actor BondingPasteWep_NormalBar : NormalBar {args 4,92}
Actor BondingPasteWep : BaseMM8BDMWep
{
Weapon.AmmoUse 1
Weapon.AmmoGive 40
Weapon.SlotNumber 3
Obituary "$OB_BONDINGPASTE"
Tag "$TAG_BONDINGPASTE"
Inventory.Pickupmessage "$PU_BONDINGPASTE"
weapon.ammotype "BondingPasteAmmo"
inventory.icon "BPSTICON"
States
{
SpawnLoop:
BPST Z -1
loop
Ready:
BPST A 0 ACS_NamedExecuteWithResult("core_weaponcolor",CLR_BONDINGPASTE)
ReadyC:
BPST A 1 A_WeaponReady
Goto Ready+1
Deselect:
BPST A 0 
goto DeselectSwap
Select:
BPST A 0 
goto SelectSwap
Fire:
BPST A 0 A_JumpIfNoAmmo("NoAmmo")
BPST A 0 A_PlaySoundEx("weapon/bondingpaste","Weapon")
BPST A 0 A_JumpIfInventory("IsBot",1,"BotCheck")
BPST A 0 A_FireCustomMissile("BondingPasteShot",frandom(-3,3),1,8,0)
RangedFire:
BPST BC 2
BPST A 1
BPST A 0 A_Refire
Goto Ready+1
NoAmmo:
BPST A 1 ACS_NamedExecuteAlways("core_noammo",0)
Goto Ready+1
BotCheck:
BPST A 0 A_FireCustomMissile("BondingPasteShot",frandom(-3,3),1,8,0,0,CallACS("Enc_BotLobDist",28,1,0))
Goto RangedFire
}
}

Actor BondingPasteAmmo : Ammo
{
	Inventory.Amount 1
	Inventory.MaxAmount 40
	+INVENTORY.IGNORESKILL
}

actor BondingPasteShot : BasicProjectile
{
translation "198:198=92:92","192:192=86:86"
PROJECTILE
+FORCEXYBILLBOARD
Damage (CallACS("vile_cbm_damage",9))
damagetype "BondingPaste"
Obituary "$OB_BONDINGPASTE"
Height 8
Radius 8
-NOGRAVITY
Scale 2.0
speed 28
States
{
Spawn:
BPST E 0
BPST E 2 A_CheckFloor("Death")
loop
Crash:
XDeath:
BPST GGH 1
stop
Death:
BPST E 0 A_JumpIf(z-floorz<1,"Death2")
BPST E 1 A_GiveInventory("CutterFlag",1)
BPST E 0 A_JumpIfInventory("CutterFlag",175,"Xdeath")
loop
Death2:
BPST E 1 A_SpawnItemEx("BondingBlob",0,0,0)
stop
}
}

Actor BondingBlob : BasicProjectile
{
translation "198:198=92:92","192:192=86:86"
+MISSILE
+MOVEWITHSECTOR
+NODAMAGETHRUST
+NOBLOOD
+DONTSPLASH
+NOEXPLODEFLOOR
+RIPPER
+NOTARGETSWITCH
+NOTAUTOAIMED
-NOGRAVITY
Damage (0)
damagetype "BondingPaste"
Obituary "$OB_BONDINGPASTE"
Height 5
Radius 8
scale 3.0
yscale 2.0
mass 99999
reactiontime 250
states
{
Spawn:
BPST J 0
BPST J 0 A_PlaySoundEx("weapon/bondingland","Weapon")
BPST J 0 ACS_NamedExecuteAlways("enc_RadiusSlow",0,24)
BPST JKL 2 A_Stop
Goto SlideWait
SlideWait:
BPST M 1 A_GiveInventory("CutterFlag",1)
BPST M 0 A_JumpIf(z-floorz>0,"NewShot")
BPST M 0 A_JumpIfInventory("CutterFlag",245,"Death")
loop
NewShot:
BPST M 0 A_SpawnItemEx("BondingPasteShot",0,0,0,momx,momy,momz,0,SXF_ABSOLUTEMOMENTUM)
Goto Death 
Death:
TNT1 A 0
stop
}
}

actor BondingPasteSlow : PowerSpeed {Powerup.Duration 18 Speed 0.40}
