summon wandering_trader ~ ~ ~ {Silent:1b,Tags:["new","svm_ep.npc","svm_ep.npc_pemc","svm_ep.power_user","svm_ep.phase_user"],Offers:{Recipes:[{maxUses:15,buy:{id:iron_ingot,Count:15},buyB:{id:gold_ingot,Count:10},sell:{id:flower_banner_pattern,Count:1,components:{"minecraft:custom_data":{svm_ep.scroll_phase:1b,svm_ep.power_scroll:1b},"custom_name":'[{"text":"Phase Scroll","italic":false,"bold":true,"color":"gold"}]',"lore":['[{"text":"Put in your offhand to learn powers of phasing","italic":false,"color":"aqua"},{"text":"","italic":false,"color":"dark_purple"}]','[{"text":"","italic":false,"color":"dark_purple"}]','[{"text":"(Doesn\'t work if user has any of the powers)","italic":true,"color":"gray"}]']}}}]},CustomName:'[{"text":"P","color":"#ff0000"},{"text":"e","color":"#ff3300"},{"text":"m","color":"#ff6600"},{"text":"c","color":"#ff3300"}]',Health:500,CanPickUpLoot:1b,OnGround:1b,PersistenceRequired:1b,ActiveEffects:[{Id:14,Duration:"infinite",ShowParticles:0b}],HandDropChances:[0.00f],Attributes:[{Name:"generic.max_health",Base:500f}]}

summon armor_stand ~ ~ ~ {Tags:["new2","svm_ep.npc","svm_ep.npc_display","svm_ep.npc_pemc"],ShowArms:1b,Invisible:1b,Marker:1b,NoBasePlate:1b,DisabledSlots:4144959,ArmorItems:[{},{},{},{id:warped_fungus_on_a_stick,components:{"custom_model_data":4},Count:1}],ArmorDropChances:[0f,0f,0f,0.00f]}

execute as @e[tag=new2] run ride @s mount @e[tag=new,limit=1,sort=nearest]

effect give @e[tag=new] invisibility infinite 0 true
attribute @n[tag=new,limit=1] minecraft:generic.max_health base set 250
attribute @n[tag=new,limit=1] minecraft:generic.step_height base set 2.5
data merge entity @n[tag=new,limit=1] {Health:250}

tag @e remove new
tag @e remove new2