localcmd("\nsv_hook_firstjoin\n");
}
}
+
+.string shootfromfixedorigin;
+.entity chatbubbleentity;
+void player_powerups_remove_all(entity this);
+
/*
=============
ClientDisconnect
Called when a client disconnects from the server
=============
*/
-.entity chatbubbleentity;
-void player_powerups_remove_all(entity this);
-
void ClientDisconnect(entity this)
{
assert(IS_CLIENT(this), return);
RemoveGrapplingHooks(this);
+ strfree(this.shootfromfixedorigin);
+
// Here, everything has been done that requires this player to be a client.
this.flags &= ~FL_CLIENT;
this.wp_aimed = ent;
}
-.string shootfromfixedorigin;
.bool dualwielding_prev;
bool PlayerThink(entity this)
{
FixPlayermodel(this);
if (this.shootfromfixedorigin != autocvar_g_shootfromfixedorigin) {
- this.shootfromfixedorigin = autocvar_g_shootfromfixedorigin;
+ strcpy(this.shootfromfixedorigin, autocvar_g_shootfromfixedorigin);
stuffcmd(this, sprintf("\ncl_shootfromfixedorigin \"%s\"\n", autocvar_g_shootfromfixedorigin));
}