diff options
-rw-r--r-- | src/cgame/cg_event.c | 4 | ||||
-rw-r--r-- | src/game/bg_misc.c | 26 | ||||
-rw-r--r-- | src/game/bg_pmove.c | 19 | ||||
-rw-r--r-- | src/game/g_client.c | 2 | ||||
-rw-r--r-- | src/game/g_cmds.c | 54 | ||||
-rw-r--r-- | src/game/g_main.c | 3 | ||||
-rw-r--r-- | src/game/tremulous.h | 51 |
7 files changed, 102 insertions, 57 deletions
diff --git a/src/cgame/cg_event.c b/src/cgame/cg_event.c index ca13b0ab..992db57c 100644 --- a/src/cgame/cg_event.c +++ b/src/cgame/cg_event.c @@ -159,8 +159,8 @@ static void CG_Obituary( entityState_t *ent ) { char *s; - s = va( "You fragged %s", targetName ); - CG_CenterPrint( s, SCREEN_HEIGHT * 0.30, BIGCHAR_WIDTH ); +/* s = va( "You fragged %s", targetName ); + CG_CenterPrint( s, SCREEN_HEIGHT * 0.30, BIGCHAR_WIDTH );*/ // print the text message as well } diff --git a/src/game/bg_misc.c b/src/game/bg_misc.c index 7d5a2b91..63c4cad7 100644 --- a/src/game/bg_misc.c +++ b/src/game/bg_misc.c @@ -1339,14 +1339,14 @@ classAttributes_t bg_classList[ ] = PCL_A_O_LEV1, //int classnum; "dragoon", //char *classname; "Dragoon", //char *humanname; - "jumper", //char *modelname; - 0.3f, //float modelScale; - "red", //char *skinname; + "prowl", //char *modelname; + 0.75f, //float modelScale; + "default", //char *skinname; "alien_hud", //char *hudname; ( 1 << S1 )|( 1 << S2 )|( 1 << S3 ), //int stages - { -24, -24, -9 }, //vec3_t mins; - { 24, 24, 9 }, //vec3_t maxs; - { 24, 24, 9 }, //vec3_t crouchmaxs; + { -24, -24, -16 }, //vec3_t mins; + { 24, 24, 16 }, //vec3_t maxs; + { 24, 24, 16 }, //vec3_t crouchmaxs; { -24, -24, -4 }, //vec3_t deadmins; { 24, 24, 4 }, //vec3_t deadmaxs; 18, 18, //int viewheight, crouchviewheight; @@ -1369,14 +1369,14 @@ classAttributes_t bg_classList[ ] = PCL_A_O_LEV1_UPG, //int classnum; "dragoonupg", //char *classname; "Dragoon Upgrade", //char *humanname; - "jumper", //char *modelname; - 0.4f, //float modelScale; - "blue", //char *skinname; + "prowl", //char *modelname; + 0.75f, //float modelScale; + "default", //char *skinname; "alien_hud", //char *hudname; ( 1 << S1 )|( 1 << S2 )|( 1 << S3 ), //int stages - { -24, -24, -11 }, //vec3_t mins; - { 24, 24, 11 }, //vec3_t maxs; - { 24, 24, 11 }, //vec3_t crouchmaxs; + { -24, -24, -16 }, //vec3_t mins; + { 24, 24, 16 }, //vec3_t maxs; + { 24, 24, 16 }, //vec3_t crouchmaxs; { -24, -24, -4 }, //vec3_t deadmins; { 24, 24, 4 }, //vec3_t deadmaxs; 20, 20, //int viewheight, crouchviewheight; @@ -1461,7 +1461,7 @@ classAttributes_t bg_classList[ ] = PCL_A_O_LEV3, //int classnum; "chimera", //char *classname; "Chimera", //char *humanname; - "prowl", //char *modelname; + "tarantula", //char *modelname; 0.75f, //float modelScale; "default", //char *skinname; "alien_hud", //char *hudname; diff --git a/src/game/bg_pmove.c b/src/game/bg_pmove.c index f8615e30..16f67a6b 100644 --- a/src/game/bg_pmove.c +++ b/src/game/bg_pmove.c @@ -484,6 +484,25 @@ static qboolean PM_CheckPounce( void ) PM_AddEvent( EV_JUMP ); + if( pm->cmd.forwardmove >= 0 ) + { + if( !( pm->ps->persistant[ PERS_STATE ] & PS_NONSEGMODEL ) ) + PM_ForceLegsAnim( LEGS_JUMP ); + else + PM_ForceLegsAnim( NSPA_JUMP ); + + pm->ps->pm_flags &= ~PMF_BACKWARDS_JUMP; + } + else + { + if( !( pm->ps->persistant[ PERS_STATE ] & PS_NONSEGMODEL ) ) + PM_ForceLegsAnim( LEGS_JUMPB ); + else + PM_ForceLegsAnim( NSPA_JUMPBACK ); + + pm->ps->pm_flags |= PMF_BACKWARDS_JUMP; + } + return qtrue; } diff --git a/src/game/g_client.c b/src/game/g_client.c index 77846960..fe220be9 100644 --- a/src/game/g_client.c +++ b/src/game/g_client.c @@ -1164,7 +1164,7 @@ void ClientUserinfoChanged( int clientNum ) trap_SetConfigstring( CS_PLAYERS + clientNum, s ); - G_LogPrintf( "ClientUserinfoChanged: %i %s\n", clientNum, s ); + /*G_LogPrintf( "ClientUserinfoChanged: %i %s\n", clientNum, s );*/ } diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c index 96b28f52..e85b775d 100644 --- a/src/game/g_cmds.c +++ b/src/game/g_cmds.c @@ -1011,13 +1011,13 @@ void Cmd_Class_f( gentity_t *ent ) } numLevels = BG_ClassCanEvolveFromTo( ent->client->ps.stats[ STAT_PCLASS ], ent->client->pers.pclass, - ent->client->ps.persistant[ PERS_CREDIT ], 0 ); + (short)ent->client->ps.persistant[ PERS_CREDIT ], 0 ); //...check we can evolve to that class if( numLevels && BG_FindStagesForClass( ent->client->pers.pclass, g_alienStage.integer ) ) { //remove credit - ent->client->ps.persistant[ PERS_CREDIT ] -= numLevels - 1; + ent->client->ps.persistant[ PERS_CREDIT ] -= (short)( numLevels - 1 ); //prevent lerping ent->client->ps.eFlags ^= EF_TELEPORT_BIT; @@ -1313,8 +1313,14 @@ void Cmd_Buy_f( gentity_t *ent ) } //can afford this? - if( BG_FindPriceForWeapon( weapon ) > ent->client->ps.persistant[ PERS_CREDIT ] ) + if( BG_FindPriceForWeapon( weapon ) > (short)ent->client->ps.persistant[ PERS_CREDIT ] ) { + G_LogPrintf( "Client %d buying weapon %d, value %d, credit %d\n", + ent->client->ps.clientNum, + weapon, + BG_FindPriceForWeapon( weapon ), + (short)ent->client->ps.persistant[ PERS_CREDIT ] ); + G_AddPredictableEvent( ent, EV_MENU, MN_H_NOFUNDS ); return; } @@ -1363,7 +1369,7 @@ void Cmd_Buy_f( gentity_t *ent ) ent->client->ps.stats[ STAT_MISC ] = 0; //subtract from funds - ent->client->ps.persistant[ PERS_CREDIT ] -= BG_FindPriceForWeapon( weapon ); + ent->client->ps.persistant[ PERS_CREDIT ] -= (short)BG_FindPriceForWeapon( weapon ); } else if( upgrade != UP_NONE ) { @@ -1378,9 +1384,15 @@ void Cmd_Buy_f( gentity_t *ent ) } //can afford this? - if( BG_FindPriceForUpgrade( upgrade ) > ent->client->ps.persistant[ PERS_CREDIT ] ) + if( BG_FindPriceForUpgrade( upgrade ) > (short)ent->client->ps.persistant[ PERS_CREDIT ] ) { G_AddPredictableEvent( ent, EV_MENU, MN_H_NOFUNDS ); + G_LogPrintf( "Client %d buying upgrade %d, value %d, credit %d\n", + ent->client->ps.clientNum, + weapon, + BG_FindPriceForWeapon( upgrade ), + (short)ent->client->ps.persistant[ PERS_CREDIT ] ); + return; } @@ -1442,7 +1454,7 @@ void Cmd_Buy_f( gentity_t *ent ) } //subtract from funds - ent->client->ps.persistant[ PERS_CREDIT ] -= BG_FindPriceForUpgrade( upgrade ); + ent->client->ps.persistant[ PERS_CREDIT ] -= (short)BG_FindPriceForUpgrade( upgrade ); } else { @@ -1510,7 +1522,7 @@ void Cmd_Sell_f( gentity_t *ent ) BG_removeWeapon( weapon, ent->client->ps.stats ); //add to funds - ent->client->ps.persistant[ PERS_CREDIT ] += BG_FindPriceForWeapon( weapon ); + ent->client->ps.persistant[ PERS_CREDIT ] += (short)BG_FindPriceForWeapon( weapon ); } //if we have this weapon selected, force a new selection @@ -1525,7 +1537,7 @@ void Cmd_Sell_f( gentity_t *ent ) BG_removeItem( upgrade, ent->client->ps.stats ); //add to funds - ent->client->ps.persistant[ PERS_CREDIT ] += BG_FindPriceForUpgrade( upgrade ); + ent->client->ps.persistant[ PERS_CREDIT ] += (short)BG_FindPriceForUpgrade( upgrade ); } //if we have this upgrade selected, force a new selection @@ -1571,7 +1583,7 @@ void Cmd_Deposit_f( gentity_t *ent ) } if( !Q_stricmp( s, "all" ) ) - amount = ent->client->ps.persistant[ PERS_CREDIT ]; + amount = (short)ent->client->ps.persistant[ PERS_CREDIT ]; else amount = atoi( s ); @@ -1582,9 +1594,14 @@ void Cmd_Deposit_f( gentity_t *ent ) return; } - if( amount <= ent->client->ps.persistant[ PERS_CREDIT ] ) + G_LogPrintf( "Client %d depositing %d with credit %d\n", + ent->client->ps.clientNum, + amount, + (short)ent->client->ps.persistant[ PERS_CREDIT ] ); + + if( amount <= (short)ent->client->ps.persistant[ PERS_CREDIT ] ) { - ent->client->ps.persistant[ PERS_CREDIT ] -= amount; + ent->client->ps.persistant[ PERS_CREDIT ] -= (short)amount; ent->client->ps.persistant[ PERS_BANK ] += amount; level.bankCredits[ ent->client->ps.clientNum ] += amount; } @@ -1607,7 +1624,7 @@ void Cmd_Deposit_f( gentity_t *ent ) } if( !Q_stricmp( s, "all" ) ) - amount = ent->client->ps.persistant[ PERS_CREDIT ]; + amount = (short)ent->client->ps.persistant[ PERS_CREDIT ]; else amount = atoi( s ); @@ -1618,9 +1635,9 @@ void Cmd_Deposit_f( gentity_t *ent ) return; } - if( amount <= ent->client->ps.persistant[ PERS_CREDIT ] ) + if( amount <= (short)ent->client->ps.persistant[ PERS_CREDIT ] ) { - ent->client->ps.persistant[ PERS_CREDIT ] -= amount; + ent->client->ps.persistant[ PERS_CREDIT ] -= (short)amount; ent->client->ps.persistant[ PERS_BANK ] += amount; level.bankCredits[ ent->client->ps.clientNum ] += amount; } @@ -1673,9 +1690,14 @@ void Cmd_Withdraw_f( gentity_t *ent ) return; } + G_LogPrintf( "Client %d withdrawing %d with credit %d\n", + ent->client->ps.clientNum, + amount, + (short)level.bankCredits[ ent->client->ps.clientNum ] ); + if( amount <= level.bankCredits[ ent->client->ps.clientNum ] ) { - ent->client->ps.persistant[ PERS_CREDIT ] += amount; + ent->client->ps.persistant[ PERS_CREDIT ] += (short)amount; ent->client->ps.persistant[ PERS_BANK ] -= amount; level.bankCredits[ ent->client->ps.clientNum ] -= amount; } @@ -1711,7 +1733,7 @@ void Cmd_Withdraw_f( gentity_t *ent ) if( amount <= level.bankCredits[ ent->client->ps.clientNum ] ) { - ent->client->ps.persistant[ PERS_CREDIT ] += amount; + ent->client->ps.persistant[ PERS_CREDIT ] += (short)amount; ent->client->ps.persistant[ PERS_BANK ] -= amount; level.bankCredits[ ent->client->ps.clientNum ] -= amount; } diff --git a/src/game/g_main.c b/src/game/g_main.c index dbaef63b..d711216c 100644 --- a/src/game/g_main.c +++ b/src/game/g_main.c @@ -241,7 +241,8 @@ void QDECL G_Printf( const char *fmt, ... ) vsprintf( text, fmt, argptr ); va_end( argptr ); - trap_SendServerCommand( -1, va( "gprintf \"%s\"", text ) ); + if( !g_dedicated.integer ) + trap_SendServerCommand( -1, va( "gprintf \"%s\"", text ) ); trap_Printf( text ); } diff --git a/src/game/tremulous.h b/src/game/tremulous.h index 1c554f07..7d068c75 100644 --- a/src/game/tremulous.h +++ b/src/game/tremulous.h @@ -66,10 +66,10 @@ #define CHIMERA_CLAW_RANGE 96.0f #define CHIMERA_CLAW_REPEAT 400 #define CHIMERA_CLAW_U_REPEAT 300 -#define CHIMERA_AREAZAP_DMG ADM(125) +#define CHIMERA_AREAZAP_DMG ADM(75) #define CHIMERA_AREAZAP_RANGE 200.0f #define CHIMERA_AREAZAP_REPEAT 1500 -#define CHIMERA_DIRECTZAP_DMG ADM(125) +#define CHIMERA_DIRECTZAP_DMG ADM(75) #define CHIMERA_DIRECTZAP_RANGE 200.0f #define CHIMERA_DIRECTZAP_REPEAT 1500 @@ -99,61 +99,64 @@ #define ALIEN_HLTH_MODIFIER 1.0f #define AHM(h) ((int)((float)h*ALIEN_HLTH_MODIFIER)) +#define ALIEN_VALUE_MODIFIER 3.0f +#define AVM(h) ((int)((float)h*ALIEN_VALUE_MODIFIER)) + #define ABUILDER_SPEED 0.8f #define ABUILDER_TTE 2000 -#define ABUILDER_VALUE 50 +#define ABUILDER_VALUE AVM(50) #define ABUILDER_HEALTH AHM(50) #define ABUILDER_REGEN 2 #define ABUILDER_UPG_SPEED 1.0f -#define ABUILDER_UPG_VALUE 120 +#define ABUILDER_UPG_VALUE AVM(120) #define ABUILDER_UPG_HEALTH AHM(75) #define ABUILDER_UPG_REGEN 3 -#define SOLDIER_SPEED 1.5f +#define SOLDIER_SPEED 1.3f #define SOLDIER_TTE 2000 -#define SOLDIER_VALUE 50 +#define SOLDIER_VALUE AVM(50) #define SOLDIER_HEALTH AHM(25) #define SOLDIER_REGEN 1 -#define DRAGOON_SPEED 1.5f +#define DRAGOON_SPEED 1.3f #define DRAGOON_TTE 3000 -#define DRAGOON_VALUE 100 +#define DRAGOON_VALUE AVM(100) #define DRAGOON_HEALTH AHM(50) #define DRAGOON_REGEN 2 -#define DRAGOON_UPG_SPEED 1.5f +#define DRAGOON_UPG_SPEED 1.3f #define DRAGOON_UPG_TTE 3000 -#define DRAGOON_UPG_VALUE 120 +#define DRAGOON_UPG_VALUE AVM(120) #define DRAGOON_UPG_HEALTH AHM(60) #define DRAGOON_UPG_REGEN 3 -#define HYDRA_SPEED 1.5f +#define HYDRA_SPEED 1.25f #define HYDRA_TTE 3000 #define HYDRA_VALUE 200 #define HYDRA_HEALTH AHM(100) #define HYDRA_REGEN 5 -#define HYDRA_UPG_SPEED 1.5f +#define HYDRA_UPG_SPEED 1.25f #define HYDRA_UPG_TTE 3000 -#define HYDRA_UPG_VALUE 240 +#define HYDRA_UPG_VALUE AVM(240) #define HYDRA_UPG_HEALTH AHM(120) #define HYDRA_UPG_REGEN 6 -#define CHIMERA_SPEED 1.3f +#define CHIMERA_SPEED 1.2f #define CHIMERA_TTE 3000 -#define CHIMERA_VALUE 300 +#define CHIMERA_VALUE AVM(300) #define CHIMERA_HEALTH AHM(200) #define CHIMERA_REGEN 7 -#define CHIMERA_UPG_SPEED 1.3f +#define CHIMERA_UPG_SPEED 1.2f #define CHIMERA_UPG_TTE 3000 -#define CHIMERA_UPG_VALUE 360 +#define CHIMERA_UPG_VALUE AVM(360) #define CHIMERA_UPG_HEALTH AHM(250) #define CHIMERA_UPG_REGEN 10 -#define BMOFO_SPEED 1.2f -#define BMOFO_VALUE 400 +#define BMOFO_SPEED 1.1f +#define BMOFO_VALUE AVM(400) #define BMOFO_HEALTH AHM(400) #define BMOFO_REGEN 15 @@ -278,7 +281,7 @@ #define RIFLE_RELOAD 2000 #define RIFLE_PRICE 0 #define RIFLE_SPREAD 200 -#define RIFLE_DMG HDM(7) +#define RIFLE_DMG HDM(9) #define CHAINGUN_BULLETS 300 #define CHAINGUN_REPEAT 50 @@ -414,7 +417,7 @@ #define MGTURRET_HEALTH HBHM(100) #define MGTURRET_SPLASHDAMAGE 50 #define MGTURRET_SPLASHRADIUS 1000 -#define MGTURRET_ANGULARSPEED 20 //degrees/think ~= 200deg/sec +#define MGTURRET_ANGULARSPEED 5 //degrees/think ~= 200deg/sec #define MGTURRET_ACCURACYTOLERANCE MGTURRET_ANGULARSPEED / 2 //angular difference for turret to fire #define MGTURRET_VERTICALCAP 30 // +/- maximum pitch #define MGTURRET_REPEAT 100 @@ -463,9 +466,9 @@ * HUMAN misc */ -#define HUMAN_JOG_MODIFIER 0.8f -#define HUMAN_BACK_MODIFIER 0.5f -#define HUMAN_SIDE_MODIFIER 0.75f +#define HUMAN_JOG_MODIFIER 0.9f +#define HUMAN_BACK_MODIFIER 0.7f +#define HUMAN_SIDE_MODIFIER 0.8f #define STAMINA_STOP_RESTORE 10 #define STAMINA_WALK_RESTORE 5 |