particle dust{color:[0,1,0],scale:.5} ^ ^ ^-.25 0 0 0 0 1 force
particle dust{color:[0,1,0],scale:.5} ~ ~ ~ 0 0 0 0 1 force
particle dust{color:[0,1,0],scale:.5} ^ ^ ^.25 0 0 0 0 1 force

execute as @e[dx=0,type=!#survivalplus:notalive,type=!player] positioned ~-0.99 ~-0.99 ~-0.99 if entity @s[dx=0] run damage @s 6 minecraft:player_attack by @p

execute if entity @e[dx=0,type=!#survivalplus:notalive,nbt=!{HurtTime:0s}] run tag @s add hittarget
execute if entity @s[distance=..6,tag=!hittarget] if block ~ ~ ~ #survivalplus:nobounce positioned ^ ^ ^.5 run function survivalplus:tools/trap/crystarget
tag @s remove hittarget