mirror of
https://github.com/ZDoom/gzdoom.git
synced 2025-01-31 05:40:44 +00:00
8dba322775
- Took the opportunity and fixed the logic for the Skull Rod's rain spawner. The old code which was part of the 3D floor submission was unable to work with portals at all. The new approach no longer tries to hide the dead projectile in the ceiling, it leaves it where it is and changes a few flags, so that its z-position can be used as reference to get the actual ceiling. This works for line portals, but for sector portals still requires some changes to sector_t::NextHighestCeilingAt to work, but at least this can be made to work unlike the old code. - added names for the player-related translations to A_SetTranslation. - fixed: Failure to resolve a function argument was checked for, too late. - made the parameter for A_SetTranslation a name instead of a string, because it is more efficient. We do not need full strings here.
184 lines
2.8 KiB
Text
184 lines
2.8 KiB
Text
|
|
class HereticWeapon : Weapon
|
|
{
|
|
Default
|
|
{
|
|
Weapon.Kickback 150;
|
|
}
|
|
}
|
|
|
|
|
|
// Phoenix Rod --------------------------------------------------------------
|
|
|
|
class PhoenixRod : Weapon native
|
|
{
|
|
Default
|
|
{
|
|
+WEAPON.NOAUTOFIRE
|
|
Weapon.SelectionOrder 2600;
|
|
Weapon.Kickback 150;
|
|
Weapon.YAdjust 15;
|
|
Weapon.AmmoUse 1;
|
|
Weapon.AmmoGive 2;
|
|
Weapon.AmmoType "PhoenixRodAmmo";
|
|
Weapon.Sisterweapon "PhoenixRodPowered";
|
|
Inventory.PickupMessage "$TXT_WPNPHOENIXROD";
|
|
Tag "$TAG_PHOENIXROD";
|
|
}
|
|
|
|
action native void A_FirePhoenixPL1();
|
|
|
|
States
|
|
{
|
|
Spawn:
|
|
WPHX A -1;
|
|
Stop;
|
|
Ready:
|
|
PHNX A 1 A_WeaponReady;
|
|
Loop;
|
|
Deselect:
|
|
PHNX A 1 A_Lower;
|
|
Loop;
|
|
Select:
|
|
PHNX A 1 A_Raise;
|
|
Loop;
|
|
Fire:
|
|
PHNX B 5;
|
|
PHNX C 7 A_FirePhoenixPL1;
|
|
PHNX DB 4;
|
|
PHNX B 0 A_ReFire;
|
|
Goto Ready;
|
|
}
|
|
}
|
|
|
|
class PhoenixRodPowered : PhoenixRod native
|
|
{
|
|
Default
|
|
{
|
|
+WEAPON.POWERED_UP
|
|
+WEAPON.MELEEWEAPON
|
|
Weapon.SisterWeapon "PhoenixRod";
|
|
Weapon.AmmoGive 0;
|
|
Tag "$TAG_PHOENIXRODP";
|
|
}
|
|
|
|
action native void A_InitPhoenixPL2();
|
|
action native void A_FirePhoenixPL2();
|
|
action native void A_ShutdownPhoenixPL2();
|
|
|
|
States
|
|
{
|
|
Fire:
|
|
PHNX B 3 A_InitPhoenixPL2;
|
|
Hold:
|
|
PHNX C 1 A_FirePhoenixPL2;
|
|
PHNX B 4 A_ReFire;
|
|
Powerdown:
|
|
PHNX B 4 A_ShutdownPhoenixPL2;
|
|
Goto Ready;
|
|
}
|
|
}
|
|
|
|
// Phoenix FX 1 -------------------------------------------------------------
|
|
|
|
class PhoenixFX1 : Actor
|
|
{
|
|
Default
|
|
{
|
|
Radius 11;
|
|
Height 8;
|
|
Speed 20;
|
|
Damage 20;
|
|
DamageType "Fire";
|
|
Projectile;
|
|
+THRUGHOST
|
|
+SPECIALFIREDAMAGE
|
|
SeeSound "weapons/phoenixshoot";
|
|
DeathSound "weapons/phoenixhit";
|
|
Obituary "$OB_MPPHOENIXROD";
|
|
}
|
|
|
|
native void A_PhoenixPuff();
|
|
|
|
States
|
|
{
|
|
Spawn:
|
|
FX04 A 4 BRIGHT A_PhoenixPuff;
|
|
Loop;
|
|
Death:
|
|
FX08 A 6 BRIGHT A_Explode;
|
|
FX08 BC 5 BRIGHT;
|
|
FX08 DEFGH 4 BRIGHT;
|
|
Stop;
|
|
}
|
|
|
|
override int DoSpecialDamage (Actor target, int damage, Name damagetype)
|
|
{
|
|
Sorcerer2 s2 = Sorcerer2(target);
|
|
if (s2 != null && random[HornRodFX2]() < 96)
|
|
{ // D'Sparil teleports away
|
|
s2.DSparilTeleport ();
|
|
return -1;
|
|
}
|
|
return damage;
|
|
}
|
|
|
|
}
|
|
|
|
// Phoenix puff -------------------------------------------------------------
|
|
|
|
class PhoenixPuff : Actor
|
|
{
|
|
Default
|
|
{
|
|
+NOBLOCKMAP
|
|
+NOGRAVITY
|
|
+NOTELEPORT
|
|
+CANNOTPUSH
|
|
RenderStyle "Translucent";
|
|
Alpha 0.4;
|
|
}
|
|
|
|
States
|
|
{
|
|
Spawn:
|
|
FX04 BCDEF 4;
|
|
Stop;
|
|
}
|
|
}
|
|
|
|
// Phoenix FX 2 -------------------------------------------------------------
|
|
|
|
class PhoenixFX2 : Actor native
|
|
{
|
|
Default
|
|
{
|
|
Radius 6;
|
|
Height 8;
|
|
Speed 10;
|
|
Damage 2;
|
|
DamageType "Fire";
|
|
Projectile;
|
|
RenderStyle "Add";
|
|
Obituary "$OB_MPPPHOENIXROD";
|
|
}
|
|
|
|
native void A_FlameEnd();
|
|
native void A_FloatPuff();
|
|
|
|
States
|
|
{
|
|
Spawn:
|
|
FX09 ABABA 2 BRIGHT;
|
|
FX09 B 2 BRIGHT A_FlameEnd;
|
|
FX09 CDEF 2 BRIGHT;
|
|
Stop;
|
|
Death:
|
|
FX09 G 3 BRIGHT;
|
|
FX09 H 3 BRIGHT A_FloatPuff;
|
|
FX09 I 4 BRIGHT;
|
|
FX09 JK 5 BRIGHT;
|
|
Stop;
|
|
}
|
|
}
|
|
|