Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
conditions:stringequals [2019/07/01 01:58]
127.0.0.1 external edit
conditions:stringequals [2020/05/27 12:34] (current)
wahrheit [Examples]
Line 22: Line 22:
 <​code>​ <​code>​
 Conditions: Conditions:
-- stringequals{val1="​yes!";​ val2="​yes!"​} true+- stringequals{val1="​yes!";​val2="​yes!"​} true
 </​code>​ </​code>​
    
    
 +<​code>​
 +Conditions:
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].item_in_hand.has_nbt[special_item]>​%";​val2="​true"​} true
 +</​code>​
 +
 +Uses Denizen, PlaceholderAPI,​ and MythicMobs to check whether the item the player is holding has a Denizen NBT key of "​special_item."​ <​trigger.uuid>​ is a MythicMobs placeholder that gets parsed //before// PlaceholderAPI parses the Denizen tag.
 +
 +<​code>​
 +Conditions:
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].item_in_hand.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +</​code>​
 +
 +Uses Denizen, PlaceholderAPI,​ and MythicMobs to check whether the item the player is holding is a MythicItem with the internalname of "​SomeMythicItem"​ by reading raw NBT data. Only supported on versions that store internalnames on NBT data.
 +
 +<​code>​
 +Conditions:
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].item_in_offhand.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +</​code>​
 +
 +The same, but for the offhand.
 +
 +<​code>​
 +Conditions:
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].equipment.helmet.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].equipment.chestplate.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].equipment.leggings.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +- stringequals{val1="​%denizen_<​player[<​trigger.uuid>​].equipment.boots.raw_nbt.get[mythic_type].after[string:​]>​%";​val2="​SomeMythicItem"​} true
 +</​code>​
  
 +The same, but for equipment slots.

conditions/stringequals.1561960733.txt.gz · Last modified: 2019/07/01 01:58 by 127.0.0.1