actor HumBugWep_NormalBar : NormalBar{args 211, 197}
actor HumBugWep : BaseMM8BDMWep
{ 
Weapon.AmmoUse 14
Weapon.AmmoGive 56
Weapon.SlotNumber 6
Inventory.Pickupmessage "$PU_HUMBUG"
Obituary "$OB_HUMBUG"
Tag "$TAG_HUMBUG"
weapon.ammotype "HumBugAmmo"
inventory.icon "HBUGICON"
States
{
SpawnLoop:
HBUG Z 1
loop
Ready:
HBUG A 0 ACS_NamedExecuteWithResult("core_weaponcolor",COLOR_HUMBUG)
HBUG A 0 A_JumpIfNoAmmo("ReadyNoAmmo")
HBUG A 1 A_WeaponReady
Goto Ready+1
ReadyC: Goto Ready+1
ReadyNoAmmo:
HBUG P 1 A_WeaponReady
HBUG P 0 A_JumpIfNoAmmo("ReadyNoAmmo")
Goto Ready+1
Deselect:
HBUG A 0
goto DeselectSwap
Select:
HBUG A 0
goto SelectSwap
Fire:
HBUG A 0 A_JumpIfNoAmmo("NoAmmo")
HBUG A 0 A_PlaySoundEx("weapon/humbugstart","Weapon")
HBUG A 0 A_FireCustomMissile("HumBug",0,1,0,0)
HBUG BCDEFGHHHHHH 3
HBUG A 0 A_JumpIfNoAmmo("NoneWait")
HBUG A 4 Offset(0,42)
HBUG A 12 A_WeaponReady(WRF_NOSWITCH)
HBUG A 0 A_Refire
Goto Ready+1
NoneWait:
HBUG P 4 Offset(0,42)
HBUG P 12 A_WeaponReady(WRF_NOSWITCH)
goto Ready+1
NoAmmo:
HBUG P 1 ACS_NamedExecute("core_noammo",0)
Goto Ready+1
}
}

actor HumBugAmmo : Ammo
{
inventory.amount 1
inventory.maxamount 56
+INVENTORY.IGNORESKILL
}


actor HumBug : BasicProjectile
{
+RIPPER
+SKYEXPLODE
var int user_PierceRipper;
var int user_BugCount;
damagetype "HumBug"
Obituary "$OB_HUMBUG"
speed 0
Radius 16
Height 24
scale 2.5
damage (CallACS("vile_cbm_damage",47))
reactiontime 8
States
{
Spawn:
HBUG I 0
HBUG I 2 ThrustThingZ(0,5,0,0)
HBUG JK 2 ThrustThingZ(0,10,0,0)
HBUG L 0 A_ChangeVelocity(0, 0, 0, CVF_REPLACE)
HBUG L 0 ThrustThingZ(0,40,0,0)
SpawnLoop:
HBUG LMNLMNLMN 2 ThrustThingZ(0,8,0,1)
goto Death
Death:
HBUG A 0 A_PlaySoundEx("weapon/humbugscatter","Weapon")
HBUG A 0 A_SpawnItemEx("ExplosionEffect2", 0, 0, 0, 0, 0, 0, 0, SXF_WEPFXCOLOR)
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,0,0,-20,0,SXF_TRANSFERPOINTERS)
DeathLoop:
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,12,0,-8,0,SXF_TRANSFERPOINTERS)
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,8,0,-12,0,SXF_TRANSFERPOINTERS)
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,6,0,-14,0,SXF_TRANSFERPOINTERS)
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,4,0,-16,0,SXF_TRANSFERPOINTERS)
HBUG A 0 A_SpawnItemEx("HumBugScatter",0,0,-4,2,0,-18,0,SXF_TRANSFERPOINTERS)
TNT1 A 0 A_SetAngle(angle-45)
TNT1 A 0 A_SetUserVar(user_BugCount, user_BugCount+1)
TNT1 A 0 A_JumpIf(user_BugCount < 8, "DeathLoop")
stop
End:
TNT1 A 3
stop
}
}

actor HumBugScatter : BasicProjectile
{
scale 2.5
Radius 16
Height 16
damage (CallACS("vile_cbm_damage",12))
damagetype "HumBugBit"
Obituary "$OB_HUMBUG"
speed 0
States
{
Spawn:
HBUG O 1
loop
Death:
TNT1 A 0 A_PlaySoundEx("weapons/mm7/dangerwrapexplode", "Weapon")
TNT1 A 0 A_SpawnItemEx("ExplosionEffect2", 0, 0, 0, 0, 0, 0, 0, SXF_WEPFXCOLOR)
TNT1 A 1 A_Explode(CallACS("vile_cbm_damage",12), 96, 0, 0, 32)
stop
}
}