mirror of
https://github.com/ZDoom/qzdoom-gpl.git
synced 2024-11-17 09:41:21 +00:00
352 lines
5.3 KiB
Text
352 lines
5.3 KiB
Text
// --------------------------------------------------------------------------
|
|
//
|
|
// Doom weapon base class
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class DoomWeapon : Weapon
|
|
{
|
|
Default
|
|
{
|
|
Weapon.Kickback 100;
|
|
}
|
|
}
|
|
|
|
|
|
// --------------------------------------------------------------------------
|
|
//
|
|
// Rocket launcher
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class RocketLauncher : DoomWeapon
|
|
{
|
|
Default
|
|
{
|
|
Weapon.SelectionOrder 2500;
|
|
Weapon.AmmoUse 1;
|
|
Weapon.AmmoGive 2;
|
|
Weapon.AmmoType "RocketAmmo";
|
|
+WEAPON.NOAUTOFIRE
|
|
Inventory.PickupMessage "$GOTLAUNCHER";
|
|
Tag "$TAG_ROCKETLAUNCHER";
|
|
}
|
|
States
|
|
{
|
|
Ready:
|
|
MISG A 1 A_WeaponReady;
|
|
Loop;
|
|
Deselect:
|
|
MISG A 1 A_Lower;
|
|
Loop;
|
|
Select:
|
|
MISG A 1 A_Raise;
|
|
Loop;
|
|
Fire:
|
|
MISG B 8 A_GunFlash;
|
|
MISG B 12 A_FireMissile;
|
|
MISG B 0 A_ReFire;
|
|
Goto Ready;
|
|
Flash:
|
|
MISF A 3 Bright A_Light1;
|
|
MISF B 4 Bright;
|
|
MISF CD 4 Bright A_Light2;
|
|
Goto LightDone;
|
|
Spawn:
|
|
LAUN A -1;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
class Rocket : Actor
|
|
{
|
|
Default
|
|
{
|
|
Radius 11;
|
|
Height 8;
|
|
Speed 20;
|
|
Damage 20;
|
|
Projectile;
|
|
+RANDOMIZE
|
|
+DEHEXPLOSION
|
|
+ROCKETTRAIL
|
|
SeeSound "weapons/rocklf";
|
|
DeathSound "weapons/rocklx";
|
|
Obituary "$OB_MPROCKET";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
MISL A 1 Bright;
|
|
Loop;
|
|
Death:
|
|
MISL B 8 Bright A_Explode;
|
|
MISL C 6 Bright;
|
|
MISL D 4 Bright;
|
|
Stop;
|
|
BrainExplode:
|
|
MISL BC 10 Bright;
|
|
MISL D 10 A_BrainExplode;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
// --------------------------------------------------------------------------
|
|
//
|
|
// Grenade -- Taken and adapted from Skulltag, with MBF stuff added to it
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class Grenade : Actor
|
|
{
|
|
Default
|
|
{
|
|
Radius 8;
|
|
Height 8;
|
|
Speed 25;
|
|
Damage 20;
|
|
Projectile;
|
|
-NOGRAVITY
|
|
+RANDOMIZE
|
|
+DEHEXPLOSION
|
|
+GRENADETRAIL
|
|
BounceType "Doom";
|
|
Gravity 0.25;
|
|
SeeSound "weapons/grenlf";
|
|
DeathSound "weapons/grenlx";
|
|
BounceSound "weapons/grbnce";
|
|
Obituary "$OB_GRENADE";
|
|
DamageType "Grenade";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
SGRN A 1 Bright;
|
|
Loop;
|
|
Death:
|
|
MISL B 8 Bright A_Explode;
|
|
MISL C 6 Bright;
|
|
MISL D 4 Bright;
|
|
Stop;
|
|
Grenade:
|
|
MISL A 1000 A_Die;
|
|
Wait;
|
|
Detonate:
|
|
MISL B 4 A_Scream;
|
|
MISL C 6 A_Detonate;
|
|
MISL D 10;
|
|
Stop;
|
|
Mushroom:
|
|
MISL B 8 A_Mushroom;
|
|
Goto Death+1;
|
|
}
|
|
}
|
|
|
|
// --------------------------------------------------------------------------
|
|
//
|
|
// Plasma rifle
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class PlasmaRifle : DoomWeapon
|
|
{
|
|
Default
|
|
{
|
|
Weapon.SelectionOrder 100;
|
|
Weapon.AmmoUse 1;
|
|
Weapon.AmmoGive 40;
|
|
Weapon.AmmoType "Cell";
|
|
Inventory.PickupMessage "$GOTPLASMA";
|
|
Tag "$TAG_PLASMARIFLE";
|
|
}
|
|
States
|
|
{
|
|
Ready:
|
|
PLSG A 1 A_WeaponReady;
|
|
Loop;
|
|
Deselect:
|
|
PLSG A 1 A_Lower;
|
|
Loop;
|
|
Select:
|
|
PLSG A 1 A_Raise;
|
|
Loop;
|
|
Fire:
|
|
PLSG A 3 A_FirePlasma;
|
|
PLSG B 20 A_ReFire;
|
|
Goto Ready;
|
|
Flash:
|
|
PLSF A 4 Bright A_Light1;
|
|
Goto LightDone;
|
|
PLSF B 4 Bright A_Light1;
|
|
Goto LightDone;
|
|
Spawn:
|
|
PLAS A -1;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
class PlasmaBall : Actor
|
|
{
|
|
Default
|
|
{
|
|
Radius 13;
|
|
Height 8;
|
|
Speed 25;
|
|
Damage 5;
|
|
Projectile;
|
|
+RANDOMIZE
|
|
RenderStyle "Add";
|
|
Alpha 0.75;
|
|
SeeSound "weapons/plasmaf";
|
|
DeathSound "weapons/plasmax";
|
|
Obituary "$OB_MPPLASMARIFLE";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
PLSS AB 6 Bright;
|
|
Loop;
|
|
Death:
|
|
PLSE ABCDE 4 Bright;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
// --------------------------------------------------------------------------
|
|
//
|
|
// BFG 2704
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class PlasmaBall1 : PlasmaBall
|
|
{
|
|
Default
|
|
{
|
|
Damage 4;
|
|
BounceType "Classic";
|
|
BounceFactor 1.0;
|
|
Obituary "$OB_MPBFG_MBF";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
PLS1 AB 6 Bright;
|
|
Loop;
|
|
Death:
|
|
PLS1 CDEFG 4 Bright;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
class PlasmaBall2 : PlasmaBall1
|
|
{
|
|
States
|
|
{
|
|
Spawn:
|
|
PLS2 AB 6 Bright;
|
|
Loop;
|
|
Death:
|
|
PLS2 CDE 4 Bright;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
// --------------------------------------------------------------------------
|
|
//
|
|
// BFG 9000
|
|
//
|
|
// --------------------------------------------------------------------------
|
|
|
|
class BFG9000 : DoomWeapon
|
|
{
|
|
Default
|
|
{
|
|
Height 20;
|
|
Weapon.SelectionOrder 2800;
|
|
Weapon.AmmoUse 40;
|
|
Weapon.AmmoGive 40;
|
|
Weapon.AmmoType "Cell";
|
|
+WEAPON.NOAUTOFIRE;
|
|
Inventory.PickupMessage "$GOTBFG9000";
|
|
Tag "$TAG_BFG9000";
|
|
}
|
|
States
|
|
{
|
|
Ready:
|
|
BFGG A 1 A_WeaponReady;
|
|
Loop;
|
|
Deselect:
|
|
BFGG A 1 A_Lower;
|
|
Loop;
|
|
Select:
|
|
BFGG A 1 A_Raise;
|
|
Loop;
|
|
Fire:
|
|
BFGG A 20 A_BFGsound;
|
|
BFGG B 10 A_GunFlash;
|
|
BFGG B 10 A_FireBFG;
|
|
BFGG B 20 A_ReFire;
|
|
Goto Ready;
|
|
Flash:
|
|
BFGF A 11 Bright A_Light1;
|
|
BFGF B 6 Bright A_Light2;
|
|
Goto LightDone;
|
|
Spawn:
|
|
BFUG A -1;
|
|
Stop;
|
|
OldFire:
|
|
BFGG A 10 A_BFGsound;
|
|
BFGG BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB 1 A_FireOldBFG;
|
|
BFGG B 0 A_Light0;
|
|
BFGG B 20 A_ReFire;
|
|
Goto Ready;
|
|
}
|
|
}
|
|
|
|
|
|
class BFGBall : Actor
|
|
{
|
|
Default
|
|
{
|
|
Radius 13;
|
|
Height 8;
|
|
Speed 25;
|
|
Damage 100;
|
|
Projectile;
|
|
+RANDOMIZE
|
|
RenderStyle "Add";
|
|
Alpha 0.75;
|
|
DeathSound "weapons/bfgx";
|
|
Obituary "$OB_MPBFG_BOOM";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
BFS1 AB 4 Bright;
|
|
Loop;
|
|
Death:
|
|
BFE1 AB 8 Bright;
|
|
BFE1 C 8 Bright A_BFGSpray;
|
|
BFE1 DEF 8 Bright;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
class BFGExtra : Actor
|
|
{
|
|
Default
|
|
{
|
|
+NOBLOCKMAP
|
|
+NOGRAVITY
|
|
RenderStyle "Add";
|
|
Alpha 0.75;
|
|
DamageType "BFGSplash";
|
|
}
|
|
States
|
|
{
|
|
Spawn:
|
|
BFE2 ABCD 8 Bright;
|
|
Stop;
|
|
}
|
|
}
|
|
|