- Duke: Call movetransports() before processing any player movement.

* This simply works much better. In addition to being able to revert commits like `- Duke: Maintain x/y/z velocity when falling through a portal, such as E1L1's air duct.`, transitioning from above water to underwater and vice-versa is interpolated, smooth and seamless, something that I was unable to hack in without this change.
This commit is contained in:
Mitchell Richters 2022-10-11 12:16:59 +11:00 committed by Christoph Oelckers
parent 641b22addf
commit 098542de69
5 changed files with 6 additions and 2 deletions

View file

@ -3274,7 +3274,6 @@ void think_d(void)
movefta(); //ST 2
moveweapons_d(); //ST 4
movetransports_d(); //ST 9
moveplayers(); //ST 10
movefallers_d(); //ST 12
moveexplosions_d(); //ST 5

View file

@ -3741,7 +3741,6 @@ void think_r(void)
movefta(); //ST 2
moveweapons_r(); //ST 4
movetransports_r(); //ST 9
moveplayers(); //ST 10
movefallers_r(); //ST 12
moveexplosions_r(); //ST 5

View file

@ -98,6 +98,8 @@ void displaymasks_d(int snum, int p, double interpfrac);
void displaymasks_r(int snum, int p, double interpfrac);
void think_d();
void think_r();
void movetransports_d();
void movetransports_r();
void animatesprites_d(tspriteArray& tsprites, const DVector2& viewVec, DAngle viewang, double interpfrac);
void animatesprites_r(tspriteArray& tsprites, const DVector2& viewVec, DAngle viewang, double interpfrac);
@ -109,6 +111,7 @@ void SetDispatcher()
{
fi = {
think_d,
movetransports_d,
initactorflags_d,
isadoorwall_d,
animatewalls_d,
@ -151,6 +154,7 @@ void SetDispatcher()
{
fi = {
think_r,
movetransports_r,
initactorflags_r,
isadoorwall_r,
animatewalls_r,

View file

@ -70,6 +70,7 @@ struct Dispatcher
{
// sectors_?.cpp
void (*think)();
void (*movetransports)();
void (*initactorflags)();
bool (*isadoorwall)(int dapic);
void (*animatewalls)();

View file

@ -70,6 +70,7 @@ void GameInterface::Ticker()
everyothertime++;
global_random = krand();
fi.movetransports();//ST 9
movedummyplayers();//ST 13
for (int i = connecthead; i >= 0; i = connectpoint2[i])