Right now, a command can only remember the current source entity and position/rotation, so if /execute changes one of those then the original must be found through other means. What if instead, you could use @x in order to select the original command executor, before any "as" or "on" subcommands are checked? The idea would be that this could be used in console commands like
execute as @e[type=zombie] run scoreboard players add @x Zombies 1
which would count the amount of zombies but in the score of the player that executed it. Other things like running a function from an entity would change the initial executor, so
execute summon pig run data modify entity @s Health set from entity @x Health
could be put in a function called by whatever entity's health should be copied to the new pig (without using macroes)
Please sign in to leave a comment.
1 Comments