From ce00395ab73bb763d5c2b19c2fcae46e9b8bfb8e Mon Sep 17 00:00:00 2001 From: Tim Angus Date: Fri, 22 Jul 2005 01:32:50 +0000 Subject: * Added a report of which stages each team had reached to the intermission scoreboard * Advanced construction kit is now free * Fixed the bug where the armoury and repeater would still work via command when not powered * Fixed bug where the granger could evolve whilst waiting for its build timer * Increased the jump height of the base granger slightly --- src/game/bg_misc.c | 2 +- src/game/g_buildable.c | 8 ++++- src/game/g_cmds.c | 95 ++++++++++++++++++++++++++++---------------------- src/game/g_main.c | 22 ++++++------ src/game/tremulous.h | 2 +- 5 files changed, 74 insertions(+), 55 deletions(-) (limited to 'src/game') diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c index bd3db376..9922bf13 100644 --- a/src/game/bg_misc.c +++ b/src/game/bg_misc.c @@ -1518,7 +1518,7 @@ classAttributes_t bg_classList[ ] = 1.0f, //float airAcceleration; 6.0f, //float friction; 100.0f, //float stopSpeed; - 130.0f, //float jumpMagnitude; + 195.0f, //float jumpMagnitude; 1.0f, //float knockbackScale; { PCL_ALIEN_BUILDER0_UPG, PCL_ALIEN_LEVEL0, PCL_NONE }, //int children[ 3 ]; ABUILDER_COST, //int cost; diff --git a/src/game/g_buildable.c b/src/game/g_buildable.c index c9079f39..a33a209e 100644 --- a/src/game/g_buildable.c +++ b/src/game/g_buildable.c @@ -2405,7 +2405,13 @@ qboolean G_BuildableRange( vec3_t origin, float r, buildable_t buildable ) { ent = &g_entities[ entityList[ i ] ]; - if( ent->s.eType == ET_BUILDABLE && ent->s.modelindex == buildable && ent->spawned ) + if( ent->s.eType != ET_BUILDABLE ) + continue; + + if( ent->biteam == BIT_HUMANS && !ent->powered ) + continue; + + if( ent->s.modelindex == buildable && ent->spawned ) return qtrue; } diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c index 421fb9d5..42273bc0 100644 --- a/src/game/g_cmds.c +++ b/src/game/g_cmds.c @@ -198,13 +198,13 @@ qboolean CheatsOk( gentity_t *ent ) { if( !g_cheats.integer ) { - trap_SendServerCommand( ent-g_entities, va( "print \"Cheats are not enabled on this server.\n\"" ) ); + trap_SendServerCommand( ent-g_entities, va( "print \"Cheats are not enabled on this server\n\"" ) ); return qfalse; } if( ent->health <= 0 ) { - trap_SendServerCommand( ent-g_entities, va( "print \"You must be alive to use this command.\n\"" ) ); + trap_SendServerCommand( ent-g_entities, va( "print \"You must be alive to use this command\n\"" ) ); return qfalse; } @@ -446,12 +446,12 @@ void Cmd_Kill_f( gentity_t *ent ) { if( ent->suicideTime == 0 ) { - trap_SendServerCommand( ent-g_entities, "print \"You will suicide in 20 seconds.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"You will suicide in 20 seconds\n\"" ); ent->suicideTime = level.time + 20000; } else if( ent->suicideTime > level.time ) { - trap_SendServerCommand( ent-g_entities, "print \"Suicide cancelled.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"Suicide cancelled\n\"" ); ent->suicideTime = 0; } } @@ -546,9 +546,9 @@ void Cmd_Team_f( gentity_t *ent ) G_ChangeTeam( ent, team ); if( team == PTE_ALIENS ) - trap_SendServerCommand( -1, va( "print \"%s" S_COLOR_WHITE " joined the aliens.\n\"", ent->client->pers.netname ) ); + trap_SendServerCommand( -1, va( "print \"%s" S_COLOR_WHITE " joined the aliens\n\"", ent->client->pers.netname ) ); else if( team == PTE_HUMANS ) - trap_SendServerCommand( -1, va( "print \"%s" S_COLOR_WHITE " joined the humans.\n\"", ent->client->pers.netname ) ); + trap_SendServerCommand( -1, va( "print \"%s" S_COLOR_WHITE " joined the humans\n\"", ent->client->pers.netname ) ); } @@ -724,25 +724,25 @@ void Cmd_CallVote_f( gentity_t *ent ) if( !g_allowVote.integer ) { - trap_SendServerCommand( ent-g_entities, "print \"Voting not allowed here.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"Voting not allowed here\n\"" ); return; } if( level.voteTime ) { - trap_SendServerCommand( ent-g_entities, "print \"A vote is already in progress.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"A vote is already in progress\n\"" ); return; } if( ent->client->pers.voteCount >= MAX_VOTE_COUNT ) { - trap_SendServerCommand( ent-g_entities, "print \"You have called the maximum number of votes.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"You have called the maximum number of votes\n\"" ); return; } if( ent->client->ps.stats[ STAT_PTEAM ] == PTE_NONE ) { - trap_SendServerCommand( ent-g_entities, "print \"Not allowed to call a vote as spectator.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"Not allowed to call a vote as spectator\n\"" ); return; } @@ -752,7 +752,7 @@ void Cmd_CallVote_f( gentity_t *ent ) if( strchr( arg1, ';' ) || strchr( arg2, ';' ) ) { - trap_SendServerCommand( ent-g_entities, "print \"Invalid vote string.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"Invalid vote string\n\"" ); return; } @@ -764,10 +764,10 @@ void Cmd_CallVote_f( gentity_t *ent ) else if( !Q_stricmp( arg1, "timelimit" ) ) { } else { - trap_SendServerCommand( ent-g_entities, "print \"Invalid vote string.\n\"" ); + trap_SendServerCommand( ent-g_entities, "print \"Invalid vote string\n\"" ); trap_SendServerCommand( ent-g_entities, "print \"Vote commands are: map_restart, nextmap, map , " "kick , clientkick , " - "timelimit