summaryrefslogtreecommitdiff
path: root/src/game/g_cmds.c
diff options
context:
space:
mode:
authorChristopher Schwarz <lakitu7@gmail.com>2009-10-03 12:30:21 +0000
committerTim Angus <tim@ngus.net>2013-01-03 00:16:01 +0000
commit9d8ede7ce116b3c5037aca9468cd85538587c46c (patch)
tree41e87a1a6e756841af8ccde3139e23d1992e5bf3 /src/game/g_cmds.c
parented462a3158d795d9effc9826e08f97d920330d04 (diff)
* Fix /give funds being broken by the fractional alien credits refactor
Diffstat (limited to 'src/game/g_cmds.c')
-rw-r--r--src/game/g_cmds.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/game/g_cmds.c b/src/game/g_cmds.c
index d920b955..250ee9e4 100644
--- a/src/game/g_cmds.c
+++ b/src/game/g_cmds.c
@@ -366,7 +366,14 @@ void Cmd_Give_f( gentity_t *ent )
if( give_all || Q_stricmpn( name, "funds", 5 ) == 0 )
{
- int credits = give_all ? ALIEN_MAX_CREDITS : atoi( name + 6 );
+ int credits = atoi( name + 6 );
+
+ if( ent->client->pers.teamSelection == TEAM_ALIENS )
+ credits *= ALIEN_CREDITS_PER_FRAG;
+
+ if( give_all )
+ credits = ALIEN_MAX_CREDITS;
+
G_AddCreditToClient( ent->client, credits, qtrue );
}