Filtering DaggerfallExteriorAutomapWindow nameplates

Discuss modding questions and implementation details.
User avatar
pango
Posts: 2750
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Filtering DaggerfallExteriorAutomapWindow nameplates

Post by pango »

.meta files are part of all Unity projects.
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

l3lessed
Posts: 652
Joined: Mon Aug 12, 2019 4:32 pm
Contact:

Re: Filtering DaggerfallExteriorAutomapWindow nameplates

Post by l3lessed »

Thanks for sharing the code. It gave me some ideas.

One question for anyone who may know. Once you add a object, say a label, to a panel ui, say the inventory, is there an easy way to remove it/clear out the panel?

I'm trying to update a label, but everytime I do, it just adds the new one on top of the old one, since the panel hasn't ben cleared.
My Daggerfall Mods: l3lessed Nexus Page

Daggerfall Unity mods: Combat Overhaul Mod

Enjoy the free work I'm doing? Consider lending your support.

l3lessed
Posts: 652
Joined: Mon Aug 12, 2019 4:32 pm
Contact:

Re: Filtering DaggerfallExteriorAutomapWindow nameplates

Post by l3lessed »

Found my solution digging around in the methods.

Code: Select all

                    if(uicomponent != null)
                        DaggerfallUI.Instance.InventoryWindow.NativePanel.Components.Remove(uicomponent);
                        
My Daggerfall Mods: l3lessed Nexus Page

Daggerfall Unity mods: Combat Overhaul Mod

Enjoy the free work I'm doing? Consider lending your support.

User avatar
TheLacus
Posts: 1288
Joined: Wed Sep 14, 2016 6:22 pm
Contact:

Re: Filtering DaggerfallExteriorAutomapWindow nameplates

Post by TheLacus »

l3lessed wrote: Sun Dec 27, 2020 10:31 pm I'm trying to update a label, but everytime I do, it just adds the new one on top of the old one, since the panel hasn't ben cleared.
TextLabel class is mutable, you can edit your current instance directly instead of creating a new one.

Please open a new topic if you need further help with a specific issue. :)
Mod System documentation - Learn how to create mods for Daggerfall Unity.
Modder Discussion - General help and discussion for the mod system.
Github Issues - Submit a bug report for the game, including the mod system.

Post Reply