##ID 2
#remove points
scoreboard players remove .points_temp arena 1
scoreboard players remove .points arena 1
#summon id2_mob x and y are random values
summon zombie ~ ~1 ~ {PersistenceRequired:1b,attributes:[{id:"minecraft:step_height",base:1},{id:"minecraft:follow_range",base:50},{id:"minecraft:attack_damage",base:0},{id:"minecraft:knockback_resistance",base:1000},{base:1000,id:"max_health"},{base:10000,id:"armor"},{base:10000,id:"armor_toughness"},{id:"minecraft:movement_speed",base:0.25}],ArmorItems:[{},{},{},{components:{"minecraft:custom_data":{enemy_drop:1b},"minecraft:profile":{id:[I;-1053026497,576143882,-1224390638,-972409266],properties:[{name:"textures",value:"eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNWFlZmY5YzRmMTNkOTVmZDJmNmM0ZTc1ZDRhNTlhNmU5MmExMWFiOGE5MDYzNDQzMjU3NWMzYzBmMzRiYTQzYSJ9fX0="}]}},count:1,id:"minecraft:player_head"}],CanPickUpLoot:0b,CustomName:'{"text":"Rock Slimed","color":"white"}',Health:1000.0f,Tags:["id2_mob","enemy","newborn","medium","ranged","slime"]}


#set id for stuff
scoreboard players set @e[type=zombie,tag=id2_mob,tag=newborn,limit=1] id 2

##set level, health and id for newborn enemy
#set health
scoreboard players set @e[type=zombie,tag=id2_mob,tag=newborn,limit=1] health_max 150
scoreboard players add @e[type=zombie,tag=id2_mob,tag=newborn,limit=1] health 150

execute as @e[type=zombie,tag=id2_mob,tag=newborn] run function main:game/mobs/spawn/scores

#enemy is not newborn now
tag @e[type=zombie,tag=id2_mob,tag=newborn,limit=1] remove newborn