Adding Tags
to the item will not be set as the entity's Tags
data. All the item data itself will be lost except for Potion
and CustomPotionEffects
, which are copied to the arrow entity if existent.
Tipped arrows will be necessary, but you can apply custom effects to reduce any issues should it strike a player or mob, such as setting the duration to 0. Currently the Instant Healing effect does not function on tipped arrows, but you may need to switch to something else should it work in the future.
The amplifier would be how you'd differentiate arrows from one another.
Example arrows to provide:
/give @p minecraft:tipped_arrow 64 0 {CustomPotionEffects:[{Id:6b,Duration:0,Amplifier:0b}]}
/give @p minecraft:tipped_arrow 64 0 {CustomPotionEffects:[{Id:6b,Duration:0,Amplifier:1b}]}
Then you'd label those arrows based on the effects it has, with the amplifier making each one unique:
/scoreboard players tag @e[type=Arrow,tag=!tntarrow] add tntarrow {CustomPotionEffects:[{Id:6b,Duration:0,Amplifier:0b}]}
/scoreboard players tag @e[type=Arrow,tag=!custom2] add custom2 {CustomPotionEffects:[{Id:6b,Duration:0,Amplifier:1b}]}
And finally, target based on that label:
/say @e[type=Arrow,tag=tntarrow] is a "tntarrow".
In 1.8 you cannot rely on arrows items specifically, as no item data is transferred to the entity.
However, the bow will modify the arrow's damage
value depending on the Power enchantment level. You can provide the player with a bow containing a specific Power level and then target arrows that have a particular amount of damage.
damage
will normally be 2.0. If Power exists on the bow, the value is incremented by 0.5 and then for each level of Power, it will increase by another 0.5. For example, a Power 3 bow would result in a damage value of 4.0.
Example bow to provide:
/give @p minecraft:bow 1 0 {ench:[{id:48s,lvl:3s}]}
You can assign a score to arrow entities based on their damage
tag value.
Objective to create:
/scoreboard objectives add BowType dummy
Example commands to run on a clock, assigning scores to specific arrows (Power 3 to Power 5):
/scoreboard players set @e[type=Arrow] BowType 1 {damage:4.0}
/scoreboard players set @e[type=Arrow] BowType 2 {damage:4.5}
/scoreboard players set @e[type=Arrow] BowType 3 {damage:5.0}
And you can target arrows based on their score.
/say Arrows shot from a Power 3 bow: @e[type=Arrow,score_BowType_min=1,score_BowType=1]
Best Answer
The bow pull stages are not detectable or settable by commands. The closest you can get is a crossbow with Quick charge 100 (or more) or retexturing something else (for example a snowball) and spawning an arrow with the right motion when the item is used (like this).