forked from Ports/perfect_dark
port: net: carry some of the client inputs over to server-sent moves
This commit is contained in:
1 parent
f6ee8bbf71
commit
96e1c57f61
1 file changed
+6
@@ -193,8 +193,14 @@ static inline void netClientRecordMove(struct netclient *cl, const struct player
|
||||
move->pos = (pl->prop) ? pl->prop->pos : pl->cam_pos;
|
||||
move->crosspos[0] = pl->crosspos[0];
|
||||
move->crosspos[1] = pl->crosspos[1];
|
||||
|
||||
move->ucmd = pl->ucmd;
|
||||
|
||||
if (g_NetMode == NETMODE_SERVER && pl->isremote && cl->inmove[0].tick) {
|
||||
// carry some of the client inputs over to the outmove
|
||||
move->ucmd |= (cl->inmove[0].ucmd & (UCMD_FIRE | UCMD_RELOAD | UCMD_AIMMODE | UCMD_EYESSHUT | UCMD_SELECT | UCMD_SELECT_DUAL));
|
||||
}
|
||||
|
||||
if (pl->crouchpos == CROUCHPOS_DUCK) {
|
||||
move->ucmd |= UCMD_DUCK;
|
||||
} else if (pl->crouchpos == CROUCHPOS_SQUAT) {
|
||||
|
||||
Reference in new issue
Block a user