mirror of
https://github.com/LZStealth/armor-statues.git
synced 2025-06-08 17:26:44 +01:00

-Changed how custom naming works: you can no longer set names to be visible/invisible from the book. Since armor stands retain their names in 1.19.4 you can rename an armor stand item and place it and it will automatically become visible. -Changed 'pointing' function for head and body: Both will now 'face' the player. -Added in has visible fire setting -Added in Pointer Wand: You can obtain this by renaming a stick 'Statues' or by using the trigger in the book: /trigger pointer_wand. -Face an armor stand to enter edit mode -r-click on a joint to first set the appendage to a neutral position, then to point towards the player. -r-click on the base to rotate it facing the player -l-click on the head to make the armor stand visible/invisible -l-click on the arms to make them visible/invisible -l-click on the base to make it visible/invisible -l-click on the body to cycle through the preset poses -Added in Adjustment Wand: You can obtain this by renaming a warped fungus on a stick 'Statues' or by using the trigger in the book: /trigger adjustment_wand. -Shift+r-click to change modes between X/Y/Z -l or r click on a joint to rotate in the positive or negative rotations -l or r click the base to move the stand in the negative or positive direction
35 lines
1.9 KiB
MCFunction
35 lines
1.9 KiB
MCFunction
#
|
|
# Description: Adjust armor stand pose
|
|
# Called by: advancement: armor_statues:attack_interaction
|
|
# Entity @s: player
|
|
#
|
|
# tag setup
|
|
tag @s add as_selected
|
|
tag @e[type=minecraft:interaction, distance=..6, nbt={attack:{}}, tag=as_interactable] add as_selected_interaction
|
|
# Stores uuid to select entities
|
|
scoreboard players operation #uuid_selector as_uuid1 = @e[type=minecraft:interaction, tag=as_selected_interaction, sort=nearest, limit=1] as_uuid1
|
|
scoreboard players operation #uuid_selector as_uuid2 = @e[type=minecraft:interaction, tag=as_selected_interaction, sort=nearest, limit=1] as_uuid2
|
|
scoreboard players operation #uuid_selector as_uuid3 = @e[type=minecraft:interaction, tag=as_selected_interaction, sort=nearest, limit=1] as_uuid3
|
|
scoreboard players operation #uuid_selector as_uuid4 = @e[type=minecraft:interaction, tag=as_selected_interaction, sort=nearest, limit=1] as_uuid4
|
|
# Selects entities from their stored uuid
|
|
function armor_statues:select_by_uuid
|
|
tag @e[type=armor_stand, tag=as_uuid_selected, sort=nearest, limit=1] add as_selected
|
|
tag @e[tag=as_uuid_selected] remove as_uuid_selected
|
|
#
|
|
# pointing wand interaction
|
|
#
|
|
execute as @s[predicate=armor_statues:holding_pointer] run function armor_statues:interactions/attack_pointer
|
|
#
|
|
# adjust wand interaction
|
|
#
|
|
execute as @s[predicate=armor_statues:holding_adjustment] run function armor_statues:interactions/attack_adjust
|
|
# Resets interaction
|
|
execute as @e[type=minecraft:interaction, tag=as_selected_interaction] run function armor_statues:interactions/reset_interaction
|
|
#execute as @e[type=minecraft:interaction, distance=..6, nbt={attack:{}}] run function armor_statues:interactions/reset_interaction
|
|
scoreboard players set @s as_trigger 0
|
|
scoreboard players enable @s as_trigger
|
|
# resets tags
|
|
tag @e[tag=as_selected] remove as_selected
|
|
tag @e[type=minecraft:interaction, tag=as_selected_interaction] remove as_selected_interaction
|
|
# Resets advancement
|
|
advancement revoke @s only armor_statues:attack_interaction |