ACTOR RocketeerClass : PlayerPawn
{
	Speed 1
	Health 100
	Radius 16
	Height 56
	Mass 100
	PainChance 255
	Player.ColorRange 112, 127
	Player.DisplayName "Rocketeer"
	Player.CrouchSprite "RKTC"
	player.startitem "NoDamageRocketLauncher", 1
	player.startitem "NoDamageRocketAmmo", 25
	player.startitem "megasphere", 1
	damagefactor "rocket", 0
	limitedtoteam 0
	+NOSKIN
	States
	{
	Spawn:
		RKTP A 0
		RKTP A 35
		RKTP A 0 A_JumpIf (health>=50, 2)
		RKTP A 0 ACS_Execute(110,0)
		RKTP A 0 A_JumpIfInventory("NoDamageRocketAmmo", 0, "Spawn")
		RKTP A 0 ACS_Execute(115,0)
	Loop
	See:
		RKTP ABCD 6 
	Goto Spawn
	Missile:
		RKTP E 12 
	Goto Spawn
	Melee:
		RKTP F 6 BRIGHT
	Goto Missile
	Pain:
		RKTP G 4 
		RKTP G 4 A_Pain
	Goto Spawn
	Death:
		RKTP H 10
		RKTP I 10 A_PlayerScream
		RKTP J 10 A_NoBlocking
		RKTP KLM 10
		RKTP N -1
	Stop
	XDeath:
		PLAY O 0 A_Stop
		RKTP O 5 A_SpawnItemEx ("HumanGibs",0,0,0,0,0,0,0,128)
		BRSP O 0 A_SkullPop("BlueHeadGib")
		RKTP P 5 A_XScream
		RKTP Q 5 A_NoBlocking
		RKTP RSTUV 5
		RKTP W -1
    Stop
	}
}

ACTOR NoDamageRocketAmmo : Ammo
{
  Inventory.PickupMessage "$GOTROCKET" // "Picked up a rocket."
  Inventory.Amount 1
  Inventory.MaxAmount 25
  Ammo.BackpackAmount 1
  Ammo.BackpackMaxAmount 25
  Inventory.Icon "ROCKA0"
  States
  {
  Spawn:
    ROCK A -1
    stop
  }
}


Actor NoDamageRocketLauncher : RocketLauncher
{
	Weapon.AmmoUse 1
	Weapon.AmmoType "NoDamageRocketAmmo"
	States
	{
	Ready:
		MISG A 1 A_WeaponReady
	Loop
	Deselect:
		MISG A 1 A_Lower
	Loop
	Select:
		MISG A 1 A_Raise
	Loop
	Fire:
		MISG A 2 
		MISG A 4 A_GunFlash
		MISG B 2
		MISG D 3 A_FireCustomMissile("NoDamageRocket",0,1,0,0)
		MISG C 3
		MISG BE 2
		MISG FG 1
		MISG A 0 A_ReFire
		Goto Ready
	Flash:
		MISF A 3 Bright A_Light1
		MISF B 2 Bright
		MISF C 2 Bright A_Light2
		MISF DE 3 Bright
		Goto LightDone
	Spawn:
		LAUN A -1
    Stop
	}
}

ACTOR NoDamageRocket
{
	Radius 11
	Height 8
	Speed 20
	Damage 0
	Projectile
	+ROCKETTRAIL
	+RANDOMIZE
	+DEHEXPLOSION
    +EXPLODEONWATER
    +SKYEXPLODE
	Projectile
	SeeSound "weapons/rocklf"
	DeathSound "weapons/dmisexpl"
	DamageType Rocket
	States
	{
	Spawn:
		MISL A 1 bright
	loop
	Death:
		MISL B 0 bright A_RadiusThrust (4096, 512, 0)
		MISL B 8 bright A_Explode
		MISL C 6 bright
		MISL D 4 bright
	stop
	}
}