I am trying to create a conditional branch branch, via events (preferably) but scripts or plugins will do if needed, that checks to see if a player as an item of a specific type equipped, not a specific item itself.
For example I want to check if a player has a sword equipped but I have 50 individual swords in the database(assigned as type sword in the database). Since events only let you check individual items and not types, the best solution i could come up with is create a common event brute force checking if i have any swords equipped and setting a switch i could then use to check in other events.
While this would work i have a hard time believing there isn't a better way to go about this. For starters this would take a ton of time and also is not robust enough to handle changes to the item database should I add or remove swords.
Any help would be appreciated, thanks 🙂
For example I want to check if a player has a sword equipped but I have 50 individual swords in the database(assigned as type sword in the database). Since events only let you check individual items and not types, the best solution i could come up with is create a common event brute force checking if i have any swords equipped and setting a switch i could then use to check in other events.
While this would work i have a hard time believing there isn't a better way to go about this. For starters this would take a ton of time and also is not robust enough to handle changes to the item database should I add or remove swords.
Any help would be appreciated, thanks 🙂