#I need help with this Action Script

1 messages · Page 1 of 1 (latest)

sweet gladeBOT
#

Could you show me the actual requirements that are attached to those IF statements and confirm what element is running this action script (e.g., a button, slider, ticker)? From the docs you need to give each Is Variable Value requirement a value in the variable_name:expected_value format, otherwise the IF will never evaluate to true, and the script never runs. Also double‑check that the action script is actually triggered (for example a button click or ticker pulse) and that Set Variable Value is using the exact same variable name/path.

If you can post a full screenshot of the requirement dialogs (and mention which element is executing the script), I can point out any mismatches.

pure pond
#

First If THEN second If

sweet gladeBOT
# pure pond First If THEN second If

Thanks for the extra screenshots! From what I can see, your two Is Variable Value (FM Variable) requirements only have a Value set (e.g. cape:off), but they are still missing the variable identifier itself. The requirement needs the exact variable_name:expected_value string so it can compare it properly—this is explained on the Variables page in the docs. In other words, the requirement must know which variable to check with cape:off or cape:on, not just the expected part.

Make sure your Set Variable Value actions are using the same variable name (cape) and values (on/off), and that the button (or whatever element runs this script) is actually being clicked/ticked so the action script runs. Once both requirements and actions reference the same variable identifier/value pair, the IF chains should trigger and the Minecraft option (modelPart_cape:true/false) will update as expected.

If you want, feel free to post a screenshot of the entire action script tree (including the Set Variable Value configuration) so I can point out any mismatches.

pure pond
#

The element is a checkbox, and actually, according to the doc and the text above the Vars screen, it says to use variable_name:variable_value, which is being used in the IF statements cape:on and cape:off

sweet gladeBOT
# pure pond The element is a checkbox, and actually, according to the doc and the text above...

Thanks for confirming it’s a checkbox. The only reason FancyMenu’s Is Variable Value (FM Variable) requirement wouldn’t fire is if it doesn’t actually know which variable to compare. The Value input you’ve shown (cape:on / cape:off) is correct for the name:value format, but there’s also a separate Variable field in that requirement that must be filled with the variable identifier itself (e.g., cape). If that field is left empty, the requirement can’t resolve the name and will never return true.

So double‑check the requirement dialog: make sure the Variable entry is set to your variable’s name (like cape), and keep the Value set to the cape:on / cape:off strings. Also ensure the variable actually exists in the Variables manager and that the checkbox’s action script is triggered on toggle. Once both the name and value are provided, the IF branches should run and your Set Minecraft Option + Set Variable actions will execute as expected.

pure pond
#

This is what shows up when i click on Edit Requirement and Edit Requirement Value (Same with other IF just set to off)