actor BearerClass : CustWepClassBase
{
Player.ScoreIcon "C_00X0X"
player.displayname "BearerClass"
player.soundclass "BearerClassC"

player.maxhealth 2000
health 2000
player.jumpz 10
player.forwardmove 0.6, 0.6
player.sidemove 0.58, 0.58

player.startitem "BearerClass_W"
player.startitem "MaximumBearAmmo",3
//player.startitem "BearerFlag"
//player.startitem "Spawn_HalfHitStunFlag"
//player.startitem "HalfHitStunFlag"


player.startitem "ThunderBeamWeakness"//
//player.startitem "CrashBombWeakness"
player.startitem "HardKnuckleWeakness"//
//player.startitem "DrillBombWeakness"
player.startitem "GyroAttackWeakness"
//player.startitem "FlameBlastWeakness"
player.startitem "ThunderBoltWeakness"
player.startitem "ThunderClawWeakness"
player.startitem "RemoteMineWeakness"//LightningBolt
player.startitem "BlackHoleBombWeakness"
player.startitem "ReboundStrikerWeakness"
player.startitem "PhotonMissileWeakness"
player.startitem "BalladeCrackerWeakness"
//player.startitem "ChainBlastWeakness"//

+NOSKIN
player.morphweapon "BearerClass_W"
PainSound "misc/M1_PAIN"

ReactionTime 0//Needed for morph

States
{
Spawn:
YD_B A 0
YD_B B 1
YD_B A 1
Goto Spawn+2
See:
YD_B BCDE 4
Goto Spawn
Missile:
YD_B FG 5
goto Spawn

ClassPain://A_PlaySoundEX("misc/MV_OUCH","Voice")
YD_B H 0
Goto MegamanPain
ClassDeath:
YD_B H 0
goto MegamanDeath

}
}

actor BearerClass_W : BaseMM8BDMWep_CBM
{
dropitem "ConfettiDeathSpawner"
Tag "$TAGC_1Y"
Weapon.AmmoUse 0
Weapon.AmmoGive 3
Obituary "$OB_BEARCLOSE"
weapon.ammotype "MaximumBearAmmo"
States
{
SpawnLoop:
C_00 X 1
loop

Deselect:
YD_H A 0
goto DeselectSwap
Select:
YD_H A 0
goto SelectSwap

Ready:
YD_H A 1 ACS_NamedExecuteWithResult("core_weaponcolor",DYE_YELLOWDEVIL)
YD_H A 0 ACS_NamedExecuteWithResult("core_weaponcolor",DYE_YELLOWDEVIL,1)//Needs a second call online
YD_H A 0 A_GunFlash("Flash",1)
goto Ready1
Ready1:
YD_H A 1 A_WeaponReady
wait

Flash:
TNT1 A 1
stop

Fire:
YD_H C 0
YD_H A 1 Offset(8,26)
YD_H C 1 Offset(8,26)
YD_H C 1 Offset(20,16)
YD_H C 1 Offset(30,6)
YD_H C 0 A_PlaySoundEx("wep/YD_Toss","weapon")
YD_H C 0 A_FireCustomMissile("YD_BearerCube",0,0,8,0)
YD_H D 2 Offset(20,8)
YD_H E 1 Offset(12,17)
YD_H E 1 Offset(2,27)
YD_H E 8 Offset(-10,37)
YD_H A 1 Offset(-8,36)
YD_H A 1 Offset(-6,35)
YD_H A 1 Offset(-4,34)
YD_H A 1 Offset(-2,33)
Goto Ready1
Altfire:
YD_H A 0 A_FireCustomMissile("YD_BearerPunch",0,0,8,0)
YD_H A 0 A_PlaySoundEx("wep/YD_Punch","Weapon")
YD_H B 2 Offset(-28,14)
YD_H BBBB 2 Offset(-56,-4)
YD_H B 2 Offset(-56,-4)
YD_H B 2 Offset(-56,-4)
YD_H B 2 Offset(-32,8)
YD_H A 2 Offset(-12,20)
YD_H A 2 A_WeaponReady(14)
Goto Ready1
}
}

actor MaximumBearAmmo : Ammo
{
inventory.amount 1
inventory.maxamount 3
+INVENTORY.IGNORESKILL
}

actor BearerFlag : Inventory{}

actor BearerJustCaptured_F : Powerup//Failsafe
{
Powerup.Duration 7
}
actor BearerJustMorphed_F : Powerup//Failsafe
{
Powerup.Duration 7
}


actor CBM_MorphPowerPropReset_P : CustomInventory
{
States
{
Pickup:
//Powerup actors
TNT1 A 0 A_TakeInventory("CBM_DisableJumpPower")
TNT1 A 0 A_TakeInventory("CBM_FlipJumpPower")
TNT1 A 0 A_TakeInventory("YamatomanSpinSlow")
TNT1 A 0 A_TakeInventory("CBM_Ratio5_6JumpPower")
TNT1 A 0 A_TakeInventory("CBM_Ratio8JumpPower")
TNT1 A 0 A_TakeInventory("CBM_Ratio7JumpPower")
TNT1 A 0 A_TakeInventory("CBM_Ratio1JumpPower")
TNT1 A 0 A_TakeInventory("CBM_QuickmanJumpPower")
/*
//Do not remove these
TNT1 A 0 A_TakeInventory("Core_PowerSlow")
TNT1 A 0 A_TakeInventory("Core_ShockedStop")
TNT1 A 0 A_TakeInventory("PlantTrapSlow")
TNT1 A 0 A_TakeInventory("CoolestIceSlow")
TNT1 A 0 A_TakeInventory("HalfShockedStop")
TNT1 A 0 A_TakeInventory("ShadeReleaseHasten")
TNT1 A 0 A_TakeInventory("SlashM_GoopSlow")
TNT1 A 0 A_TakeInventory("TenguTornadoHeldSlow")
TNT1 A 0 A_TakeInventory("PowerSplashSwiftSong")
TNT1 A 0 A_TakeInventory("GalaxyM_BHB_EscapeHasten")
TNT1 A 0 A_TakeInventory("ChillPuddleAllyHasten")
TNT1 A 0 A_TakeInventory("ChillM_ShotSlow1")
TNT1 A 0 A_TakeInventory("ChillM_ShotSlow2")
TNT1 A 0 A_TakeInventory("ChillM_ShotSlow3")
TNT1 A 0 A_TakeInventory("VenusBlastJumpHasten")
TNT1 A 0 A_TakeInventory("RaThorGroundBurstHasten")
*/
TNT1 A 0 A_TakeInventory("CBM_DisableSpeedPower")
TNT1 A 0 A_TakeInventory("CBM_BotFlipSpeedPower")
TNT1 A 0 A_TakeInventory("CBM_SwordmanSpeedPower")
TNT1 A 0 A_TakeInventory("CBM_120_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_125_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_130_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_140_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_165_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_175_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_185_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_200_SpeedPower")
TNT1 A 0 A_TakeInventory("CBM_250_SpeedPower")

//TNT1 A 0 A_TakeInventory("ShadowmanInvisAlpha")
//TNT1 A 0 A_TakeInventory("SearchmanInvisAlpha")

TNT1 A 0 A_TakeInventory("CBM_00_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_10_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_20_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_30_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_40_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_50_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_60_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_70_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_80_AlphaPower")
TNT1 A 0 A_TakeInventory("CBM_90_AlphaPower")

TNT1 A 0 A_TakeInventory("GravitymanFlipAirZPower")
TNT1 A 0 A_TakeInventory("GravitymanFlipWallZPower")

TNT1 A 0 A_TakeInventory("GravitymanFlipGravPower")
TNT1 A 0 A_TakeInventory("ShadeFlightGravPower")
TNT1 A 0 A_TakeInventory("GroundmanCeilingGravPower")

//TNT1 A 0 A_TakeInventory("BubbleFloodGravPower")
TNT1 A 0 A_TakeInventory("GravSlammerPower")
stop
}
}


actor CBM_UnMorphSuperFlagReset_P : CustomInventory
{
States
{
Pickup:
//SetActorProperty(0, APROP_Invulnerable, false);
TNT1 A 0 SetPlayerProperty(0,0,PROP_BUDDHA)
TNT1 A 0 SetPlayerProperty(0,0,PROP_NOTARGET)
TNT1 A 0 A_ChangeFlag(CANPUSHWALLS,true)
TNT1 A 0 A_ChangeFlag(DONTRIP,false)
TNT1 A 0 A_ChangeFlag(NORADIUSDMG,false)
//TNT1 A 0 A_ChangeFlag(INVULNERABLE,false)
TNT1 A 0 A_ChangeFlag(NONSHOOTABLE,false)
TNT1 A 0 A_ChangeFlag(CANTSEEK,false)
TNT1 A 0 A_ChangeFlag(INVISIBLE,false)
TNT1 A 0 A_ChangeFlag(DONTIDENTIFYTARGET,false)
TNT1 A 0 A_ChangeFlag(THRUSPECIES,false)
TNT1 A 0 A_ChangeFlag(SOLID,true)
TNT1 A 0 A_ChangeFlag(NOGRAVITY,false)
stop
}
}

actor CBM_FixMorphPower_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_GiveInventory("FixMorphJumpZ_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphGravity_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphAlpha_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphSpeed_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphScaleX_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphScaleY_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphFriction_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphAirJumpZ_Giv",1)
TNT1 A 0 A_GiveInventory("FixMorphWallJumpZ_Giv",1)
stop
}
}
actor CBM_ResetMorphPower_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_TakeInventory("FixMorphJumpZ_Pow")
TNT1 A 0 A_TakeInventory("FixMorphGravity_Pow")
TNT1 A 0 A_TakeInventory("FixMorphAlpha_Pow")
TNT1 A 0 A_TakeInventory("FixMorphSpeed_Pow")
TNT1 A 0 A_TakeInventory("FixMorphScaleX_Pow")
TNT1 A 0 A_TakeInventory("FixMorphScaleY_Pow")
TNT1 A 0 A_TakeInventory("FixMorphFriction_Pow")
TNT1 A 0 A_TakeInventory("FixMorphAirJumpZ_Pow")
TNT1 A 0 A_TakeInventory("FixMorphWallJumpZ_Pow")
stop
}
}

//Possession also gives this pickup
actor CBM_MorphFlagReset_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 //LightTeamFlag//ACS handles TeamFlags/FlagPickups

//TNT1 A 0 SetPlayerProperty(0,0,16)//Buddha
//TNT1 A 0 SetPlayerProperty(0,0,4)//TotallyFrozen
//TNT1 A 0 SetPlayerProperty(0,0,0)//Frozen
//TNT1 A 0 SetPlayerProperty(0,0,3)//Flight

//Important Gives
TNT1 A 0 A_GiveInventory("BearerFlag",1)//ACS uses this and disables all class items
//TNT1 A 0 A_GiveInventory("EnvironmentGravity",1)//Fix underwater gravity
TNT1 A 0 A_GiveInventory("CBM_BaseFlagPack")//A morph is a fresh spawn technically
TNT1 A 0 A_GiveInventory("NoFallingRespawn_CTF",1)

//Bonus Gives
//TNT1 A 0 A_GiveInventory("SemiStunArmor",1)


//CBM Zone

//Flags to end certain class actors/projectiles


//TNT1 A 0 A_GiveInventory("ClashFlag1",1)//Applies to Tornado as well
//TNT1 A 0 A_GiveInventory("ClashFlag2",1)
//TNT1 A 0 A_GiveInventory("ClashFlag3",1)
//TNT1 A 0 A_GiveInventory("ClashFlag4",1)
//TNT1 A 0 A_GiveInventory("ClashFlagT",1)

TNT1 A 0 A_TakeInventory("PressButton_Main_F")
TNT1 A 0 A_TakeInventory("PressButton_Alt_F")
TNT1 A 0 A_TakeInventory("PressButton_Jump_F")

TNT1 A 0 A_TakeInventory("VivifyFlag1")
TNT1 A 0 A_TakeInventory("VivifyFlag2")
TNT1 A 0 A_TakeInventory("VivifyFlag3")

TNT1 A 0 A_TakeInventory("VivifyCycle1")
TNT1 A 0 A_TakeInventory("VivifyCycle2")
TNT1 A 0 A_TakeInventory("VivifyCycle3")
TNT1 A 0 A_TakeInventory("VivifyCycle4")
TNT1 A 0 A_TakeInventory("VivifyCycle5")
TNT1 A 0 A_TakeInventory("VivifyCycle6")

//TNT1 A 0 A_TakeInventory("BotFlag1")
//TNT1 A 0 A_TakeInventory("BotFlag2")
//TNT1 A 0 A_TakeInventory("BotFlag3")

TNT1 A 0 A_ChangeFlag("FLOORHUGGER",0)//Elecman

//TNT1 A 0 A_TakeInventory("HalfHitStunFlag")
//TNT1 A 0 A_TakeInventory("NoHitStunFlag")
//TNT1 A 0 A_TakeInventory("HalfPushFlag")
//TNT1 A 0 A_TakeInventory("NoPushFlag")

//TNT1 A 0 A_GiveInventory("StopShield",1)
//TNT1 A 0 A_TakeInventory("ShieldCheck")
TNT1 A 0 A_TakeInventory("BasicArmor")
TNT1 A 0 A_TakeInventory("DynamicArmorDosage")
TNT1 A 0 A_TakeInventory("SpawningMisfire")
TNT1 A 0 A_TakeInventory("GuardUpFlag")
TNT1 A 0 A_TakeInventory("GuardDownFlag")
TNT1 A 0 A_TakeInventory("NoJumpCancel")
TNT1 A 0 A_TakeInventory("CutterFlag")


TNT1 A 0 A_TakeInventory("SlideVivifyFlag")
//TNT1 A 0 A_GiveInventory("StopShield")
TNT1 A 0 A_TakeInventory("PowerMeter")
TNT1 A 0 A_TakeInventory("PowerBlockFlag")
TNT1 A 0 A_TakeInventory("PowerAdaptorBlock")
TNT1 A 0 A_TakeInventory("RockKickFlag")
TNT1 A 0 A_TakeInventory("SecondSwing")
TNT1 A 0 A_TakeInventory("AutoCreationFlag")
TNT1 A 0 A_GiveInventory("JoeSelectKillFlag",1)
TNT1 A 0 A_TakeInventory("RyuL_Flag")
TNT1 A 0 A_TakeInventory("MegaShoryu")
TNT1 A 0 A_TakeInventory("RyuMainFlag")
TNT1 A 0 A_TakeInventory("RyuAltFlag")
TNT1 A 0 A_TakeInventory("RyuMainFlagX")
TNT1 A 0 A_TakeInventory("RyuAltFlagX")
TNT1 A 0 A_TakeInventory("RyuRecoverFlag")
TNT1 A 0 A_TakeInventory("RyuSuperFlag")
TNT1 A 0 A_TakeInventory("RyuShinShoryuFlag")

TNT1 A 0 A_TakeInventory("RollingCutterFlag")//
TNT1 A 0 A_TakeInventory("CutmanNoCutterF")
TNT1 A 0 A_TakeInventory("SuperArmTemp")
TNT1 A 0 A_TakeInventory("GutsmanFlag")
TNT1 A 0 A_TakeInventory("GutsDestroyFlag")
TNT1 A 0 A_TakeInventory("OilmanJump")

TNT1 A 0 A_TakeInventory("BubbleIsSwimming_F")
TNT1 A 0 A_GiveInventory("BubbleFloodUndeploy")
TNT1 A 0 A_TakeInventory("QuickManTrail")
//TNT1 A 0 A_GiveInventory("ClashFlag1")//might not be needed due to precise scripts?
//TNT1 A 0 A_GiveInventory("ClashFlag2")
//TNT1 A 0 A_GiveInventory("ClashFlag3")
//TNT1 A 0 A_GiveInventory("ClashFlag4")
TNT1 A 0 A_TakeInventory("HeatmanFlag")
TNT1 A 0 A_TakeInventory("HeatShieldFrame")
TNT1 A 0 A_TakeInventory("WoodArmorPower")
TNT1 A 0 A_TakeInventory("WoodSlamFlag")
TNT1 A 0 A_TakeInventory("WoodmanFlag")
TNT1 A 0 A_TakeInventory("DrWily_PanFlag")
TNT1 A 0 A_TakeInventory("WilyNoSuitWeakness")
TNT1 A 0 A_TakeInventory("AlienFlightFlag")

TNT1 A 0 A_TakeInventory("NeedleReved")
TNT1 A 0 A_TakeInventory("NeedlemanRevvingSlow")
TNT1 A 0 A_GiveInventory("GeminiCloneReset_P")
TNT1 A 0 A_TakeInventory("Quaking")
TNT1 A 0 A_GiveInventory("TopmanFullReset_P")
TNT1 A 0 A_TakeInventory("SparkmanHoldFlag")
TNT1 A 0 A_GiveInventory("ShadowmanFlashInvisOff_P")
//Add a flag check to DocRobot and friends to disable their acs hud stuff when bearer
TNT1 A 0 A_TakeInventory("ToadLeapFlag")
TNT1 A 0 A_TakeInventory("ToadLeapFlagX")
TNT1 A 0 A_TakeInventory("ToadLeapFlagE")
TNT1 A 0 A_TakeInventory("ManInGauseAmmo")
TNT1 A 0 A_GiveInventory("RingFlag",1)
TNT1 A 0 A_GiveInventory("RingFlag2",1)
TNT1 A 0 A_GiveInventory("DiveLockonCleanse",1)

TNT1 A 0 A_GiveInventory("GravitymanFullReset_P")
TNT1 A 0 A_TakeInventory("WaveHookNeedLand")
TNT1 A 0 A_TakeInventory("WaveHookWasFired")
TNT1 A 0 A_GiveInventory("WaveHookKillFlag",1)
TNT1 A 0 A_TakeInventory("StoneBossLeap")
TNT1 A 0 A_TakeInventory("StoneBossLeap2")//Shouldn't be able to grab skull/flag during core
TNT1 A 0 A_TakeInventory("StoneCoreBuddha")
TNT1 A 0 A_TakeInventory("GyroTrigger")
TNT1 A 0 A_TakeInventory("GyroTrigger2")//CBM_AviationOff_P
TNT1 A 0 A_TakeInventory("StarArmorPower")
TNT1 A 0 A_TakeInventory("DarkSniperCharge")
TNT1 A 0 A_TakeInventory("DarkSniperFlag")
TNT1 A 0 A_TakeInventory("Darkman3SnipingSlow")

TNT1 A 0 A_TakeInventory("WarpGo")
TNT1 A 0 A_GiveInventory("Plantman_DrainDisable_P")
TNT1 A 0 A_TakeInventory("WindInAir")
TNT1 A 0 A_TakeInventory("YamatoSpinFlag")
TNT1 A 0 A_TakeInventory("YamatomanSpinSlow")

TNT1 A 0 A_TakeInventory("UseJunkmanShield_F")
TNT1 A 0 A_TakeInventory("BurstTrigger")
TNT1 A 0 A_TakeInventory("DangerFly")
TNT1 A 0 A_TakeInventory("IBeFlyin")
TNT1 A 0 A_TakeInventory("HatinFlyin")
TNT1 A 0 A_TakeInventory("CloudNoItemFlag")
TNT1 A 0 A_GiveInventory("ShademanFullReset_P")
TNT1 A 0 A_GiveInventory("TurboCarEnd_P")

TNT1 A 0 A_TakeInventory("AstroFlight")
TNT1 A 0 A_TakeInventory("NoFlameFlag")
TNT1 A 0 A_GiveInventory("EndFlameFlag",1)
TNT1 A 0 A_TakeInventory("CameraFlag")
TNT1 A 0 A_TakeInventory("ClownMainFiredF")
TNT1 A 0 A_TakeInventory("ClownAltFlag")
TNT1 A 0 A_GiveInventory("TrimSearchBush1",1)
TNT1 A 0 A_GiveInventory("TrimSearchBush2",1)
TNT1 A 0 A_GiveInventory("TrimSearchBush3",1)
TNT1 A 0 A_GiveInventory("TrimSearchBush4",1)
TNT1 A 0 A_TakeInventory("SearchTargetID1")
TNT1 A 0 A_TakeInventory("SearchTargetID2")
TNT1 A 0 A_TakeInventory("SearchTargetID3")
TNT1 A 0 A_TakeInventory("SearchTargetID4")
TNT1 A 0 A_TakeInventory("PopsicleAmmo")
TNT1 A 0 A_TakeInventory("IceWaveHoldFlag")
TNT1 A 0 A_GiveInventory("VivifyDelay6",1)//Disables icicle warper
TNT1 A 0 A_TakeInventory("ThatFeltGoodAmmo",1)
TNT1 A 0 A_GiveInventory("AquaKillFlag",1)
TNT1 A 0 A_GiveInventory("DuoMeteorFlagRemove_P")
TNT1 A 0 A_TakeInventory("ODuoRamFlag")
TNT1 A 0 A_GiveInventory("Trio_RageDisable_P")

TNT1 A 0 A_GiveInventory("ConcreteCleanResetFlags")
TNT1 A 0 A_TakeInventory("WeaponCharge")//give 1 for tornado? is it possible to use something else
TNT1 A 0 A_TakeInventory("SplashWarbleFlag")
TNT1 A 0 A_GiveInventory("SplashEndSinging",1)
TNT1 A 0 A_TakeInventory("PlugmanLatch")
TNT1 A 0 A_TakeInventory("JewelmanItemFlag")
TNT1 A 0 A_GiveInventory("BeeFlag1",1)
TNT1 A 0 A_GiveInventory("BeeFlag2",1)
TNT1 A 0 A_TakeInventory("MagmamanIsIdle_F")
TNT1 A 0 A_TakeInventory("GalaxyAltFlag")
TNT1 A 0 A_TakeInventory("GalaxyPortFlag")
TNT1 A 0 A_TakeInventory("MissingGalaxyBHB")

TNT1 A 0 A_GiveInventory("BlademanFullReset_P")
TNT1 A 0 A_TakeInventory("PumpmanShieldFlag")
TNT1 A 0 A_TakeInventory("PumpmanNoHandleF")
TNT1 A 0 A_GiveInventory("PumpItemTrigger",1)
TNT1 A 0 A_TakeInventory("CommandoLeapFlag")
TNT1 A 0 A_TakeInventory("CommandoLeapFlag2")
TNT1 A 0 A_TakeInventory("ChillShield")
TNT1 A 0 A_TakeInventory("ChillSliding")
TNT1 A 0 A_TakeInventory("Chill_ItemCharge")
TNT1 A 0 A_TakeInventory("Chill_ItemCoolD")
TNT1 A 0 A_TakeInventory("Chill_ItemFlag")
TNT1 A 0 A_TakeInventory("NitroBikeWallBoostAttack")
TNT1 A 0 A_TakeInventory("NitroAirTimeFlag")
TNT1 A 0 A_GiveInventory("SolarM_FlashStateEnd_P")
TNT1 A 0 A_TakeInventory("PowerSolarM_HeadTiltSlow")
TNT1 A 0 A_TakeInventory("SolarM_AmmoDrainDelay")
TNT1 A 0 A_TakeInventory("SolarHoldFlag")
TNT1 A 0 A_TakeInventory("SolarHoldCoolDown")

TNT1 A 0 A_TakeInventory("DynamoHealingWeakness")
TNT1 A 0 A_TakeInventory("DynamoIsScanning")
TNT1 A 0 A_TakeInventory("DynamoItemFlag")
TNT1 A 0 A_TakeInventory("DynamoCoolDownFlag")
TNT1 A 0 A_TakeInventory("DynamoIsCharging")
TNT1 A 0 A_GiveInventory("DynamoM_TagEnd_F",1)
TNT1 A 0 A_TakeInventory("DynamomanHealingSlow")
TNT1 A 0 A_TakeInventory("DynamomanScanningSlow")
TNT1 A 0 A_TakeInventory("ColdCombo_Flag")
TNT1 A 0 A_TakeInventory("DinoDNAFlag")
TNT1 A 0 A_GiveInventory("GroundmanFullReset_P")
TNT1 A 0 A_TakeInventory("PirateMineFlag")
TNT1 A 0 A_TakeInventory("PirateMineSticky")
TNT1 A 0 A_TakeInventory("PBubbleFlag")
TNT1 A 0 A_TakeInventory("PRemoteFlag")
TNT1 A 0 A_TakeInventory("PirateBubblePopped")
TNT1 A 0 A_TakeInventory("PirateBDashFlag")
TNT1 A 0 A_TakeInventory("BurnerDiveFlag")
TNT1 A 0 A_TakeInventory("BurnerUseTrap_F")
TNT1 A 0 A_TakeInventory("MagicBallEnd")
TNT1 A 0 A_TakeInventory("MagicBallEndFix")
TNT1 A 0 A_TakeInventory("TheKingStamina")
TNT1 A 0 A_TakeInventory("TheKingLostShield")
TNT1 A 0 A_TakeInventory("TheKingShieldChargeSlow")

TNT1 A 0 A_TakeInventory("BRGCloneFlag")
TNT1 A 0 A_TakeInventory("MWS_ItemFlag")
TNT1 A 0 A_TakeInventory("MWS_ItemHoldIt")
TNT1 A 0 A_TakeInventory("MWS_ItemForceFail")
TNT1 A 0 A_TakeInventory("HSHDashFlagX")

TNT1 A 0 A_TakeInventory("EnkerAbsorbCount")
TNT1 A 0 A_TakeInventory("QuintYesPogo")
TNT1 A 0 A_TakeInventory("QuintNoPogo")
TNT1 A 0 A_TakeInventory("QuintDive")
TNT1 A 0 A_TakeInventory("QuintIsAir")
TNT1 A 0 A_TakeInventory("QuintSpinDiveSlow")
TNT1 A 0 A_TakeInventory("RaThorHoldFlag")
TNT1 A 0 A_TakeInventory("ThorIsLungingF")
TNT1 A 0 A_TakeInventory("ThorIsGrabbingF")
TNT1 A 0 A_TakeInventory("RaThorGrabHoldSlow")

TNT1 A 0 A_TakeInventory("Terra_ChaserDawdle")
TNT1 A 0 A_TakeInventory("TerraChargeFlag")
TNT1 A 0 A_TakeInventory("TerraBuddyFlag")
TNT1 A 0 A_TakeInventory("Terra_ChaserVivify")
TNT1 A 0 A_TakeInventory("TerraCurrentRadius")
TNT1 A 0 A_GiveInventory("Merc_BlobOff_F",1)
TNT1 A 0 A_TakeInventory("MercuryClimbing_F")
TNT1 A 0 A_TakeInventory("MarsIsATank")
TNT1 A 0 A_TakeInventory("MarsSpreadFlag")
TNT1 A 0 A_TakeInventory("JupiterHovering")
TNT1 A 0 A_TakeInventory("JupiterNeedsToLand")
TNT1 A 0 A_TakeInventory("JupiterLaunching")
TNT1 A 0 A_TakeInventory("JupiterCharge")
TNT1 A 0 A_TakeInventory("UranusAnger")
TNT1 A 0 A_TakeInventory("UranusCarrying")
TNT1 A 0 A_TakeInventory("NeptuneSalty")
TNT1 A 0 A_TakeInventory("PowerSaltyBoat")
TNT1 A 0 A_TakeInventory("NeptuneSaltyWeakness")
stop
}
}

actor Core_MorphFlagReset_P : CustomInventory
{
States
{
Pickup:
//Other core flags?
TNT1 A 0 A_TakeInventory("PlayerPropertyGrounded")

TNT1 A 0 A_TakeInventory("ChillFreezeGravity")
TNT1 A 0 A_TakeInventory("ChillFreezeJump")

//Flags from core possession taker
TNT1 A 0 A_TakeInventory("OilBoat")
// No invisible holders
TNT1 A 0 A_TakeInventory("RespawnProtectionAlpha")
TNT1 A 0 A_TakeInventory("CentaurFlashNoAlpha")
TNT1 A 0 A_TakeInventory("CentaurFlashHalfAlpha")
TNT1 A 0 A_TakeInventory("CentaurFlashQuarterAlpha")

// No excess flags or noise spam
TNT1 A 0 A_TakeInventory("WeaponCharge")
TNT1 A 0 A_TakeInventory("WeaponChargeLevel")
TNT1 A 0 A_TakeInventory("OilSliderFlag")
TNT1 A 0 A_TakeInventory("HomingSniperCharge")
TNT1 A 0 A_TakeInventory("PhotonMissileCharge")
TNT1 A 0 A_TakeInventory("SuperArmTemp")
TNT1 A 0 A_TakeInventory("DeepDiggerFlagL")
TNT1 A 0 A_TakeInventory("DeepDiggerFlagR")
TNT1 A 0 A_TakeInventory("PharaohCharge")
TNT1 A 0 A_TakeInventory("WheelCutterCheck")
TNT1 A 0 A_TakeInventory("SakugarneActive")
TNT1 A 0 A_TakeInventory("MirrorBusterFlag")

// No shield leftovers
TNT1 A 0 A_GiveInventory("StopShield",1)
TNT1 A 0 A_TakeInventory("ShieldCheck")
TNT1 A 0 A_TakeInventory("LeafShieldCharge")
TNT1 A 0 A_TakeInventory("ScorchWheelPowerup")
TNT1 A 0 A_TakeInventory("WheelCount")
TNT1 A 0 A_TakeInventory("JewelShieldCheck")
TNT1 A 0 A_GiveInventory("JewelSatelliteDisable")
TNT1 A 0 A_TakeInventory("JunkShieldCharge")
TNT1 A 0 A_GiveInventory("BlackHoleTrigger")
TNT1 A 0 A_TakeInventory("BlackHoleAmmo", 4,1)
TNT1 A 0 A_TakeInventory("PlantWeakener")
TNT1 A 0 A_TakeInventory("SkullShieldCheck")
TNT1 A 0 A_TakeInventory("WaterShieldCheck")
TNT1 A 0 A_GiveInventory("WaterShieldStop",1)//Gets taken on demorph
stop
}
}


actor Core_MorphFlagReset2_P : CustomInventory
{
States
{
Pickup://All the flags
//Likely repeats of above
TNT1 A 0 A_TakeInventory("WeaponCharge")
TNT1 A 0 A_TakeInventory("BassBusterRage")
TNT1 A 0 A_TakeInventory("FistFlag")
TNT1 A 0 A_TakeInventory("AdapterWaitCount")

TNT1 A 0 A_TakeInventory("CutterFlag")
//TNT1 A 0 A_GiveInventory("DespawnOldCutter",1)
TNT1 A 0 A_TakeInventory("SuperArmTemp")
TNT1 A 0 A_TakeInventory("OilSliderFlag")
TNT1 A 0 A_TakeInventory("OilSliderFlightFlag")
TNT1 A 0 A_TakeInventory("OilBoat")

TNT1 A 0 A_TakeInventory("LeafShieldCharge")

TNT1 A 0 A_TakeInventory("SpinTime")
TNT1 A 0 A_TakeInventory("EndSpin")

TNT1 A 0 A_TakeInventory("DrillFlag")
TNT1 A 0 A_TakeInventory("PharaohCharge")
TNT1 A 0 A_TakeInventory("DiveCounter")
TNT1 A 0 A_TakeInventory("SkullShieldCheck")

TNT1 A 0 A_TakeInventory("GyroFlag")

TNT1 A 0 A_TakeInventory("CentaurFlashTime")
TNT1 A 0 A_TakeInventory("KnightFlag")
TNT1 A 0 A_TakeInventory("KnightDouble")
TNT1 A 0 A_TakeInventory("PlantWeakener")

TNT1 A 0 A_TakeInventory("JunkShieldCharge")
TNT1 A 0 A_TakeInventory("NoiseCrushCaught")
TNT1 A 0 A_TakeInventory("WheelCount")

TNT1 A 0 A_TakeInventory("HomingSniperCharge")
TNT1 A 0 A_TakeInventory("BallFlag")
TNT1 A 0 A_TakeInventory("KickedBall")
TNT1 A 0 A_TakeInventory("BallKickCounter")

TNT1 A 0 A_GiveInventory("JewelSatelliteDisable")
TNT1 A 0 A_TakeInventory("BlackHoleFlag")

TNT1 A 0 A_TakeInventory("WaterShieldShoot")
TNT1 A 0 A_TakeInventory("WaterShieldCheck")
TNT1 A 0 A_GiveInventory("WaterShieldStop")
TNT1 A 0 A_TakeInventory("CommandoSwitch")
TNT1 A 0 A_TakeInventory("ChillFreezeGravity")
TNT1 A 0 A_TakeInventory("ChillFreezeJump")
TNT1 A 0 A_TakeInventory("WheelCutterCheck")
//TNT1 A 0 A_GiveInventory("WheelCutterDestroy")
TNT1 A 0 A_TakeInventory("SolarBlazeFlag")

TNT1 A 0 A_TakeInventory("SpreadDrillFlag")
TNT1 A 0 A_TakeInventory("RemoteMineFlag")

TNT1 A 0 A_TakeInventory("MirrorBusterSwitch")
TNT1 A 0 A_TakeInventory("MirrorBusterFlag")
TNT1 A 0 A_TakeInventory("SakugarneActive")

TNT1 A 0 A_TakeInventory("PhotonMissileCharge")
TNT1 A 0 A_TakeInventory("BlackHoleShieldCheck")
TNT1 A 0 A_TakeInventory("DeepDiggerFlagL")
TNT1 A 0 A_TakeInventory("DeepDiggerFlagR")
TNT1 A 0 A_TakeInventory("BreakDashCharge")
TNT1 A 0 A_TakeInventory("BreakDashHit")
stop
}
}
/*
actor CBM_PossessionFlashEnable_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_SpawnItemEx("CBM_PossessionFlashEnable_H")
stop
}
}
actor CBM_PossessionFlashEnable_H : BasicWatcher
{
+NOTIMEFREEZE
States
{
Spawn:
TNT1 A 0
TNT1 A 2
TNT1 A 0 A_GiveToTarget("CBM_FlashEnable_P",1)
stop
}
}
actor CBM_FlashEnable_P : CustomInventory
{
States
{
Pickup:
TNT1 A 0 A_JumpIf(Health <= 0,"Flash")
TNT1 A 0 A_GunFlash("Flash",1)
stop
Flash:
TNT1 A 0
stop
}
}
*/
actor YD_BearerCube : ProjSpawnFuncActor
{
PROJECTILE
Obituary "$OB_BEARMAIN1"
damagetype "YellowDevilB"
-NOGRAVITY
+SKYEXPLODE
+EXPLODEONWATER
damage (250)
Radius 25
Height 20
speed 29
scale 2.5
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_ChangeVelocity(0,0,3.5)
TNT1 A 0 A_Jump(256,1,2,3,4)
YD_H FGHI 3
Goto Spawn+3
Death:
TNT1 A 0 A_SetGravity(0.0)
TNT1 A 0 A_PlaySoundEx("wep/YD_Sploosh","Weapon")
TNT1 AAAA 1 A_SpawnItemEx("YD_BearerCubeBit",random(1,8),0,random(4,20),frandom(2,15),0,frandom(8,13),random(0,359))
stop
}
}

actor YD_BearerCubeBit : ProjSpawnFuncActor
{
PROJECTILE
Obituary "$OB_BEARMAIN2"
damagetype "YellowDevilB"
+THRUACTORS
+DONTSPLASH
-NOGRAVITY
damage (0)
Radius 8//25
Height 8//20
speed 14
scale 2.5
States
{
Spawn:
TNT1 A 0
TNT1 A 0 A_SetScale(ScaleX-frandom(0,1))
TNT1 A 0 A_Jump(256,1,2,3)
YD_H JKL 3
goto Spawn+3
Death:
TNT1 A 1
stop
}
}

actor PainYellowDevilPHit : Basic_PainFling_H{Args 77,60,0}
actor DeathYellowDevilPHit : Basic_DeathFling_H{Args 81,120,0}

actor YD_BearerPunch : ProjSpawnFuncActor
{
PROJECTILE
damagetype "YellowDevilP"
Obituary "$OB_BEARALT"
+DONTBLAST
+DONTREFLECT
reactiontime 1
damage (500)
Radius 20
Height 20
speed 60
scale 2.5
States
{
Spawn:
YD_H O 0
YD_H O 1 A_CountDown
wait
Death:
YD_H O 0 A_Explode(500,40,0)
goto XDeath
XDeath:
YD_H O 0 A_Stop
YD_H OMOP 2
//OMFX BOBC 2
stop
}
}

