Origins (Fabric)

Origins (Fabric)

15M Downloads

Entity Selection In Datapacks Breaks

redstonerblast opened this issue ยท 1 comments

commented

Issue: Selecting command entities (such as markers) via tags doesn't work

Versions: Origins 1.13.0-alpha.2 & Origins 1.13.0-alpha.3

Example:

summon marker ~ ~ ~ {Tags:["sapling"]}
execute as @e[type=marker,tag=sapling] run say hi
commented

Assuming that the commands are run in a function (or anywhere else that allows executing commands in bulk), I think this happens because the implemented data tracker for command tags (which also effectively replace the command tags of the entity when queried) is only updated at the end of the tick.

Since commands in a function are executed in a single tick, it would seem that the entity wouldn't have the tag(s) by the point the target selector starts selecting entities, hence the issue. Good catch!