Skip to content

Commit

Permalink
Update user friction on start and tp
Browse files Browse the repository at this point in the history
  • Loading branch information
Theggv committed Dec 31, 2023
1 parent 121c188 commit adef651
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/scripts/kreedz/kz_core.sma
Original file line number Diff line number Diff line change
Expand Up @@ -440,6 +440,7 @@ public native_tp_last_pos() {
set_entvar(id, var_view_ofs, Float:{0.0, 0.0, 12.0});
set_entvar(id, var_flags, get_entvar(id, var_flags) | FL_DUCKING);
set_entvar(id, var_fuser2, 0.0);
set_entvar(id, var_friction, 1.0);

if (g_UserData[id][ud_TimerState] == TIMER_PAUSED)
cmd_Fade(id);
Expand Down Expand Up @@ -569,6 +570,7 @@ public cmd_Gocheck(id) {
set_entvar(id, var_view_ofs, Float:{0.0, 0.0, 12.0});
set_entvar(id, var_flags, get_entvar(id, var_flags) | FL_DUCKING);
set_entvar(id, var_fuser2, 0.0);
set_entvar(id, var_friction, 1.0);

ExecuteForward(g_Forwards[fwd_TeleportPost], _, id);

Expand Down Expand Up @@ -630,6 +632,7 @@ public cmd_Start(id) {
set_entvar(id, var_view_ofs, Float:{0.0, 0.0, 12.0});
set_entvar(id, var_flags, get_entvar(id, var_flags) | FL_DUCKING);
set_entvar(id, var_fuser2, 0.0);
set_entvar(id, var_friction, 1.0);
} else {
ExecuteHamB(Ham_CS_RoundRespawn, id);
}
Expand Down
1 change: 1 addition & 0 deletions src/scripts/utility/kz_cups.sma
Original file line number Diff line number Diff line change
Expand Up @@ -1183,6 +1183,7 @@ public RemoveEffects(id)
set_entvar(id, var_flags, get_entvar(id, var_flags) | FL_DUCKING);
set_entvar(id, var_fuser2, 0.0);
set_entvar(id, var_flags, get_entvar(id, var_flags) & ~FL_FROZEN);
set_entvar(id, var_friction, 1.0);
}
}

Expand Down

0 comments on commit adef651

Please sign in to comment.