accuracy_resend(this);
- this.spectatortime = time;
+ CS(this).spectatortime = time;
if(this.bot_attack)
IL_REMOVE(g_bot_targets, this);
this.bot_attack = false;
bot_relinkplayerlist();
- this.spectatortime = time;
+ CS(this).spectatortime = time;
if (blockSpectators)
{
Send_Notification(NOTIF_ONE_ONLY, this, MSG_INFO, INFO_SPECTATE_WARNING, autocvar_g_maxplayers_spectator_blocktime);
if(!this.caplayer)
if(IS_REAL_CLIENT(this))
{
- if( time > (this.spectatortime + autocvar_g_maxplayers_spectator_blocktime) ) {
+ if( time > (CS(this).spectatortime + autocvar_g_maxplayers_spectator_blocktime) ) {
Send_Notification(NOTIF_ONE_ONLY, this, MSG_INFO, INFO_QUIT_KICK_SPECTATING);
dropclient(this);
}
ATTRIB(Client, usekeypressed, bool, this.usekeypressed);
ATTRIB(Client, motd_actived_time, float, this.motd_actived_time);
ATTRIB(Client, jointime, float, this.jointime);
+ ATTRIB(Client, spectatortime, float, this.spectatortime);
METHOD(Client, m_unwind, bool(Client this));
FOREACH_CLIENT(IS_REAL_CLIENT(it) && (IS_SPEC(it) || IS_OBSERVER(it)) && !it.caplayer, LAMBDA(
if(!it.caplayer)
{
- it.spectatortime = time;
+ CS(it).spectatortime = time;
Send_Notification(NOTIF_ONE_ONLY, it, MSG_INFO, INFO_SPECTATE_WARNING, autocvar_g_maxplayers_spectator_blocktime);
}
));