summon marker ~ 200 ~ {Tags:["ParatrooperEventSpawn"]}
#limit the number of spawns to a max of 40
execute at @s positioned ~ 200 ~ run execute as @e[type=marker,distance=..2,tag=ParatrooperEventSpawn,tag=!GotTagged] run execute at @e[distance=..150,type=wither_skeleton] run scoreboard players add @s KyuDummy3 1
execute at @s positioned ~ 200 ~ run execute as @e[type=marker,distance=..2,tag=ParatrooperEventSpawn,tag=!GotTagged] run tag @s[scores={KyuDummy3=40..}] add NoSpawn


execute at @s positioned ~ 200 ~ run execute as @e[type=marker,distance=..2,tag=ParatrooperEventSpawn,tag=!GotTagged,tag=!NoSpawn] run function zzzzdonotuse:randomevent/paratroopers/paratroopersspawn2
execute at @s positioned ~ 200 ~ run execute as @e[type=marker,distance=..2,tag=ParatrooperEventSpawn,tag=!GotTagged,tag=NoSpawn] run kill @s