actor Kzan 21712
{
//$Category MM8BDM-Interactive Props
//$Title Kzan
//$Arg0 Rise Height (Height/32)
obituary "%o's armor was pierced by a Kzan."
-FORCEXYBILLBOARD
+NOGRAVITY
+SOLID
+THRUSPECIES
+THRUGHOST 
+DONTBLAST
+FORCEYBILLBOARD
height 56
radius 40
scale 2.5
species "MovingPlatform"
States
{
Spawn:
WSKZ A 0 ACS_NamedExecuteAlways("core_stickyLifts", 0, STICKYMODE_GUTSLIFT)
WSKZ A 1
Goto Detect
Detect:
WSKZ A 0 A_SpawnItemEx("KzanDetect", 0, 0, 61)
Goto Detecting
Detecting:
WSKZ A 0 A_JumpIfInventory("KzanFlag", 1, "Rising")
WSKZ A 2
loop
Rising:
WSKZ A 3 A_TakeInventory("KzanFlag",1)
WSKZ A 0 ThrustThingZ(0, 24, 0, 0)
WSKZ A 1 A_JumpIf(z-floorz>=args[0]*32, "Hang")
loop
Hang:
WSKZ A 0 A_stop
WSKZ A 24
WSKZ A 0 A_SpawnItemEx("KzanSpike", 0, 0, -32)
Goto Falling
Falling:
WSKZ A 0 A_JumpIfInventory("KzanSpikeHit", 1, "Stopping")
WSKZ A 0 ThrustThingZ(0, -38, 0, 0)
WSKZ A 1 A_JumpIf(z-floorz == 0, "Detect")
loop
Stopping:
WSKZ A 0 A_stop
WSKZ A 0 A_JumpIf(z-floorz >= 65, "Stopped")
WSKZ A 1 ThrustThingZ(0, 38, 0, 0) //Just in case someone manages to slip in w/ tengu blade or something
goto Stopping+1
Stopped:
WSKZ A 0 A_stop
WSKZ A 0 A_TakeInventory("KzanSpikeHit", 1)
WSKZ A 0 A_SpawnItemEx("KzanSpike", 0, 0, -20) //I'm gonna keep hurting you until you go away
WSKZ A 3 A_JumpIfInventory("KzanSpikeHit", 1, "Stopped")
Goto Falling
}
}

actor KzanDetect
{
PROJECTILE
+LOOKALLAROUND
+SKYEXPLODE
+DONTREFLECT
+DONTBLAST
Speed 0
Damage (0)
radius 40
height 5
scale 2.5
States
{
Spawn:
TNT1 A 2
loop
Death:
TNT1 A 0
TNT1 A 0 A_GiveToTarget("KzanFlag", 1)
stop
}
}

Actor KzanSpike
{
Damagetype "Spiney"
PROJECTILE
+LOOKALLAROUND
+SKYEXPLODE
+DONTREFLECT
+DONTBLAST
+THRUGHOST
Speed 0
Damage (0)
radius 40
height 2
scale 2.5
States
{
Spawn:
TNT1 A 1 ThrustThingZ(0, -38, 0, 0)
loop
Crash:
TNT1 A 0 
TNT1 A 0 A_GiveToTarget("KzanSpikeHit", 1)
stop
}
}

actor Covern
{
//$Category MM8BDM-Props
+NOGRAVITY
-SOLID
+FLOATBOB
+DONTBLAST
+RANDOMIZE
scale 2.5
Height 32
radius 32
States
{
Spawn:
TNT1 A 35
WSCV ABCDEFDEFDEFDEFDEFDEFGH 8
TNT1 A 35
loop
}
}

actor Phantoon
{
//$Category MM8BDM-Props
-SOLID
+NOGRAVITY
+FLOATBOB
+DONTBLAST
height 128
radius 80
Scale 2.5
RenderStyle "Translucent"
Alpha 0
States
{
Spawn:
TNT1 A 1
TNT1 A 1 A_Jump(32, "Jumpscare")
Goto Normal

Normal:
PHNT EDED 8 A_FadeIn(0.2)
PHNT EDEDEDED 8 
PHNT C 8
PHNT BABABABABABABABABABABA 8
Goto Leave

Jumpscare:
PHNT B 8 A_FadeIn(1)
PHNT ABABABABABABABABABABA 8 
PHNT C 8
Goto Leave

Leave:
PHNT C 8
PHNT ED 8
PHNT E 0 A_SpawnItemEx("PhantoonFire", 80, 80, 32)
PHNT ED 8
PHNT D 0 A_SpawnItemEx("PhantoonFire", 80, -80, 32)
PHNT ED 8
PHNT E 0 A_SpawnItemEx("PhantoonFire", -80, 80, 32)
PHNT ED 8
PHNT D 0 A_SpawnItemEx("PhantoonFire", -80, -80, 32)
PHNT ED 8
PHNT C 8
PHNT BABABABABABABABABABABA 8
PHNT EDEDED 8 A_FadeOut(0.2)
TNT1 A 0
stop
}
}

actor PhantoonFire
{
//$Category MM8BDM-Props
-SOLID
+NOGRAVITY
+DONTBLAST
+FLOATBOB
+RANDOMIZE
height 32
radius 16
Scale 2.5
RenderStyle "Translucent"
Alpha 0
States
{
Spawn:
TNT1 A 1
PHNF ABAB 4 A_FadeIn(0.2)
PHNF ABC 4
PHNF DEFDEFDEFDEFDEFDEFDEFDEFDEFDEFDEFDEF 4
PHNF DEFDEFDEFDEFDEFDEFDEFDEF 4
PHNF GHI 4
stop
}
}

actor MetroidAtomic
{
//$Category MM8BDM-Interactive Props
+SOLID
+NOGRAVITY
+DONTBLAST
PROJECTILE
+HEXENBOUNCE
+ALLOWBOUNCEONACTORS
+CANBOUNCEWATER
WALLBOUNCEFACTOR 1.0
BOUNCEFACTOR 1.0
+BRIGHT
height 16
radius 16
Scale 2.5
speed 12
reactiontime 150
States
{
Spawn:
WRSA ABCDEF 4
loop
}
}

actor MetroidRipper
{
//$Category MM8BDM-Interactive Props
+SOLID
+NOGRAVITY
+DONTBLAST
PROJECTILE
+HEXENBOUNCE
+ALLOWBOUNCEONACTORS
+CANBOUNCEWATER
WALLBOUNCEFACTOR 0.91
BOUNCEFACTOR 0.91
+ACTIVATEMCROSS
height 16
radius 16
Scale 2.5
speed 30
reactiontime 150
States
{
Spawn:
WSRP A -1
loop
}
}

actor MetroidWreckedShipItems 21714
{
//$Category MM8BDM-Props
//$Arg0 Graphic Type
//$Arg0Enum { 0 = "Super Missile"; 1 = "Gravity Suit";}
//$Arg0Type 11
//$NotAngledheight 48
radius 16
height 16
scale 2.5
states
{
Spawn:
WSIT A 0
WSIT A 0 A_ChangeFlag(FLOATBOB, args[2])
WSIT A 0 A_JumpIf(args[0]==1, "GravitySuit")
goto SuperMissile
SuperMissile:
WSIT AB 4
loop
GravitySuit:
WSIT CD 4
loop
}
}

Actor KzanFlag : Once {}
Actor KzanSpikeHit : Once {}
