actor PlasmaCutterWep : BaseMM8BDMWep
{
//$Category MM8BDM-Weapons
//$Title Plasma Cutter
//$Sprite DOSWB0
Weapon.AmmoUse 2
Weapon.AmmoGive 28
Weapon.SlotNumber 4
Inventory.Pickupmessage "$PU_PLASMACUTTER"
Obituary "$OB_PLASMACUTTER"
Tag "$TAG_PLASMACUTTER"
weapon.ammotype "PlasmaCutterAmmo"
inventory.icon "PLASCU"
States
{
SpawnLoop:
DOSW B -1
loop
Ready:
PLAC A 0 ACS_ExecuteAlways(998,0,DOSREBORN_COLOR_VOLT)
PLAC A 1 A_WeaponReady
Goto Ready+1
Deselect:
TNT1 A 0 A_JumpIfInventory("PlasmaHit",1,"ChargeDeselect")
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Lower
PLAC A 1 A_Lower
goto Deselect+1
ChargeDeselect:
PLAC A 2 A_TakeInventory("PlasmaHit",999)
goto Deselect+1
Select:
TNT1 AAAAAAAAAAAAAAAAAAAAAA 0 A_Raise
PLAC A 1 A_Raise
Loop
Fire:
PLAC A 0 A_JumpIfInventory("PlasmaHit",1,"Fire2")
PLAC A 0 ACS_ExecuteAlways(991,0,DOSREBORN_COLOR_VOLT)
PLAC A 0 A_JumpIfNoAmmo("NoAmmo")
PLAC A 0 A_PlaySoundEx("weapon/slashclaw","Weapon")
PLAC A 0 A_FireCustomMissile("PlasmaCutter1",0,1,-11,-8)
PLAC BCDEFG 1 
PLAC H 7
PLAC HHHH 1 A_JumpIfInventory("PlasmaHit",1,"FireCharge")
PLAC A 1 A_JumpIfInventory("PlasmaHit",1,"FireCharge")
Goto Ready+1
FireCharge:
PLAC A 0 A_GunFlash("Sound.BusterCharge", GFF_NOEXTCHANGE)
Charged:
PLAC N 0 ACS_ExecuteAlways(991,0,DOSREBORN_COLOR_VOLT2)
PLAC N 1 A_WeaponReady
PLAC O 0 ACS_ExecuteAlways(991,0,DOSREBORN_COLOR_VOLT3)
PLAC O 1 A_WeaponReady
PLAC A 0 ACS_ExecuteAlways(991,0,DOSREBORN_COLOR_VOLT)
PLAC A 1 A_WeaponReady
loop
Fire2:
PLAC A 0 ACS_ExecuteAlways(991,0,DOSREBORN_COLOR_VOLT)
PLAC A 0 A_PlaySoundEx("weapon/thunderbolt","Weapon")
PLAC A 0 A_TakeInventory("PlasmaHit",999)
PLAC A 0 A_FireCustomMissile("PlasmaCutter2",0,0,11,-8)
PLAC IIIJKL 1
PLAC M 21
Goto Ready+1
NoAmmo:
PLAC A 1 ACS_Execute(979,0)
Goto Ready+1
Sound.BusterCharge:
TNT1 A 9 A_PlaySoundEx("weapon/adapterchargeloop","Weapon",0)
TNT1 A 1 A_JumpIfInventory("PlasmaHit",1,"Sound.BusterCharge")
stop
}
}
actor PlasmaCutterWepSH : PlasmaCutterWep replaces PlasmaCutterWep {+INVENTORY.RESTRICTABSOLUTELY Inventory.RestrictedTo megamans}

actor PlasmaCutterAmmo : Ammo
{
inventory.amount 1
inventory.maxamount 28
+INVENTORY.IGNORESKILL
}

actor PlasmaCutter1
{
PROJECTILE
Radius 16
Height 24
scale 2.5
damage (35)
+HITTRACER
+DONTREFLECT
+NOTARGETSWITCH
+BRIGHT

//+RIPPER
damagetype "PlasmaCutter"
Obituary "$OB_PLASMACUTTER"
speed 24
States
{
Spawn:
PSMC ABCDE 2
stop
Crash:
TNT1 A 0 A_JumpIfInventory("CanBeMegaArmed",1,"Give",AAPTR_TRACER)
//TNT1 A 0 A_JumpIfInventory("BAWS",1,"Give",AAPTR_TRACER)
goto Death
Death:
TNT1 A 1
stop
Give:
TNT1 A 0 A_JumpIfInventory("Survivor", 1, "Death", AAPTR_TRACER)
TNT1 A 2 A_GiveToTarget("PlasmaHit",1)
stop
}
}

actor PlasmaCutter2 : PlasmaCutter1
{
speed 24
Radius 24
Height 24
damage (87)
+RIPPER
DamageType "PlasmaCutter2"
States
{
Spawn:
PSMC FGHIJ 2
stop
}
}

actor PlasmaHit : Inventory
{
Inventory.Amount 1
Inventory.MaxAmount 1
+INVENTORY.IGNORESKILL
}

actor PlasmaShockFX
{
+NOINTERACTION
-SOLID
+NOGRAVITY
+BRIGHT
Scale 2.5
States
{
Spawn:
SPAS FGFGFGF 2
stop
}
}

actor PlasmaShock : Shocked
{
powerup.duration 6
}

actor PlasmaCutterProtect : PowerProtection
{
Powerup.Duration 15
damagefactor "PlasmaCutter2", 0.0
}