UUID関連

function egg:uuid/equals

storage egg:uuid/equals <<this 比較対象 UUID
storage egg:uuid/equals >>that 比較対象 UUID
return 2つの UUID が等しいかどうか

2つの UUID を比較します。

# Set this.
data modify storage egg:uuid/equals <<this set from entity @s UUID
# Set that.
data modify storage egg:uuid/equals <<that set from entity @p UUID
# If they are equals, say "it's me.".
execute if function egg:uuid/equals run say "it's me."

function egg:uuid/-match

storage egg:uuid/match <<target 対象の UUID
return @s の UUIDと 一致したかどうか

対象の UUID を @s の UUID と比較します。

# Set target.
data modify storage egg:uuid/match <<target set from entity @s UUID
# Find my wolf.".
execute as @e[type=wolf] if function egg:uuid/match run say "found my wolf."