Senior Member
Join Date: Feb 2017
Posts: 119
|
Scenario: I'm trying to replace the headbands that grant stat bonuses with a headband setting item that would attach to another headband (this as an alternate to ABP). I'm 90% done except I ran into an issue with INT. On the headbands that have INT, there is a selector (or two) to select a skill to grant bonus ranks. I'm already using 2 selectors on the item; one to select the headband it attaches to and the second to select the stat to provide the bonus to. Since I don't have room for an additional selector for skill, I found the ioINTHelp item which adds another item for skill selector(s). This is bootstrapped by the headbands that have +6 INT to select a 3rd skill. I modified this item for my purposes and intend to bootstrap 1 (for +2 and +4) or 2 (for +6) of them. However, if the user doesn't select INT from the usrChosen2, then these additional items are unnecessary and I want to hide them.
Is there a tag to hide an equipment item on the Magic screen (the thing is on the Wondrous tab in the editor)? I've already tried Hide.Equipment but it says that tag doesn't exist. |
#1 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
Hide.Gear
|
#2 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
That worked successfully to hide it, but I cannot get it to unhide. I've put debugging in so I know that the condition to run the following line is working and the script is getting to the line, however the Hide.Gear tag is still on the pick so the line isn't working:
Quote:
|
|
#3 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
Try triggering a full evaluation when the thing should be unhidden. Also, why are you deleting a tag near that debug? Shouldn't you just not be assigning the hide tag instead?
|
#4 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
What do you mean by 'triggering a full evaluation"?
That IF statement either hides or unhides depending on the status of the parent abValue3. If it is 1, then it should unhide the thing. If it isn't 1 then it should hide the thing. The hiding part is working correctly. But when abValue3 = 1, it executes the debug command, but fails to remove the tag, so the thing remains hidden (when it should not). |
#5 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
Full evaluation didn't do anything.
This line doesn't work. Tag is still on the thing and does not successfully delete. But I know it is executing that portion because of the debug command. perform delete[Hide.Gear] |
#6 |
Senior Member
Join Date: Mar 2013
Location: Greater London, UK
Posts: 2,623
|
Quote:
Don't forget that every time scripts run, everything has been reset to a default state. No state information is kept between one run of a script and another. |
|
#7 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
Quote:
|
|
#8 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
Ok, now at this point, I have it properly deleting the tag Hide.Gear when I want it to... however, the pick is still hidden even when it doesn't have the Hide.Gear tag.
|
#9 |
Senior Member
Join Date: Feb 2017
Posts: 119
|
So I tried a different thing. Instead of hiding the whole row, I tried deleting [fShowWhat.Skills] and [ChooseSrc1.Hero] hoping that would hide the selector. Then if the user selects INT in the main item's attribute selector, I add those 2 tags to the pick. That part is working, the tags successfully delete or hide appropriately based on the selection. However, no matter the status of the tags, the actual interface does not change. It always shows the initial state (hidden). This seems to be the same behavior if I show/hide the entire gear item. It only shows the initial state (hidden).
Is there any known reason why it is not updating the display of the pick (whether selectors hidden/shown or entire pick hidden/shown) based on status change or is that just not something that it will ever do? |
#10 |
|
|