MV Himeworks Hidden Choice Conditions giving the opposite effect

Hey everyone, this problem is most likely a simple one and probably due to me not knowing how to write the condition properly. I'm using himeworks hidden choice plugin, which, through a script call, hides choice number X when condition Y is met.

So, a brief explanation of what I'm trying to do:
  • Choices to insert book of x color in a bookshelf only appear when player does, in fact, have said book in their inventory.
Here's where I'm making a mistake:
  • Instead of the script call condition being so that, the choice is hidden if player DOESN'T have certain book in their inventory, the script reads that the choice will be hidden if player DOES have certain book in their inventory.
Like so:
1730320233455.png


Can anyone tell me how can I write the script condition so that the choices are hidden only if the player doesn't have item x in their inventory? I'm not really sure how to go about it in script form.

Thank you in advance to anyone who responds! 😂
JavaScript NOT is an exclamation mark.

So you can enter the condition as
Code:
!$gameParty.hasItem($dataItems[28])
JavaScript NOT is an exclamation mark.

So you can enter the condition as
Code:
!$gameParty.hasItem($dataItems[28])

Thanks Turan, it works! I'll keep that in mind for next time 👋
This tripped me up for the longest time too and I foolishly worked around it with weird inverted switches. But as ATT_Turan has said, it can be swapped. If you scroll down through all the plugin help text you'll find there are many ways to handle the conditional appearance, even with things other than switches, it's surprisingly robust.

Original thread: https://forums.rpgmakerweb.com/threads/himeworks-hidden-choice-conditions-giving-the-opposite-effect.172928/