ref: 31e1dbe5dda575cb2ecf0bb910aef476c73b0279
parent: 0a1bf3f3c8f8f0f69ceea5da11bb361855ea2cba
author: Turo Lamminen <turol@iki.fi>
date: Tue Aug 30 16:11:52 EDT 2022
Always pass three correctly typed pointers to heretic action functions
--- a/src/heretic/info.h
+++ b/src/heretic/info.h
@@ -1374,7 +1374,7 @@
spritenum_t sprite;
int frame;
int tics;
- void (*action) ();
+ void (*action) (struct mobj_s *, struct player_s *, struct pspdef_s *);
statenum_t nextstate;
int misc1, misc2;
} state_t;
--- a/src/heretic/p_action.h
+++ b/src/heretic/p_action.h
@@ -20,132 +20,132 @@
#ifndef HERETIC_P_ACTION_H
#define HERETIC_P_ACTION_H
-void A_FreeTargMobj();
-void A_RestoreSpecialThing1();
-void A_RestoreSpecialThing2();
-void A_HideThing();
-void A_UnHideThing();
-void A_RestoreArtifact();
-void A_Scream();
-void A_Explode();
-void A_PodPain();
-void A_RemovePod();
-void A_MakePod();
-void A_InitKeyGizmo();
-void A_VolcanoSet();
-void A_VolcanoBlast();
-void A_BeastPuff();
-void A_VolcBallImpact();
-void A_SpawnTeleGlitter();
-void A_SpawnTeleGlitter2();
-void A_AccTeleGlitter();
-void A_Light0();
-void A_WeaponReady();
-void A_Lower();
-void A_Raise();
-void A_StaffAttackPL1();
-void A_ReFire();
-void A_StaffAttackPL2();
-void A_BeakReady();
-void A_BeakRaise();
-void A_BeakAttackPL1();
-void A_BeakAttackPL2();
-void A_GauntletAttack();
-void A_FireBlasterPL1();
-void A_FireBlasterPL2();
-void A_SpawnRippers();
-void A_FireMacePL1();
-void A_FireMacePL2();
-void A_MacePL1Check();
-void A_MaceBallImpact();
-void A_MaceBallImpact2();
-void A_DeathBallImpact();
-void A_FireSkullRodPL1();
-void A_FireSkullRodPL2();
-void A_SkullRodPL2Seek();
-void A_AddPlayerRain();
-void A_HideInCeiling();
-void A_SkullRodStorm();
-void A_RainImpact();
-void A_FireGoldWandPL1();
-void A_FireGoldWandPL2();
-void A_FirePhoenixPL1();
-void A_InitPhoenixPL2();
-void A_FirePhoenixPL2();
-void A_ShutdownPhoenixPL2();
-void A_PhoenixPuff();
-void A_RemovedPhoenixFunc();
-void A_FlameEnd();
-void A_FloatPuff();
-void A_FireCrossbowPL1();
-void A_FireCrossbowPL2();
-void A_BoltSpark();
-void A_Pain();
-void A_NoBlocking();
-void A_AddPlayerCorpse();
-void A_SkullPop();
-void A_FlameSnd();
-void A_CheckBurnGone();
-void A_CheckSkullFloor();
-void A_CheckSkullDone();
-void A_Feathers();
-void A_ChicLook();
-void A_ChicChase();
-void A_ChicPain();
-void A_FaceTarget();
-void A_ChicAttack();
-void A_Look();
-void A_Chase();
-void A_MummyAttack();
-void A_MummyAttack2();
-void A_MummySoul();
-void A_ContMobjSound();
-void A_MummyFX1Seek();
-void A_BeastAttack();
-void A_SnakeAttack();
-void A_SnakeAttack2();
-void A_HeadAttack();
-void A_BossDeath();
-void A_HeadIceImpact();
-void A_HeadFireGrow();
-void A_WhirlwindSeek();
-void A_ClinkAttack();
-void A_WizAtk1();
-void A_WizAtk2();
-void A_WizAtk3();
-void A_GhostOff();
-void A_ImpMeAttack();
-void A_ImpMsAttack();
-void A_ImpMsAttack2();
-void A_ImpDeath();
-void A_ImpXDeath1();
-void A_ImpXDeath2();
-void A_ImpExplode();
-void A_KnightAttack();
-void A_DripBlood();
-void A_Sor1Chase();
-void A_Sor1Pain();
-void A_Srcr1Attack();
-void A_SorZap();
-void A_SorcererRise();
-void A_SorRise();
-void A_SorSightSnd();
-void A_Srcr2Decide();
-void A_Srcr2Attack();
-void A_Sor2DthInit();
-void A_SorDSph();
-void A_Sor2DthLoop();
-void A_SorDExp();
-void A_SorDBon();
-void A_BlueSpark();
-void A_GenWizard();
-void A_MinotaurAtk1();
-void A_MinotaurDecide();
-void A_MinotaurAtk2();
-void A_MinotaurAtk3();
-void A_MinotaurCharge();
-void A_MntrFloorFire();
-void A_ESound();
+void A_FreeTargMobj(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RestoreSpecialThing1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RestoreSpecialThing2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_HideThing(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_UnHideThing(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RestoreArtifact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Scream(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Explode(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_PodPain(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RemovePod(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MakePod(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_InitKeyGizmo(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_VolcanoSet(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_VolcanoBlast(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeastPuff(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_VolcBallImpact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SpawnTeleGlitter(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SpawnTeleGlitter2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_AccTeleGlitter(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Light0(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_WeaponReady(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Lower(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Raise(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_StaffAttackPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ReFire(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_StaffAttackPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeakReady(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeakRaise(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeakAttackPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeakAttackPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_GauntletAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireBlasterPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireBlasterPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SpawnRippers(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireMacePL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireMacePL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MacePL1Check(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MaceBallImpact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MaceBallImpact2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_DeathBallImpact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireSkullRodPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireSkullRodPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SkullRodPL2Seek(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_AddPlayerRain(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_HideInCeiling(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SkullRodStorm(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RainImpact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireGoldWandPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireGoldWandPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FirePhoenixPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_InitPhoenixPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FirePhoenixPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ShutdownPhoenixPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_PhoenixPuff(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_RemovedPhoenixFunc(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FlameEnd(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FloatPuff(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireCrossbowPL1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FireCrossbowPL2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BoltSpark(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Pain(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_NoBlocking(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_AddPlayerCorpse(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SkullPop(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FlameSnd(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_CheckBurnGone(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_CheckSkullFloor(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_CheckSkullDone(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Feathers(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ChicLook(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ChicChase(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ChicPain(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_FaceTarget(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ChicAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Look(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Chase(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MummyAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MummyAttack2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MummySoul(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ContMobjSound(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MummyFX1Seek(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BeastAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SnakeAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SnakeAttack2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_HeadAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BossDeath(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_HeadIceImpact(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_HeadFireGrow(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_WhirlwindSeek(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ClinkAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_WizAtk1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_WizAtk2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_WizAtk3(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_GhostOff(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpMeAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpMsAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpMsAttack2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpDeath(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpXDeath1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpXDeath2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ImpExplode(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_KnightAttack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_DripBlood(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Sor1Chase(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Sor1Pain(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Srcr1Attack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorZap(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorcererRise(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorRise(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorSightSnd(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Srcr2Decide(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Srcr2Attack(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Sor2DthInit(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorDSph(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_Sor2DthLoop(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorDExp(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_SorDBon(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_BlueSpark(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_GenWizard(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MinotaurAtk1(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MinotaurDecide(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MinotaurAtk2(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MinotaurAtk3(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MinotaurCharge(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_MntrFloorFire(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
+void A_ESound(struct mobj_s *actor, struct player_s *player, struct pspdef_s *psp);
#endif /* #ifndef HERETIC_P_ACTION_H */
--- a/src/heretic/p_enemy.c
+++ b/src/heretic/p_enemy.c
@@ -602,7 +602,7 @@
==============
*/
-void A_Look(mobj_t * actor)
+void A_Look(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *targ;
@@ -671,7 +671,7 @@
==============
*/
-void A_Chase(mobj_t * actor)
+void A_Chase(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int delta;
@@ -802,7 +802,7 @@
//
//----------------------------------------------------------------------------
-void A_FaceTarget(mobj_t * actor)
+void A_FaceTarget(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -823,7 +823,7 @@
//
//----------------------------------------------------------------------------
-void A_Pain(mobj_t * actor)
+void A_Pain(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->info->painsound)
{
@@ -837,7 +837,7 @@
//
//----------------------------------------------------------------------------
-void A_DripBlood(mobj_t * actor)
+void A_DripBlood(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
int r1,r2;
@@ -859,7 +859,7 @@
//
//----------------------------------------------------------------------------
-void A_KnightAttack(mobj_t * actor)
+void A_KnightAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -888,7 +888,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpExplode(mobj_t * actor)
+void A_ImpExplode(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -912,7 +912,7 @@
//
//----------------------------------------------------------------------------
-void A_BeastPuff(mobj_t * actor)
+void A_BeastPuff(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (P_Random() > 64)
{
@@ -932,7 +932,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpMeAttack(mobj_t * actor)
+void A_ImpMeAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -951,7 +951,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpMsAttack(mobj_t * actor)
+void A_ImpMsAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *dest;
angle_t an;
@@ -965,7 +965,7 @@
dest = actor->target;
actor->flags |= MF_SKULLFLY;
S_StartSound(actor, actor->info->attacksound);
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
an = actor->angle >> ANGLETOFINESHIFT;
actor->momx = FixedMul(12 * FRACUNIT, finecosine[an]);
actor->momy = FixedMul(12 * FRACUNIT, finesine[an]);
@@ -986,7 +986,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpMsAttack2(mobj_t * actor)
+void A_ImpMsAttack2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -1007,7 +1007,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpDeath(mobj_t * actor)
+void A_ImpDeath(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->flags &= ~MF_SOLID;
actor->flags2 |= MF2_FOOTCLIP;
@@ -1023,7 +1023,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpXDeath1(mobj_t * actor)
+void A_ImpXDeath1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->flags &= ~MF_SOLID;
actor->flags |= MF_NOGRAVITY;
@@ -1037,7 +1037,7 @@
//
//----------------------------------------------------------------------------
-void A_ImpXDeath2(mobj_t * actor)
+void A_ImpXDeath2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->flags &= ~MF_NOGRAVITY;
if (actor->z <= actor->floorz)
@@ -1101,7 +1101,7 @@
//
//----------------------------------------------------------------------------
-void A_ChicAttack(mobj_t * actor)
+void A_ChicAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (P_UpdateChicken(actor, 18))
{
@@ -1123,13 +1123,13 @@
//
//----------------------------------------------------------------------------
-void A_ChicLook(mobj_t * actor)
+void A_ChicLook(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (P_UpdateChicken(actor, 10))
{
return;
}
- A_Look(actor);
+ A_Look(actor, player, psp);
}
//----------------------------------------------------------------------------
@@ -1138,13 +1138,13 @@
//
//----------------------------------------------------------------------------
-void A_ChicChase(mobj_t * actor)
+void A_ChicChase(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (P_UpdateChicken(actor, 3))
{
return;
}
- A_Chase(actor);
+ A_Chase(actor, player, psp);
}
//----------------------------------------------------------------------------
@@ -1153,7 +1153,7 @@
//
//----------------------------------------------------------------------------
-void A_ChicPain(mobj_t * actor)
+void A_ChicPain(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (P_UpdateChicken(actor, 10))
{
@@ -1168,7 +1168,7 @@
//
//----------------------------------------------------------------------------
-void A_Feathers(mobj_t * actor)
+void A_Feathers(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int i;
int count;
@@ -1200,7 +1200,7 @@
//
//----------------------------------------------------------------------------
-void A_MummyAttack(mobj_t * actor)
+void A_MummyAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -1224,7 +1224,7 @@
//
//----------------------------------------------------------------------------
-void A_MummyAttack2(mobj_t * actor)
+void A_MummyAttack2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -1252,7 +1252,7 @@
//
//----------------------------------------------------------------------------
-void A_MummyFX1Seek(mobj_t * actor)
+void A_MummyFX1Seek(mobj_t *actor, player_t *player, pspdef_t *psp)
{
P_SeekerMissile(actor, ANG1_X * 10, ANG1_X * 20);
}
@@ -1263,7 +1263,7 @@
//
//----------------------------------------------------------------------------
-void A_MummySoul(mobj_t * mummy)
+void A_MummySoul(mobj_t * mummy, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -1278,10 +1278,10 @@
//
//----------------------------------------------------------------------------
-void A_Sor1Pain(mobj_t * actor)
+void A_Sor1Pain(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->special1.i = 20; // Number of steps to walk fast
- A_Pain(actor);
+ A_Pain(actor, player, psp);
}
//----------------------------------------------------------------------------
@@ -1290,7 +1290,7 @@
//
//----------------------------------------------------------------------------
-void A_Sor1Chase(mobj_t * actor)
+void A_Sor1Chase(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->special1.i)
{
@@ -1297,7 +1297,7 @@
actor->special1.i--;
actor->tics -= 3;
}
- A_Chase(actor);
+ A_Chase(actor, player, psp);
}
//----------------------------------------------------------------------------
@@ -1308,7 +1308,7 @@
//
//----------------------------------------------------------------------------
-void A_Srcr1Attack(mobj_t * actor)
+void A_Srcr1Attack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
fixed_t momz;
@@ -1359,7 +1359,7 @@
//
//----------------------------------------------------------------------------
-void A_SorcererRise(mobj_t * actor)
+void A_SorcererRise(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -1376,7 +1376,7 @@
//
//----------------------------------------------------------------------------
-void P_DSparilTeleport(mobj_t * actor)
+void P_DSparilTeleport(mobj_t *actor)
{
int i;
fixed_t x;
@@ -1419,7 +1419,7 @@
//
//----------------------------------------------------------------------------
-void A_Srcr2Decide(mobj_t * actor)
+void A_Srcr2Decide(mobj_t *actor, player_t *player, pspdef_t *psp)
{
static int chance[] = {
192, 120, 120, 120, 64, 64, 32, 16, 0
@@ -1441,7 +1441,7 @@
//
//----------------------------------------------------------------------------
-void A_Srcr2Attack(mobj_t * actor)
+void A_Srcr2Attack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int chance;
@@ -1475,7 +1475,7 @@
//
//----------------------------------------------------------------------------
-void A_BlueSpark(mobj_t * actor)
+void A_BlueSpark(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int i;
mobj_t *mo;
@@ -1495,7 +1495,7 @@
//
//----------------------------------------------------------------------------
-void A_GenWizard(mobj_t * actor)
+void A_GenWizard(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
mobj_t *fog;
@@ -1520,7 +1520,7 @@
//
//----------------------------------------------------------------------------
-void A_Sor2DthInit(mobj_t * actor)
+void A_Sor2DthInit(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->special1.i = 7; // Animation loop counter
P_Massacre(); // Kill monsters early
@@ -1532,7 +1532,7 @@
//
//----------------------------------------------------------------------------
-void A_Sor2DthLoop(mobj_t * actor)
+void A_Sor2DthLoop(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (--actor->special1.i)
{ // Need to loop
@@ -1546,32 +1546,32 @@
//
//----------------------------------------------------------------------------
-void A_SorZap(mobj_t * actor)
+void A_SorZap(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sorzap);
}
-void A_SorRise(mobj_t * actor)
+void A_SorRise(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sorrise);
}
-void A_SorDSph(mobj_t * actor)
+void A_SorDSph(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sordsph);
}
-void A_SorDExp(mobj_t * actor)
+void A_SorDExp(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sordexp);
}
-void A_SorDBon(mobj_t * actor)
+void A_SorDBon(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sordbon);
}
-void A_SorSightSnd(mobj_t * actor)
+void A_SorSightSnd(mobj_t *actor, player_t *player, pspdef_t *psp)
{
S_StartSound(NULL, sfx_sorsit);
}
@@ -1584,7 +1584,7 @@
//
//----------------------------------------------------------------------------
-void A_MinotaurAtk1(mobj_t * actor)
+void A_MinotaurAtk1(mobj_t *actor, player_t *player_, pspdef_t *psp)
{
player_t *player;
@@ -1613,7 +1613,7 @@
#define MNTR_CHARGE_SPEED (13*FRACUNIT)
-void A_MinotaurDecide(mobj_t * actor)
+void A_MinotaurDecide(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
mobj_t *target;
@@ -1634,7 +1634,7 @@
// Don't call the state function right away
P_SetMobjStateNF(actor, S_MNTR_ATK4_1);
actor->flags |= MF_SKULLFLY;
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
angle = actor->angle >> ANGLETOFINESHIFT;
actor->momx = FixedMul(MNTR_CHARGE_SPEED, finecosine[angle]);
actor->momy = FixedMul(MNTR_CHARGE_SPEED, finesine[angle]);
@@ -1648,7 +1648,7 @@
}
else
{ // Swing attack
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
// Don't need to call P_SetMobjState because the current state
// falls through to the swing attack
}
@@ -1660,7 +1660,7 @@
//
//----------------------------------------------------------------------------
-void A_MinotaurCharge(mobj_t * actor)
+void A_MinotaurCharge(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *puff;
@@ -1685,7 +1685,7 @@
//
//----------------------------------------------------------------------------
-void A_MinotaurAtk2(mobj_t * actor)
+void A_MinotaurAtk2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
angle_t angle;
@@ -1722,7 +1722,7 @@
//
//----------------------------------------------------------------------------
-void A_MinotaurAtk3(mobj_t * actor)
+void A_MinotaurAtk3(mobj_t *actor, player_t *player_, pspdef_t *psp)
{
mobj_t *mo;
player_t *player;
@@ -1760,7 +1760,7 @@
//
//----------------------------------------------------------------------------
-void A_MntrFloorFire(mobj_t * actor)
+void A_MntrFloorFire(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
int r1, r2;
@@ -1783,7 +1783,7 @@
//
//----------------------------------------------------------------------------
-void A_BeastAttack(mobj_t * actor)
+void A_BeastAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -1804,7 +1804,7 @@
//
//----------------------------------------------------------------------------
-void A_HeadAttack(mobj_t * actor)
+void A_HeadAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int i;
mobj_t *fire;
@@ -1826,7 +1826,7 @@
{
return;
}
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
if (P_CheckMeleeRange(actor))
{
P_DamageMobj(target, actor, actor, HITDICE(6));
@@ -1885,7 +1885,7 @@
//
//----------------------------------------------------------------------------
-void A_WhirlwindSeek(mobj_t * actor)
+void A_WhirlwindSeek(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->health -= 3;
if (actor->health < 0)
@@ -1914,7 +1914,7 @@
//
//----------------------------------------------------------------------------
-void A_HeadIceImpact(mobj_t * ice)
+void A_HeadIceImpact(mobj_t * ice, player_t *player, pspdef_t *psp)
{
unsigned int i;
angle_t angle;
@@ -1940,7 +1940,7 @@
//
//----------------------------------------------------------------------------
-void A_HeadFireGrow(mobj_t * fire)
+void A_HeadFireGrow(mobj_t * fire, player_t *player, pspdef_t *psp)
{
fire->health--;
fire->z += 9 * FRACUNIT;
@@ -1957,7 +1957,7 @@
//
//----------------------------------------------------------------------------
-void A_SnakeAttack(mobj_t * actor)
+void A_SnakeAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -1965,7 +1965,7 @@
return;
}
S_StartSound(actor, actor->info->attacksound);
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
P_SpawnMissile(actor, actor->target, MT_SNAKEPRO_A);
}
@@ -1975,7 +1975,7 @@
//
//----------------------------------------------------------------------------
-void A_SnakeAttack2(mobj_t * actor)
+void A_SnakeAttack2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (!actor->target)
{
@@ -1983,7 +1983,7 @@
return;
}
S_StartSound(actor, actor->info->attacksound);
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
P_SpawnMissile(actor, actor->target, MT_SNAKEPRO_B);
}
@@ -1993,7 +1993,7 @@
//
//----------------------------------------------------------------------------
-void A_ClinkAttack(mobj_t * actor)
+void A_ClinkAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int damage;
@@ -2015,7 +2015,7 @@
//
//----------------------------------------------------------------------------
-void A_GhostOff(mobj_t * actor)
+void A_GhostOff(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->flags &= ~MF_SHADOW;
}
@@ -2026,9 +2026,9 @@
//
//----------------------------------------------------------------------------
-void A_WizAtk1(mobj_t * actor)
+void A_WizAtk1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
actor->flags &= ~MF_SHADOW;
}
@@ -2038,9 +2038,9 @@
//
//----------------------------------------------------------------------------
-void A_WizAtk2(mobj_t * actor)
+void A_WizAtk2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
- A_FaceTarget(actor);
+ A_FaceTarget(actor, player, psp);
actor->flags |= MF_SHADOW;
}
@@ -2050,7 +2050,7 @@
//
//----------------------------------------------------------------------------
-void A_WizAtk3(mobj_t * actor)
+void A_WizAtk3(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
angle_t angle;
@@ -2083,7 +2083,7 @@
//
//----------------------------------------------------------------------------
-void A_Scream(mobj_t * actor)
+void A_Scream(mobj_t * actor, player_t *player, pspdef_t *psp)
{
switch (actor->type)
{
@@ -2147,7 +2147,7 @@
//
//----------------------------------------------------------------------------
-void A_NoBlocking(mobj_t * actor)
+void A_NoBlocking(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->flags &= ~MF_SOLID;
// Check for monsters dropping things
@@ -2197,7 +2197,7 @@
//
//----------------------------------------------------------------------------
-void A_Explode(mobj_t * actor)
+void A_Explode(mobj_t * actor, player_t *player, pspdef_t *psp)
{
int damage;
@@ -2227,7 +2227,7 @@
//
//----------------------------------------------------------------------------
-void A_PodPain(mobj_t * actor)
+void A_PodPain(mobj_t * actor, player_t *player, pspdef_t *psp)
{
int i;
int count;
@@ -2257,7 +2257,7 @@
//
//----------------------------------------------------------------------------
-void A_RemovePod(mobj_t * actor)
+void A_RemovePod(mobj_t * actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -2279,7 +2279,7 @@
#define MAX_GEN_PODS 16
-void A_MakePod(mobj_t * actor)
+void A_MakePod(mobj_t * actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
fixed_t x;
@@ -2340,7 +2340,7 @@
//
//----------------------------------------------------------------------------
-void A_BossDeath(mobj_t * actor)
+void A_BossDeath(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
thinker_t *think;
@@ -2389,7 +2389,7 @@
//
//----------------------------------------------------------------------------
-void A_ESound(mobj_t * mo)
+void A_ESound(mobj_t *mo, player_t *player, pspdef_t *psp)
{
int sound = sfx_None;
@@ -2413,7 +2413,7 @@
//
//----------------------------------------------------------------------------
-void A_SpawnTeleGlitter(mobj_t * actor)
+void A_SpawnTeleGlitter(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
int r1, r2;
@@ -2432,7 +2432,7 @@
//
//----------------------------------------------------------------------------
-void A_SpawnTeleGlitter2(mobj_t * actor)
+void A_SpawnTeleGlitter2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
int r1, r2;
@@ -2451,7 +2451,7 @@
//
//----------------------------------------------------------------------------
-void A_AccTeleGlitter(mobj_t * actor)
+void A_AccTeleGlitter(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (++actor->health > 35)
{
@@ -2465,7 +2465,7 @@
//
//----------------------------------------------------------------------------
-void A_InitKeyGizmo(mobj_t * gizmo)
+void A_InitKeyGizmo(mobj_t * gizmo, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
statenum_t state = S_NULL;
@@ -2495,7 +2495,7 @@
//
//----------------------------------------------------------------------------
-void A_VolcanoSet(mobj_t * volcano)
+void A_VolcanoSet(mobj_t * volcano, player_t *player, pspdef_t *psp)
{
volcano->tics = 105 + (P_Random() & 127);
}
@@ -2506,7 +2506,7 @@
//
//----------------------------------------------------------------------------
-void A_VolcanoBlast(mobj_t * volcano)
+void A_VolcanoBlast(mobj_t * volcano, player_t *player, pspdef_t *psp)
{
int i;
int count;
@@ -2535,7 +2535,7 @@
//
//----------------------------------------------------------------------------
-void A_VolcBallImpact(mobj_t * ball)
+void A_VolcBallImpact(mobj_t * ball, player_t *player, pspdef_t *psp)
{
unsigned int i;
mobj_t *tiny;
@@ -2569,7 +2569,7 @@
//
//----------------------------------------------------------------------------
-void A_SkullPop(mobj_t * actor)
+void A_SkullPop(mobj_t *actor, player_t *player_, pspdef_t *psp)
{
mobj_t *mo;
player_t *player;
@@ -2606,7 +2606,7 @@
//
//----------------------------------------------------------------------------
-void A_CheckSkullFloor(mobj_t * actor)
+void A_CheckSkullFloor(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->z <= actor->floorz)
{
@@ -2620,7 +2620,7 @@
//
//----------------------------------------------------------------------------
-void A_CheckSkullDone(mobj_t * actor)
+void A_CheckSkullDone(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->special2.i == 666)
{
@@ -2634,7 +2634,7 @@
//
//----------------------------------------------------------------------------
-void A_CheckBurnGone(mobj_t * actor)
+void A_CheckBurnGone(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->special2.i == 666)
{
@@ -2648,7 +2648,7 @@
//
//----------------------------------------------------------------------------
-void A_FreeTargMobj(mobj_t * mo)
+void A_FreeTargMobj(mobj_t * mo, player_t *player, pspdef_t *psp)
{
mo->momx = mo->momy = mo->momz = 0;
mo->z = mo->ceilingz + 4 * FRACUNIT;
@@ -2668,7 +2668,7 @@
mobj_t *bodyque[BODYQUESIZE];
int bodyqueslot;
-void A_AddPlayerCorpse(mobj_t * actor)
+void A_AddPlayerCorpse(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (bodyqueslot >= BODYQUESIZE)
{ // Too many player corpses - remove an old one
@@ -2684,7 +2684,7 @@
//
//----------------------------------------------------------------------------
-void A_FlameSnd(mobj_t * actor)
+void A_FlameSnd(mobj_t * actor, player_t *player, pspdef_t *psp)
{
S_StartSound(actor, sfx_hedat1); // Burn sound
}
@@ -2695,7 +2695,7 @@
//
//----------------------------------------------------------------------------
-void A_HideThing(mobj_t * actor)
+void A_HideThing(mobj_t * actor, player_t *player, pspdef_t *psp)
{
//P_UnsetThingPosition(actor);
actor->flags2 |= MF2_DONTDRAW;
@@ -2707,7 +2707,7 @@
//
//----------------------------------------------------------------------------
-void A_UnHideThing(mobj_t * actor)
+void A_UnHideThing(mobj_t * actor, player_t *player, pspdef_t *psp)
{
//P_SetThingPosition(actor);
actor->flags2 &= ~MF2_DONTDRAW;
--- a/src/heretic/p_inter.c
+++ b/src/heretic/p_inter.c
@@ -489,7 +489,7 @@
//
//---------------------------------------------------------------------------
-void A_RestoreArtifact(mobj_t * arti)
+void A_RestoreArtifact(mobj_t * arti, player_t *player, pspdef_t *psp)
{
arti->flags |= MF_SPECIAL;
P_SetMobjState(arti, arti->info->spawnstate);
@@ -517,7 +517,7 @@
//
//---------------------------------------------------------------------------
-void A_RestoreSpecialThing1(mobj_t * thing)
+void A_RestoreSpecialThing1(mobj_t * thing, player_t *player, pspdef_t *psp)
{
if (thing->type == MT_WMACE)
{ // Do random mace placement
@@ -533,7 +533,7 @@
//
//---------------------------------------------------------------------------
-void A_RestoreSpecialThing2(mobj_t * thing)
+void A_RestoreSpecialThing2(mobj_t * thing, player_t *player, pspdef_t *psp)
{
thing->flags |= MF_SPECIAL;
P_SetMobjState(thing, thing->info->spawnstate);
--- a/src/heretic/p_mobj.c
+++ b/src/heretic/p_mobj.c
@@ -73,7 +73,7 @@
mobj->frame = st->frame;
if (st->action)
{ // Call action function
- st->action(mobj);
+ st->action(mobj, NULL, NULL);
}
return (true);
}
@@ -1610,7 +1610,7 @@
//
//---------------------------------------------------------------------------
-void A_ContMobjSound(mobj_t * actor)
+void A_ContMobjSound(mobj_t * actor, player_t *player, pspdef_t *psp)
{
switch (actor->type)
{
--- a/src/heretic/p_pspr.c
+++ b/src/heretic/p_pspr.c
@@ -339,7 +339,7 @@
}
if (state->action)
{ // Call action routine.
- state->action(player, psp);
+ state->action(NULL, player, psp);
if (!psp->state)
{
break;
@@ -584,7 +584,7 @@
//
//---------------------------------------------------------------------------
-void A_WeaponReady(player_t * player, pspdef_t * psp)
+void A_WeaponReady(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int angle;
@@ -661,7 +661,7 @@
//
//---------------------------------------------------------------------------
-void A_BeakReady(player_t * player, pspdef_t * psp)
+void A_BeakReady(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (player->cmd.buttons & BT_ATTACK)
{ // Chicken beak attack
@@ -695,7 +695,7 @@
//
//---------------------------------------------------------------------------
-void A_ReFire(player_t * player, pspdef_t * psp)
+void A_ReFire(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if ((player->cmd.buttons & BT_ATTACK)
&& player->pendingweapon == wp_nochange && player->health)
@@ -716,7 +716,7 @@
//
//---------------------------------------------------------------------------
-void A_Lower(player_t * player, pspdef_t * psp)
+void A_Lower(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (player->chickenTics)
{
@@ -750,7 +750,7 @@
//
//---------------------------------------------------------------------------
-void A_BeakRaise(player_t * player, pspdef_t * psp)
+void A_BeakRaise(mobj_t *actor, player_t *player, pspdef_t *psp)
{
psp->sy = WEAPONTOP;
P_SetPsprite(player, ps_weapon,
@@ -763,7 +763,7 @@
//
//---------------------------------------------------------------------------
-void A_Raise(player_t * player, pspdef_t * psp)
+void A_Raise(mobj_t *actor, player_t *player, pspdef_t *psp)
{
psp->sy -= RAISESPEED;
if (psp->sy > WEAPONTOP)
@@ -832,7 +832,7 @@
//
//----------------------------------------------------------------------------
-void A_BeakAttackPL1(player_t * player, pspdef_t * psp)
+void A_BeakAttackPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
int damage;
@@ -860,7 +860,7 @@
//
//----------------------------------------------------------------------------
-void A_BeakAttackPL2(player_t * player, pspdef_t * psp)
+void A_BeakAttackPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
int damage;
@@ -888,7 +888,7 @@
//
//----------------------------------------------------------------------------
-void A_StaffAttackPL1(player_t * player, pspdef_t * psp)
+void A_StaffAttackPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
int damage;
@@ -916,7 +916,7 @@
//
//----------------------------------------------------------------------------
-void A_StaffAttackPL2(player_t * player, pspdef_t * psp)
+void A_StaffAttackPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
int damage;
@@ -945,7 +945,7 @@
//
//----------------------------------------------------------------------------
-void A_FireBlasterPL1(player_t * player, pspdef_t * psp)
+void A_FireBlasterPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
angle_t angle;
@@ -972,7 +972,7 @@
//
//----------------------------------------------------------------------------
-void A_FireBlasterPL2(player_t * player, pspdef_t * psp)
+void A_FireBlasterPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -992,7 +992,7 @@
//
//----------------------------------------------------------------------------
-void A_FireGoldWandPL1(player_t * player, pspdef_t * psp)
+void A_FireGoldWandPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
angle_t angle;
@@ -1018,7 +1018,7 @@
//
//----------------------------------------------------------------------------
-void A_FireGoldWandPL2(player_t * player, pspdef_t * psp)
+void A_FireGoldWandPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
int i;
mobj_t *mo;
@@ -1050,7 +1050,7 @@
//
//----------------------------------------------------------------------------
-void A_FireMacePL1B(player_t * player, pspdef_t * psp)
+void A_FireMacePL1B(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *pmo;
mobj_t *ball;
@@ -1093,13 +1093,13 @@
//
//----------------------------------------------------------------------------
-void A_FireMacePL1(player_t * player, pspdef_t * psp)
+void A_FireMacePL1(mobj_t *mobj, player_t * player, pspdef_t * psp)
{
mobj_t *ball;
if (P_Random() < 28)
{
- A_FireMacePL1B(player, psp);
+ A_FireMacePL1B(mobj, player, psp);
return;
}
if (player->ammo[am_mace] < USE_MACE_AMMO_1)
@@ -1123,7 +1123,7 @@
//
//----------------------------------------------------------------------------
-void A_MacePL1Check(mobj_t * ball)
+void A_MacePL1Check(mobj_t * ball, player_t *player, pspdef_t *psp)
{
angle_t angle;
@@ -1150,7 +1150,7 @@
//
//----------------------------------------------------------------------------
-void A_MaceBallImpact(mobj_t * ball)
+void A_MaceBallImpact(mobj_t * ball, player_t *player, pspdef_t *psp)
{
if ((ball->z <= ball->floorz) && (P_HitFloor(ball) != FLOOR_SOLID))
{ // Landed in some sort of liquid
@@ -1180,7 +1180,7 @@
//
//----------------------------------------------------------------------------
-void A_MaceBallImpact2(mobj_t * ball)
+void A_MaceBallImpact2(mobj_t * ball, player_t *player, pspdef_t *psp)
{
mobj_t *tiny;
angle_t angle;
@@ -1233,7 +1233,7 @@
//
//----------------------------------------------------------------------------
-void A_FireMacePL2(player_t * player, pspdef_t * psp)
+void A_FireMacePL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -1258,7 +1258,7 @@
//
//----------------------------------------------------------------------------
-void A_DeathBallImpact(mobj_t * ball)
+void A_DeathBallImpact(mobj_t * ball, player_t *player, pspdef_t *psp)
{
int i;
mobj_t *target;
@@ -1328,7 +1328,7 @@
//
//----------------------------------------------------------------------------
-void A_SpawnRippers(mobj_t * actor)
+void A_SpawnRippers(mobj_t *actor, player_t *player, pspdef_t *psp)
{
unsigned int i;
angle_t angle;
@@ -1353,7 +1353,7 @@
//
//----------------------------------------------------------------------------
-void A_FireCrossbowPL1(player_t * player, pspdef_t * psp)
+void A_FireCrossbowPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *pmo;
@@ -1370,7 +1370,7 @@
//
//----------------------------------------------------------------------------
-void A_FireCrossbowPL2(player_t * player, pspdef_t * psp)
+void A_FireCrossbowPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *pmo;
@@ -1390,7 +1390,7 @@
//
//----------------------------------------------------------------------------
-void A_BoltSpark(mobj_t * bolt)
+void A_BoltSpark(mobj_t * bolt, player_t *player, pspdef_t *psp)
{
mobj_t *spark;
@@ -1408,7 +1408,7 @@
//
//----------------------------------------------------------------------------
-void A_FireSkullRodPL1(player_t * player, pspdef_t * psp)
+void A_FireSkullRodPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
@@ -1435,7 +1435,7 @@
//
//----------------------------------------------------------------------------
-void A_FireSkullRodPL2(player_t * player, pspdef_t * psp)
+void A_FireSkullRodPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->ammo[am_skullrod] -=
deathmatch ? USE_SKRD_AMMO_1 : USE_SKRD_AMMO_2;
@@ -1464,7 +1464,7 @@
//
//----------------------------------------------------------------------------
-void A_SkullRodPL2Seek(mobj_t * actor)
+void A_SkullRodPL2Seek(mobj_t *actor, player_t *player, pspdef_t *psp)
{
P_SeekerMissile(actor, ANG1_X * 10, ANG1_X * 30);
}
@@ -1475,7 +1475,7 @@
//
//----------------------------------------------------------------------------
-void A_AddPlayerRain(mobj_t * actor)
+void A_AddPlayerRain(mobj_t *actor, player_t *player_, pspdef_t *psp)
{
int playerNum;
player_t *player;
@@ -1526,7 +1526,7 @@
//
//----------------------------------------------------------------------------
-void A_SkullRodStorm(mobj_t * actor)
+void A_SkullRodStorm(mobj_t *actor, player_t *player_, pspdef_t *psp)
{
fixed_t x;
fixed_t y;
@@ -1582,7 +1582,7 @@
//
//----------------------------------------------------------------------------
-void A_RainImpact(mobj_t * actor)
+void A_RainImpact(mobj_t *actor, player_t *player, pspdef_t *psp)
{
if (actor->z > actor->floorz)
{
@@ -1600,7 +1600,7 @@
//
//----------------------------------------------------------------------------
-void A_HideInCeiling(mobj_t * actor)
+void A_HideInCeiling(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->z = actor->ceilingz + 4 * FRACUNIT;
}
@@ -1611,7 +1611,7 @@
//
//----------------------------------------------------------------------------
-void A_FirePhoenixPL1(player_t * player, pspdef_t * psp)
+void A_FirePhoenixPL1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
@@ -1630,7 +1630,7 @@
//
//----------------------------------------------------------------------------
-void A_PhoenixPuff(mobj_t * actor)
+void A_PhoenixPuff(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *puff;
angle_t angle;
@@ -1656,7 +1656,7 @@
// The purpose of this object is unknown, as is this function.
//
-void A_RemovedPhoenixFunc(mobj_t *actor)
+void A_RemovedPhoenixFunc(mobj_t *actor, player_t * player, pspdef_t * psp)
{
I_Error("Action function invoked for removed Phoenix action!");
}
@@ -1667,7 +1667,7 @@
//
//----------------------------------------------------------------------------
-void A_InitPhoenixPL2(player_t * player, pspdef_t * psp)
+void A_InitPhoenixPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->flamecount = FLAME_THROWER_TICS;
}
@@ -1680,7 +1680,7 @@
//
//----------------------------------------------------------------------------
-void A_FirePhoenixPL2(player_t * player, pspdef_t * psp)
+void A_FirePhoenixPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
mobj_t *mo;
mobj_t *pmo;
@@ -1725,7 +1725,7 @@
//
//----------------------------------------------------------------------------
-void A_ShutdownPhoenixPL2(player_t * player, pspdef_t * psp)
+void A_ShutdownPhoenixPL2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->ammo[am_phoenixrod] -= USE_PHRD_AMMO_2;
}
@@ -1736,7 +1736,7 @@
//
//----------------------------------------------------------------------------
-void A_FlameEnd(mobj_t * actor)
+void A_FlameEnd(mobj_t *actor, player_t *player, pspdef_t *psp)
{
actor->momz += (fixed_t)(1.5 * FRACUNIT);
}
@@ -1747,7 +1747,7 @@
//
//----------------------------------------------------------------------------
-void A_FloatPuff(mobj_t * puff)
+void A_FloatPuff(mobj_t * puff, player_t *player, pspdef_t *psp)
{
puff->momz += (fixed_t)(1.8 * FRACUNIT);
}
@@ -1758,7 +1758,7 @@
//
//---------------------------------------------------------------------------
-void A_GauntletAttack(player_t * player, pspdef_t * psp)
+void A_GauntletAttack(mobj_t *actor, player_t *player, pspdef_t *psp)
{
angle_t angle;
int damage;
@@ -1836,17 +1836,17 @@
player->mo->flags |= MF_JUSTATTACKED;
}
-void A_Light0(player_t * player, pspdef_t * psp)
+void A_Light0(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->extralight = 0;
}
-void A_Light1(player_t * player, pspdef_t * psp)
+void A_Light1(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->extralight = 1;
}
-void A_Light2(player_t * player, pspdef_t * psp)
+void A_Light2(mobj_t *actor, player_t *player, pspdef_t *psp)
{
player->extralight = 2;
}