Started by
yelfog
on
Topic category: Help with Minecraft modding (Java Edition)
So I put together a procedure that is supposed to open a gui when I right click on a spider. The problem is I cant right click on mobs while in game. Is there a easy solutution to this?
I If the image isn't showing up here is the link for it
https://ibb.co/zXpFKs9
Change is source entity to entity. The Player is the source entity (who is right clicking), the entity is the splider (who receives the right click).Same with deal <###> damage to source entity, change it to entity.
Wow, Really Thanks, I Also Had The Same Problem and You We're Right I Swapped Them and It Worked
# Trigger an external call or when a player right-clicks on an entity
Events trigger - triggered external call
Or when (global trigger) player right-clicks on entity:
# Check if the source is a sub-type of a spider
If source is (sub)type of spider:
# Open the "normalspiderGui" screen for the targeted entity at coordinates (x, y, z)
Do open screen events/target entity x y z gui normalspiderGui
# Check if there are items in slot 0 of the "currency" GUI in the targeted entity
If get number of items from slot 0 of the currency > 0:
# Deal 100 damage to the source entity with the generic type
Deal 100 damage to source entity type generic
# Spawn a "custom spiderwithsadle" living entity at coordinates (x, y, z)
Spawn x y z living entity custom spiderwithsadle
# Close any open GUI for the targeted entity
Close any GUI open for events/target entity
# Open the "spiderwithsadle" screen for the targeted entity at coordinates (x, y, z)
Open screen for events/target entity, passing location x y z, GUI spiderwithsadle