Started by
Dollyfroggy
on
Topic category: Help with Minecraft modding (Java Edition)
It says 'Set variable block for player variable is missing entity input' but I have the dependency 'Event/target entity' and it works everywhere else. How can I fix this? Code here.
maybe your trigger doesn't support event target entity, also who uses Global Triggers for itemstacks??
It appears to support it, so I'm not sure why there's an issue. What are Global Triggers and what's the alternative?
hard to explain, but Global Triggers are triggers that are not local, for example, supposing you have a lightning wand that strikes lightning when right clicked, you could
1. make the procedure on global trigger BUT you will have to check for the item in main hand
or
2. on your item editor put the procedure on local Triggers and you do not need to get item in main hand.
indeed really hard to explain, but you should be able to figure it out from here.
and an alternative would depend on what triggers your procedure, if it's a custom item or a custom entity or custom block or Anything Custom, the put the procedure on the local triggers it provides
Wouldn't this be a local trigger since it says 'No additional trigger' and it's triggered by changing something in a GUI? I attached the next line of my code; the error only complains about the first line but not the second despite them both using the 'entity' dependency.
that could be either a local or global trigger, if the trigger supports entity ofc, but can't you do this without variables? why do you need them on this case?
I have some other procedures that could be triggered when the GUI is closed (e.g. when entity is healed) and I need to check which item is in the GUI. There's no block for checking an item in a GUI besides the one that is currently open to my knowledge, so I tried to set it to a variable so I could check the variable.
Basis of the mod: There's a GUI where you put items in and different items give you different power-ups.
I see. But then do this with Player Lifetime Variables, when player inserts item set VARIABLE "power-up" to = # or true/false
Can I use items for that? There are multiple items with different power-ups and I don't want to make a variable for each.
yes, make different variables
oh sorry lol, just make multiple variables for multiple items
Alright, I'll do that. Thank you!