//Music by Melody Man

actor VANPookin : TerminalArmorClass
{
Player.ScoreIcon "VANPMUGS"
player.startitem "BaseFlagPack", 1
PainSound "weapon/mm7pain"
player.displayname "VANPookin"
player.soundclass "vanpookinc"
player.morphweapon "GreenSpitBoss"
player.startitem "IsFromMM7"
player.startitem "NoHealthBar"
player.viewheight 69
projectilepassheight 117
player.forwardmove 0.85, 0.85
player.sidemove 0.83, 0.83
player.jumpz 12
alpha 0.0
States
{
Spawn:
PLAY A 0 
VNPK B 1 A_JumpIf(z-floorz>0,"Jumping")
Animation18:
VNPK A 1 A_JumpIf(z-floorz>0,"Jumping")
Goto Spawn+2
See:
VNPK BBCCDDEEFFGG 1 A_JumpIf(z-floorz>0, "Jumping")
Goto Spawn
Jumping:
VNPK BBCC 1 A_JumpIf(z-floorz<=0,"Spawn")
loop
Animation0:
VNPK A 1 A_JumpIf(z-floorz<=0,"Animation18")
wait
Missile:
VNPK KKKKK 1 A_JumpIf(z-floorz>0, "JumpingMissile")
Missile2:
VNPK LLLLL 1 A_JumpIf(z-floorz>0, "JumpingMissile2")
Goto Spawn+2
JumpingMissile:
VNPK KKKKK 1 A_JumpIf(z-floorz<=0, "Missile")
JumpingMissile2:
VNPK LLLLL 1 A_JumpIf(z-floorz<=0, "Missile2")
Goto Jumping

Animation6: VANPookinFireStartA: VNPK HHH 1
Animation7: VANPookinFireStartB: VNPK III 1
Animation8: VANPookinFireStartC: VNPK JJJ 1
Animation9: VANPookinFirePhaseD: VNPK KKK 1
Goto Spawn+2

Animation10:
VANPookinFire:
VNPK LLLLLLLLLL 1
Goto Spawn+2

Animation11: VANPookinSpinA: VNPK MMM 1
Animation12: VANPookinSpinA: VNPK NNN 1
Animation13: VANPookinSpinA: VNPK OOO 1
Animation14: VANPookinSpinA: VNPK PPP 1
Animation15: VANPookinSpinA: VNPK QQQ 1
Animation16: VANPookinSpinA: VNPK RRR 1
Animation17: VANPookinSpinA: VNPK SSS 1
Goto Spawn+2

ClassPain:
VNPK TTTTTTTTTT 2 A_SpawnItem("PainFX",0,3)
Goto Spawn+1
ClassDeath: 
TNT1 A 0 A_SpawnItemEx("VANPookinDeath",0,0,0,0,0,0,0,1)
NOFX A 20 ACS_ExecuteAlways(999,0,0)
NOFX A 1 A_CheckPlayerDone
wait
WeaponGetM:
SHDE H 0
goto ClassDeath
}
}

actor VANPookinEntrance : BasicClientSide
{
renderstyle add
alpha 0.0
States
{
Spawn:
TNT1 A 0
VBOO UUUUU 1 A_FadeIn(0.2)
VBOO U 25 A_PlaySoundEx("weapon/vanpookinentrance","Body")
stop
}
}

Actor VanPookinIntroScareHitbox : QuakeDamage
{
Obituary "$OB_VANPOOKIN1"
States
{
Spawn:
TNT1 A 0
TNT1 A 2 A_Explode(200,300,0,0,300)
stop
}
}

Actor GreenSpitBoss : VCBaseWeapon
{
weapon.ammotype "Base112Ammo"
weapon.ammotype2 "BaseAltfireAmmo"
Obituary "$OB_VANPOOKIN1"
States
{
Ready:
TNT1 A 0
TNT1 A 0 A_Stop
TNT1 A 0 SetPlayerProperty(0,1,4)
TNT1 A 0 A_ChangeFlag("INVULNERABLE",True)
TNT1 A 0 A_ChangeFlag("NOTELEFRAG",True)
TNT1 A 0 A_GiveInventory("InvProtection",1)
TNT1 A 0 ACS_ExecuteAlways(991,0,43)
TNT1 A 0 ACS_ExecuteAlways(191,0,APROP_JumpZ,0,1)
TNT1 A 100
TNT1 A 30 A_SpawnItemEx("VANPookinEntrance")
VPKH A 0 A_Quake(3,25,0,300)
VPKH A 0 ACS_ExecuteAlways(991,0,43)
VPKH A 0 A_PlaySoundEx("weapon/napalm","Weapon")
VPKH A 0 A_PlaySoundEx("weapon/junkend","Voice")
VPKH A 0 A_PlaySoundEx("weapon/drillexplode","Body")
TNT1 AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA 0 A_SpawnItemEx("BubbleBatRMFX",32,0,Random(32,64),Random(3,25),0,random(-2,5),random(0,359))
VPKH AAAAAAAAAAAAAAA 0 A_SpawnItemEx("DrillExplode",Random(-128,128),Random(-128,128),Random(0,80))
TNT1 A 0 ACS_ExecuteAlways(191,0,APROP_JumpZ,12,1)
TNT1 A 0 A_GiveInventory("ShadowVisible")
TNT1 A 0 A_GiveInventory("GravityRestore")
TNT1 A 0 A_SpawnItemEx("VanPookinIntroScareHitbox")
TNT1 A 0 SetPlayerProperty(0,0,0)
VPKH A 35 SetPlayerProperty(0,0,4)
TNT1 A 0 A_ChangeFlag("INVULNERABLE",False)
TNT1 A 0 A_ChangeFlag("NOTELEFRAG",False)
VPKH A 0 A_TakeInventory("InvProtection",1)

Ready2:
VPKH A 0 A_JumpIfInventory("BaseAltfireAmmo",28,"Ready2.CanTF")
VPKH A 1 A_WeaponReady(WRF_NOPRIMARY*CallACS("VC_AmmoCheck",2,0)|WRF_NOSECONDARY*CallACS("VC_AmmoCheck",3,28))
VPKH A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
VPKH A 0 A_GiveInventory("BaseAltfireAmmo",1)
VPKH A 0 A_GiveInventory("HalfDamageProtection")
Goto Ready2
Ready2.CanTF: 
VPKH A 1 A_WeaponReady(WRF_NOPRIMARY*CallACS("VC_AmmoCheck",2,0)|WRF_NOSECONDARY*CallACS("VC_AmmoCheck",3,28))
VPKH A 0 A_JumpIfInventory("UltAttackFlag",1,"UltimateAttack")
VPKH A 0 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"User1")
VPKH A 0 A_GiveInventory("BaseAltfireAmmo",1)
VPKH A 0 A_GiveInventory("HalfDamageProtection")
Goto Ready2

Deselect:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Lower
VPKH A 1 A_Lower
Loop
Select:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Raise
VPKH A 1 A_Raise
Loop

Fire:
GreenSpitHold:
TOAD A 0 A_GiveInventory("ToadChargeDamageGive")
VPKH B 0 A_PlaySoundEx("misc/door","Auto")
VPKH B 0 A_TakeInventory("HalfDamageProtection")
GreenSpitHoldB:
VPKH B 0 A_JumpIfInventory("Base112Ammo",37,"GreenSpitHold2")
VPKH B 0 ACS_NamedExecuteWithResult("VC_SetState",6)
VPKH B 1 A_GiveInventory("Base112Ammo",1)
VPKH BB 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHoldC")
Goto GreenSpitWeak
GreenSpitHoldC:
VPKH B 0 A_JumpIfInventory("Base112Ammo",37,"GreenSpitHold2")
VPKH B 0 ACS_NamedExecuteWithResult("VC_SetState",6)
VPKH B 1 A_GiveInventory("Base112Ammo",2)
VPKH BB 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHoldB")
Goto GreenSpitWeak
GreenSpitHold2:
VPKH C 0 A_PlaySoundEx("misc/door","Auto")
GreenSpitHold2B:
VPKH C 0 A_JumpIfInventory("Base112Ammo",74,"GreenSpitHold3")
VPKH C 0 ACS_NamedExecuteWithResult("VC_SetState",7)
VPKH C 1 A_GiveInventory("Base112Ammo",1)
VPKH CC 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold2C")
Goto GreenSpitModerate
GreenSpitHold2C:
VPKH C 0 A_JumpIfInventory("Base112Ammo",74,"GreenSpitHold3")
VPKH C 0 ACS_NamedExecuteWithResult("VC_SetState",7)
VPKH C 1 A_GiveInventory("Base112Ammo",2)
VPKH CC 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold2B")
Goto GreenSpitModerate
GreenSpitHold3:
VPKH D 0 A_PlaySoundEx("misc/door","Auto")
GreenSpitHold3B:
VPKH D 0 A_JumpIfInventory("Base112Ammo",112,"GreenSpitHold4")
VPKH D 0 ACS_NamedExecuteWithResult("VC_SetState",8)
VPKH D 1 A_GiveInventory("Base112Ammo",1)
VPKH DD 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold3C")
Goto GreenSpitStrong
GreenSpitHold3C:
VPKH D 0 A_JumpIfInventory("Base112Ammo",112,"GreenSpitHold4")
VPKH D 0 ACS_NamedExecuteWithResult("VC_SetState",8)
VPKH D 1 A_GiveInventory("Base112Ammo",2)
VPKH DD 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold3B")
Goto GreenSpitStrong
GreenSpitHold4:
VPKH E 0 A_PlaySoundEx("weapon/acidbarrier","Auto")
GreenSpitHold4B:
VPKH E 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",9)
VPKH EE 1 Offset(-1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold4C")
Goto GreenSpitStrongest
GreenSpitHold4C:
VPKH E 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",9)
VPKH EE 1 Offset(1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==3,"GreenSpitHold4B")
Goto GreenSpitStrongest
GreenSpitWeak:
TOAD A 0 A_GiveInventory("ToadChargeDamageTake")
VPKH E 0 ACS_NamedExecuteWithResult("VC_SetState",10)
VPKH E 0 A_PlaySoundEx("weapon/pshot","SoundSlot1")
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot2")
VPKH E 0 A_TakeInventory("Base112Ammo",112)
VPKH E 0 A_FireCustomMissile("GreenSpitRM",0,0,0,14)
VPKH E 0 A_FireCustomMissile("GreenSpitRM",10,0,0,14)
VPKH E 0 A_FireCustomMissile("GreenSpitRM",-10,0,0,14)
Goto EndMainUlt
GreenSpitModerate:
TOAD A 0 A_GiveInventory("ToadChargeDamageTake")
VPKH E 0 ACS_NamedExecuteWithResult("VC_SetState",10)
VPKH E 0 A_PlaySoundEx("weapon/pshot","SoundSlot1")
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot2")
VPKH E 0 A_TakeInventory("Base112Ammo",112)
VPKH E 0 A_FireCustomMissile("GreenSpit2RM",0,0,0,14)
Goto EndMainUlt
GreenSpitStrong:
TOAD A 0 A_GiveInventory("ToadChargeDamageTake")
VPKH E 0 ACS_NamedExecuteWithResult("VC_SetState",10)
VPKH E 0 A_PlaySoundEx("weapon/pshot","SoundSlot1")
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot2")
VPKH E 0 A_TakeInventory("Base112Ammo",7)
VPKH E 4 A_FireCustomMissile("GreenSpit3RM",0,0,0,14)
VPKH E 0 A_JumpIfInventory("Base112Ammo",7,"GreenSpitStrong")
Goto EndMainUlt
GreenSpitStrongest:
TOAD A 0 A_GiveInventory("ToadChargeDamageTake")
VPKH E 0 ACS_NamedExecuteWithResult("VC_SetState",10)
VPKH E 0 A_PlaySoundEx("weapon/pshot","SoundSlot1")
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot2")
VPKH E 0 A_TakeInventory("Base112Ammo",22)
VPKH E 7 A_FireCustomMissile("BubbleBatRM",0,0,0,14)
VPKH E 0 A_JumpIfInventory("Base112Ammo",22,"GreenSpitStrongest")
EndMainUlt:
VPKH EDCB 2 A_TakeInventory("Base112Ammo",112)
VPKH A 1 A_Jump(256,"Ready2")
wait

Altfire:
VPKH A 0 A_GiveInventory("VANPookinAltThirdOn")
VPKH A 0 A_JumpIf(floorz-z==0,"GreenFountainHold")
Goto PumpkinSlam
GreenFountainHold:
VPKH B 0 A_TakeInventory("HalfDamageProtection")
VPKH B 0 A_PlaySoundEx("misc/door","Auto")
VPKH BBBBBBBBBBBB 1 ACS_NamedExecuteWithResult("VC_SetState",6)
VPKH C 0 A_PlaySoundEx("misc/door","Auto")
VPKH CCCCCCCCCCCC 1 ACS_NamedExecuteWithResult("VC_SetState",7)
VPKH D 0 A_PlaySoundEx("misc/door","Auto")
VPKH DDDDDDDDDDDD 1 ACS_NamedExecuteWithResult("VC_SetState",8)
GreenFountainHoldFire:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAltUlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",11)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(-1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFireB")
Goto EndAlt
GreenFountainHoldFireB:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",12)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFireC")
Goto EndAlt
GreenFountainHoldFireC:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",13)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(-1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFireD")
Goto EndAlt
GreenFountainHoldFireD:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",14)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFireE")
Goto EndAlt
GreenFountainHoldFireE:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",15)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(-1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFireF")
Goto EndAlt
GreenFountainHoldFireF:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",16)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(1,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFire")
Goto EndAlt
GreenFountainHoldFireG:
VPKH E 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndAlt
VPKH E 0 A_TakeInventory("BaseAltfireAmmo",1)
VPKH E 0 A_PlaySoundEx("weapon/oilshot","SoundSlot1")
VPKH EE 1 Offset(0,32)ACS_NamedExecuteWithResult("VC_SetState",17)
VPKH EEEEE 0 A_SpawnItemEx("GreenSpit4RM",16,0,40,20,0,Random(5,10),Random(0,359))
VPKH EE 1 Offset(0,32)A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",4)==5,"GreenFountainHoldFire")
Goto EndAlt

PumpkinSlam:
VPKH A 0 ThrustThingZ(0,-60,0,0)
VPKH A 0 ACS_NamedExecuteWithResult("VC_SetState",0)
VPKH A 0 A_SpawnItemEx("PumpkinSlamHitBox",0,0,0,momx,momy,momz)
VPKH A 1 A_JumpIf(floorz-z==0,1)
loop
VPKH A 0 A_Quake(3,35,0,300)
VPKH A 0 A_PlaySoundEx("weapon/GutsmanQuake", "Body")
VPKH A 0 A_SpawnItemEx("ConcreteShockwaveRadius")
VPKH A 0 A_SpawnItemEx("VANPookinQuakeRadius")
VPKH A 0 A_SpawnItemEx("VANPookinCrushDamager",0,0,32)
VPKH A 1 Offset(0,38)A_stop
VPKH A 1 Offset(0,26)A_stop
VPKH A 1 Offset(0,38)A_stop
VPKH A 1 Offset(0,26)A_stop
VPKH A 1 Offset(0,38)A_stop
VPKH A 1 Offset(0,27)A_stop
VPKH A 1 Offset(0,37)A_stop
VPKH A 1 Offset(0,27)A_stop
VPKH A 1 Offset(0,37)A_stop
VPKH A 1 Offset(0,27)A_stop
VPKH A 1 Offset(0,36)A_stop
VPKH A 1 Offset(0,28)A_stop
VPKH A 1 Offset(0,36)A_stop
VPKH A 1 Offset(0,28)A_stop
VPKH A 1 Offset(0,36)A_stop
VPKH A 1 Offset(0,29)A_stop
VPKH A 1 Offset(0,35)A_stop
VPKH A 1 Offset(0,29)A_stop
VPKH A 1 Offset(0,35)A_stop
VPKH A 1 Offset(0,29)A_stop
VPKH A 1 Offset(0,34)A_stop
VPKH A 1 Offset(0,30)A_stop
VPKH A 1 Offset(0,34)A_stop
VPKH A 1 Offset(0,30)A_stop
VPKH A 1 Offset(0,33)A_stop
VPKH A 1 Offset(0,31)A_stop
VPKH A 1 Offset(0,33)A_stop
VPKH A 1 Offset(0,31)A_stop
VPKH A 1 Offset(0,33)A_stop
VPKH A 1 Offset(0,31)A_stop
VPKH A 1 A_stop
VPKH A 1 A_stop
VPKH A 1 A_stop
VPKH A 1 A_stop
VPKH A 1 A_stop
VPKH A 0 A_TakeInventory("CutterFlag",999)
VPKH A 0 A_TakeInventory("VANPookinAltThirdOn")
VPKH A 0 ACS_NamedExecuteWithResult("VC_SetState",0)
VPKH A 1 A_Jump(256,"Ready2")
wait

EndAlt:
VPKH A 0 A_TakeInventory("CutterFlag",999)
VPKH A 0 A_TakeInventory("VANPookinAltThirdOn")
VPKH A 0 ACS_NamedExecuteWithResult("VC_SetState",0)
VPKH EDCB 1
VPKH A 1 A_Jump(256,"Ready2")
wait

User1:
RunawayPumpkinHold:
VPKH A 0 SetPlayerProperty(0,1,4)
VPKH A 0 A_GiveInventory("HalfDamageProtection")
VPKH A 0 A_GiveInventory("VANPookinAltThirdOn")
VPKH A 0 A_JumpIfInventory("VANPookinHit",1,"RunawayPumpkinRecoil")
VPKH A 0 A_JumpIfInventory("BaseAltfireAmmo",1,1)
Goto EndTF
VPKH A 0 A_PlaySoundEx("weapon/superboost","Weapon")
VPKH A 0 A_ChangeVelocity(cos(pitch)*35,0,0,CVF_RELATIVE|CVF_REPLACE)
VPKH A 0 A_SpawnItemEx("RunawayPumpkinWallCheck",32,0,0,momx,momy,momz,0,8)
VPKH A 0 A_SpawnItemEx("RunawayPumpkinHitBox",32,0,24,momx,momy,momz)
VPKH A 1 A_TakeInventory("BaseAltfireAmmo",1)
VPKH AA 1 A_JumpIf(ACS_NamedExecuteWithResult("VC_CheckBtn",3)==3,"RunawayPumpkinHold")
Goto EndTF

RunawayPumpkinRecoil:
VPKH A 0 A_Stop
VPKH A 0 A_Recoil(15)
VPKH A 0 A_Quake(3,25,0,300)
VPKH A 0 ThrustThingZ(0,30,0,0)
VPKH A 0 A_PlaySoundEx("weapon/GutsmanQuake","Body")
VPKH A 1 Offset(0,34)SetPlayerProperty(0,0,4)
VPKH A 1 Offset(0,30)A_TakeInventory("VANPookinHit")
VPKH A 1 Offset(-2,32)A_TakeInventory("BaseAltfireAmmo")
VPKH A 1 Offset(2,32)A_TakeInventory("VANPookinAltThirdOn")
VPKH A 1 Offset(0,34)A_GiveInventory("HalfDamageProtection")
VPKH A 1 Offset(0,30)
VPKH A 1 Offset(-2,32)
VPKH A 1 Offset(2,32)
VPKH A 1 Offset(0,34)
VPKH A 1 Offset(0,30)
VPKH A 1 Offset(-2,32)
VPKH A 1 Offset(2,32)
VPKH A 1 A_Jump(256,"Ready2")
wait

EndTF:
VPKH A 0 SetPlayerProperty(0,0,4)
VPKH A 0 A_TakeInventory("VANPookinHit")
VPKH A 0 A_TakeInventory("BaseAltfireAmmo")
VPKH A 0 A_TakeInventory("VANPookinAltThirdOn")
VPKH AAAAAAAAAAAA 1 A_GiveInventory("HalfDamageProtection")
VPKH A 1 A_Jump(256,"Ready2")
wait

UltimateAttack:
VPKH B 0 A_PlaySoundEx("classes/ultimateactivation","Auto") VPKH B 0 A_SpawnItemEx("TerminatorUltimateAlarm")
VPKH B 0 ACS_NamedExecuteAlways("VC_UltimateText",0,131)
VPKH B 0 A_GiveInventory("PharaohUltCooldown",1) VPKH B 0 A_GiveInventory("InvProtection") VPKH B 0 A_ChangeFlag("INVULNERABLE",True)
VPKH B 0 A_PlaySoundEx("misc/door","Auto")
VPKH BBBBBBBBBBBBBBBBBBBBBBBBBBB 1 ACS_NamedExecuteWithResult("VC_SetState",6)
VPKH B 0 A_GiveInventory("PharaohUltCooldown",1)
VPKH C 0 A_PlaySoundEx("misc/door","Auto")
VPKH CCCCCCCCCCCCCCCCCCCCCCCCCCC 1 ACS_NamedExecuteWithResult("VC_SetState",7)
VPKH B 0 A_GiveInventory("PharaohUltCooldown",1)
VPKH D 0 A_PlaySoundEx("misc/door","Auto")
VPKH DDDDDDDDDDDDDDDDDDDDDDDDDDD 1 ACS_NamedExecuteWithResult("VC_SetState",8)
VPKH B 0 A_GiveInventory("PharaohUltCooldown",1)
VPKH E 0 A_PlaySoundEx("weapon/acidbarrier","Auto")
VPKH EEEEEEEEEEEEEEEEEEEEEEEEEEE 1 ACS_NamedExecuteWithResult("VC_SetState",9)
BatCountry:
VPKH E 0 A_JumpIfInventory("TerminationUltimateAmmo",1,1)
Goto UltEnd
VPKH E 0 A_PlaySoundEx("weapon/hshbreath","Weapon")
VPKH EEE 0 A_FireCustomMissile("BatCountryBubbleBat",Random(-10,10),0,0,4,0,Random(-10,10))
VPKH E 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",10) VPKH E 0 A_TakeInventory("TerminationUltimateAmmo",10)
VPKH E 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",10) VPKH E 0 A_TakeInventory("TerminationUltimateAmmo",10)
VPKH E 1 Offset(-1,32)ACS_NamedExecuteWithResult("VC_SetState",10) VPKH E 0 A_TakeInventory("TerminationUltimateAmmo",10)
VPKH E 1 Offset(1,32)ACS_NamedExecuteWithResult("VC_SetState",10) VPKH E 0 A_TakeInventory("TerminationUltimateAmmo",10)
loop
UltEnd:
VPKH B 0 A_TakeInventory("UltAttackFlag",1)
TNT1 A 0 A_ChangeFlag("INVULNERABLE",0)
VPKH EDCB 5 A_TakeInventory("InvProtection")
Goto Ready2
}
}

actor BatCountryBubbleBat
{
PROJECTILE
+SEEKERMISSILE
+LOOKALLAROUND
damagetype "VANPookin"
Obituary "$OB_VANPOOKIN8"
species "VANPookinType"
+THRUSPECIES
+NOCLIP
+DONTREFLECT
Damage (0)
Radius 32
Height 32
Speed 20
scale 2.5
States
{
Spawn:
TNT1 AA 0 A_GiveInventory("ProjectileCode",1)
TNT1 A 1
TNT1 A 0 A_ChangeFlag("NOCLIP",0)
Spawn2:
BBAT GHI 5 A_GiveToTarget("PharaohUltCooldown",1)
BBAT IIIII 0 A_SeekerMissile (90, 360, SMF_LOOK|SMF_PRECISE, 256, 8)
loop
Death:
NAPA E 0 A_PlaySoundEx("weapon/napalm","Body")
NAPA E 0 A_Explode(24,128,32)
NAPA EFGHIJKLMNOPQRS 2
stop
}
}

actor TerminatorUltimateAlarm
{
PROJECTILE
+NOINTERACTION
+DONTBLAST
damage (0)
radius 1
height 1
States
{
Spawn:
TNT1 AA 0
TNT1 A 0 A_PlaySoundEx("misc/alarmlong","weapon",0,1)
TNT1 A 55
TNT1 A 0 A_PlaySoundEx("misc/alarmlong","weapon",0,1)
TNT1 A 55
stop
}
}