From 64c83d166e47333c533b6f2722202295e5baca6e Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Mon, 2 Nov 2020 19:53:04 +0100 Subject: [PATCH] - fixed a few parameters --- source/games/duke/src/sectors_d.cpp | 8 ++++---- source/games/duke/src/sectors_r.cpp | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/source/games/duke/src/sectors_d.cpp b/source/games/duke/src/sectors_d.cpp index a2256d407..d5ab4766b 100644 --- a/source/games/duke/src/sectors_d.cpp +++ b/source/games/duke/src/sectors_d.cpp @@ -212,9 +212,9 @@ void operaterespawns_d(int low) // //--------------------------------------------------------------------------- -void operateforcefields_d(int s, int low) +void operateforcefields_d(DDukeActor* act, int low) { - operateforcefields_common(&hittype[s], low, { W_FORCEFIELD, W_FORCEFIELD + 1, W_FORCEFIELD + 2, BIGFORCE }); + operateforcefields_common(act, low, { W_FORCEFIELD, W_FORCEFIELD + 1, W_FORCEFIELD + 2, BIGFORCE }); } //--------------------------------------------------------------------------- @@ -579,7 +579,7 @@ bool checkhitswitch_d(int snum, int ww, DDukeActor *act) } operateactivators(lotag, snum); - fi.operateforcefields(ps[snum].i, lotag); + fi.operateforcefields(ps[snum].GetActor(), lotag); operatemasterswitches(lotag); if (picnum == DIPSWITCH || picnum == DIPSWITCH + 1 || @@ -1533,7 +1533,7 @@ void checksectors_d(int snum) if (chatmodeon || p->GetActor()->s.extra <= 0) return; if (ud.cashman && PlayerInput(snum, SB_OPEN)) - fi.lotsofmoney(&hittype[p->i], 2); + fi.lotsofmoney(p->GetActor(), 2); if (p->newowner >= 0) { diff --git a/source/games/duke/src/sectors_r.cpp b/source/games/duke/src/sectors_r.cpp index 82a8e5603..a772aa962 100644 --- a/source/games/duke/src/sectors_r.cpp +++ b/source/games/duke/src/sectors_r.cpp @@ -332,9 +332,9 @@ void operaterespawns_r(int low) // //--------------------------------------------------------------------------- -void operateforcefields_r(int s, int low) +void operateforcefields_r(DDukeActor* act, int low) { - operateforcefields_common(&hittype[s], low, { BIGFORCE }); + operateforcefields_common(act, low, { BIGFORCE }); } //--------------------------------------------------------------------------- @@ -861,7 +861,7 @@ bool checkhitswitch_r(int snum, int ww, DDukeActor* act) } operateactivators(lotag, snum); - fi.operateforcefields(ps[snum].i, lotag); + fi.operateforcefields(ps[snum].GetActor(), lotag); operatemasterswitches(lotag); if (picnum == DIPSWITCH || picnum == DIPSWITCH + 1 || @@ -2477,7 +2477,7 @@ void checksectors_r(int snum) if (chatmodeon || p->GetActor()->s.extra <= 0) return; if (ud.cashman && PlayerInput(snum, SB_OPEN)) - fi.lotsofmoney(&hittype[p->i], 2); + fi.lotsofmoney(p->GetActor(), 2); if (!(PlayerInput(snum, SB_OPEN)))