So I want to give someone a rank depending on if they have a named item in they're inventory I use permissionsex plugin if that helps.
command /EmeraldKey:
trigger: if player has 1 tripwire hook named "&a&lEmerald Key":
remove 1 tripwire hook named "&a&lEmerald Key" from player's inventory console command
"pex user %player% group add Emerald"
command /EmeraldKey:
trigger: if player has 1 tripwire hook named "&a&lEmerald Key":
remove 1 tripwire hook named "&a&lEmerald Key" from player's inventory console command
"pex user %player% group add Emerald"