♻️Use Point for positions in msg.cpp functions

This commit is contained in:
Anders Jenbo 2021-04-29 16:02:11 +02:00
commit 5745f099ba
12 changed files with 66 additions and 69 deletions

View file

@ -34,7 +34,7 @@ void track_process()
Uint32 tick = SDL_GetTicks();
if ((int)(tick - sgdwLastWalk) >= gnTickDelay * 6) {
sgdwLastWalk = tick;
NetSendCmdLoc(myplr, true, CMD_WALKXY, cursmx, cursmy);
NetSendCmdLoc(myplr, true, CMD_WALKXY, { cursmx, cursmy });
if (!sgbIsScrolling)
sgbIsScrolling = true;
}
@ -50,7 +50,7 @@ void track_repeat_walk(bool rep)
if (rep) {
sgbIsScrolling = false;
sgdwLastWalk = SDL_GetTicks() - gnTickDelay;
NetSendCmdLoc(myplr, true, CMD_WALKXY, cursmx, cursmy);
NetSendCmdLoc(myplr, true, CMD_WALKXY, { cursmx, cursmy });
} else if (sgbIsScrolling) {
sgbIsScrolling = false;
}