void Cmd_Chasecam_Toggle (edict_t *ent) { // Lazarus: Don't allow thirdperson when using spycam if (!ent->deadflag && !ent->client->spycam) { if (ent->client->chasetoggle) ChasecamRemove (ent, OPTION_OFF); // Knightmare- don't use server chasecam if client chasecam is on else if (!cl_3dcam->value || deathmatch->value || coop->value) ChasecamStart (ent); } }
void Cmd_Chasecam_Toggle (edict_t *ent) { int i; edict_t *e; //////////////////////////////////// // ADDED if(ent->client->resp.spectator == true)// || //(ent->client->resp.team == CTF_NOTEAM && ent->client->resp.player_class == NO_CLASS)) { if (ent->client->chase_target) { //ent->svflags &= ~SVF_NOCLIENT; //added ent->client->chase_target = NULL; } else { for (i = 1; i <= maxclients->value; i++) { e = g_edicts + i; if (e->inuse && e->solid != SOLID_NOT) { ent->client->chase_target = e; ent->client->update_chase = true; ent->svflags |= SVF_NOCLIENT; //added break; } } } } // Lazarus: Don't allow thirdperson when using spycam else if (!ent->deadflag && !ent->client->spycam /*&& ent->client->resp.player_class*/) { // if (ent->client->chasetoggle) if (ent->client->chaseactive) { // gi.cprintf (ent, PRINT_HIGH, "Leaving Third Person mode.\n"); ChasecamRemove (ent); } // Knightmare- don't use server chasecam if client chasecam is on else if (!cl_thirdperson->value || deathmatch->value || coop->value) { // gi.cprintf (ent, PRINT_HIGH, "Starting Third Person mode.\n"); ChasecamStart (ent); } } }