scoreboard players add #npc_start time 1
execute if score #npc_start time matches 50 run tellraw @a {"text":"\n\n\n\n\n\n\n\n\n\n\n\nPikatscha joined the game","color":"yellow"}
execute if score #npc_start time matches 500 run scoreboard players reset #startSEQ V
execute if score #npc_start time matches 50 run summon piglin_brute 10 1 0 {Silent:1b,Invulnerable:1b,CustomNameVisible:1b,PersistenceRequired:1b,CanPickUpLoot:0b,IsImmuneToZombification:1b,Tags:["npc","npc_start"],CustomName:'{"text":"Pikatscha","color":"white"}',ArmorItems:[{},{},{},{id:"minecraft:player_head",Count:1b,tag:{SkullOwner:{Id:[I;-1270540108,-998941926,-1858353752,-1399270529],Properties:{textures:[{Value:"e3RleHR1cmVzOntTS0lOOnt1cmw6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMWZhMjlmMmZlNjBkMzhjMjRjNGQ3ODZlMDZmMjI5OWQxZjYzYmQzN2FjZmU0YTk1ZGRkZDM4MTdjZjRkYzVkYSJ9fX0="}]}}}}],Attributes:[{Name:generic.movement_speed,Base:0},{Name:generic.attack_damage,Base:0.001},{Name:generic.attack_knockback,Base:2}]}
execute if score #npc_start time matches 100 run tellraw @a [{"text":"\n<Pikatscha> Willkommen in der "},{"text":"PietSmiet Adventure Map","color":"aqua"},{"text":", ich bin der ","color":"white"},{"text":"Creator ","color":"aqua"},{"text":"und am heutigen Tag ihr ","color":"white"},{"text":"NPC","color":"aqua"},{"text":"!","color":"white"}]
execute if score #npc_start time matches 160 run tellraw @a [{"text":"\n<Pikatscha> Die Bauzeit dieser Map waren "},{"text":"ca. 3 Tage","color":"aqua"},{"text":".","color":"white"}]
execute if score #npc_start time matches 220 run tellraw @a {"text":"\n<Pikatscha> Ich hoffe euch gefällt die Map, da ich in dieser Art noch nie etwas gemacht habe."}
execute if score #npc_start time matches 280 run tellraw @a [{"text":"\n<Pikatscha> Ich begleite euch zum "},{"text":"ersten Level","color":"aqua"},{"text":". Folgt mir!","color":"white"}]

execute if score #npc_start time matches 290 run data merge entity e0bdfada-c63a-4669-a626-ea250c0364ec {start_interpolation:-1,transformation:{left_rotation:[0.0f,0.0f,0.0f,1.0f],right_rotation:[0.0f,0.0f,0.0f,1.0f],scale:[36.0f,1.0f,5.0f],translation:[-0.5f,-0.5f,-2.5f]}}
execute if score #npc_start time matches 290 run data merge entity aeb17fe1-371d-4e7b-bda1-6cab00973144 {start_interpolation:-1,transformation:{left_rotation:[0.0f,0.0f,0.0f,1.0f],right_rotation:[0.0f,0.0f,0.0f,1.0f],scale:[4.0f,5.0f,5.0f],translation:[-1.9f,2.4f,-2.5f]}}
execute if score #npc_start time matches 290 run fill 11 2 2 11 2 -2 air
execute if score #npc_start time matches 290 run playsound minecraft:block.beacon.activate master @a 12 0 0 5 .8
execute if score #npc_start time matches 290..330 run playsound minecraft:block.chain.step master @a 12 0 0 .2 .7
execute if score #npc_start time matches 300 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pikatsch§ka"}'}
execute if score #npc_start time matches 310 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pikatsc§kha"}'}
execute if score #npc_start time matches 320 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pikats§kcha"}'}
execute if score #npc_start time matches 330 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pikat§ksch"}'}
execute if score #npc_start time matches 340 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pika§ktsc"}'}
execute if score #npc_start time matches 350 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pik§kats"}'}
execute if score #npc_start time matches 360 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"Pi§kkat"}'}
execute if score #npc_start time matches 370 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"P§kika"}'}
execute if score #npc_start time matches 380 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"§kPik"}'}
execute if score #npc_start time matches 390 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"§kPi"}'}
execute if score #npc_start time matches 400 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":"§kP"}'}
execute if score #npc_start time matches 410 run data merge entity @e[tag=npc_start,limit=1] {CustomName:'{"text":""}',CustomNameVisible:0b}

execute if score #npc_start time matches 300..445 run function npc:move/0
execute if score #npc_start time matches 300 run execute if entity JayPietSmiet run effect give @e[name=jay] minecraft:glowing 30 1 true
execute if score #npc_start time matches 300 run execute if entity PietSmiet run effect give @e[name=piet] minecraft:glowing 30 1 true
execute if score #npc_start time matches 300 run execute if entity Br4mm3n run effect give @e[name=br4] minecraft:glowing 30 1 true
execute if score #npc_start time matches 300 run execute if entity Brosator run effect give @e[name=chr] minecraft:glowing 30 1 true
execute if score #npc_start time matches 300 run execute if entity kessemak run effect give @e[name=sep] minecraft:glowing 30 1 true
execute if score #npc_start time matches 340 run tellraw @a [{"text":"\n<Pikatscha> In der Map sind "},{"text":"Emerald Blöcke ","color":"aqua"},{"text":"verteilt, welche euch ","color":"white"},{"text":"kosmetische Rüstungsstücke ","color":"aqua"},{"text":"geben können! Vllt lohnt es sich etwas umzuschauen.","color":"white"}]
execute if score #npc_start time matches 420 run tellraw @a [{"text":"\n<Pikatscha> Ich werde ab jetzt als "},{"text":"NPC ","color":"aqua"},{"text":"euch durch die Map folgen. Um mit mir zu interagieren, klickt mich an!","color":"white"}]

execute if score #npc_start time matches 445 run tp @e[tag=npc_start] ~ -100 ~ 
execute if score #npc_start time matches 445 run kill @e[tag=npc_start]
execute if score #npc_start time matches 445 run summon piglin_brute 52 1 -3 {Silent:1b,Invulnerable:1b,PersistenceRequired:1b,CanPickUpLoot:0b,IsImmuneToZombification:1b,Rotation:[47.5F,9.8F],Tags:["npc"],Passengers:[{id:"minecraft:interaction",width:1f,height:-2f,response:1b,Tags:["npc","d_0"]}],ArmorItems:[{},{},{},{id:"minecraft:player_head",Count:1b,tag:{SkullOwner:{Id:[I;-1270540108,-998941926,-1858353752,-1399270529],Properties:{textures:[{Value:"e3RleHR1cmVzOntTS0lOOnt1cmw6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMWZhMjlmMmZlNjBkMzhjMjRjNGQ3ODZlMDZmMjI5OWQxZjYzYmQzN2FjZmU0YTk1ZGRkZDM4MTdjZjRkYzVkYSJ9fX0="}]}}}}],Attributes:[{Name:generic.follow_range,Base:-999},{Name:generic.movement_speed,Base:0},{Name:generic.attack_damage,Base:0}]}
