Skip to content
Snippets Groups Projects
Commit 84e73586 authored by Yukita Mayako's avatar Yukita Mayako
Browse files

70 FPS player ticks.

parent fe4c4dd4
No related branches found
No related tags found
No related merge requests found
...@@ -303,6 +303,19 @@ static inline void P_RunThinkers(void) ...@@ -303,6 +303,19 @@ static inline void P_RunThinkers(void)
} }
} }
static inline void P_RunPlayerThinkers(void)
{
for (currentthinker = thinkercap.next; currentthinker != &thinkercap; currentthinker = currentthinker->next)
{
if (currentthinker->function.acp1 == (actionf_p1)P_MobjThinker)
{
mobj_t *mobj = (mobj_t *)currentthinker;
if (mobj->type == MT_PLAYER)
currentthinker->function.acp1(currentthinker);
}
}
}
// //
// P_DoAutobalanceTeams() // P_DoAutobalanceTeams()
// //
...@@ -592,8 +605,6 @@ void P_Ticker(boolean run) ...@@ -592,8 +605,6 @@ void P_Ticker(boolean run)
P_MapStart(); P_MapStart();
if (run)
{
postimgtype = postimgtype2 = postimg_none; postimgtype = postimgtype2 = postimg_none;
if (demorecording) if (demorecording)
...@@ -604,7 +615,6 @@ void P_Ticker(boolean run) ...@@ -604,7 +615,6 @@ void P_Ticker(boolean run)
for (i = 0; i < MAXPLAYERS; i++) for (i = 0; i < MAXPLAYERS; i++)
if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo)) if (playeringame[i] && players[i].mo && !P_MobjWasRemoved(players[i].mo))
P_PlayerThink(&players[i]); P_PlayerThink(&players[i]);
}
// Keep track of how long they've been playing! // Keep track of how long they've been playing!
totalplaytime++; totalplaytime++;
...@@ -616,8 +626,9 @@ void P_Ticker(boolean run) ...@@ -616,8 +626,9 @@ void P_Ticker(boolean run)
P_EmeraldManager(); // Power stone mode P_EmeraldManager(); // Power stone mode
if (run) if (run)
{
P_RunThinkers(); P_RunThinkers();
else
P_RunPlayerThinkers();
// Run any "after all the other thinkers" stuff // Run any "after all the other thinkers" stuff
for (i = 0; i < MAXPLAYERS; i++) for (i = 0; i < MAXPLAYERS; i++)
...@@ -627,7 +638,6 @@ void P_Ticker(boolean run) ...@@ -627,7 +638,6 @@ void P_Ticker(boolean run)
#ifdef HAVE_BLUA #ifdef HAVE_BLUA
LUAh_ThinkFrame(); LUAh_ThinkFrame();
#endif #endif
}
// Run shield positioning // Run shield positioning
P_RunShields(); P_RunShields();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment