From 57a35e0872cb02ab537e7ff8a61858bf22ddce4c Mon Sep 17 00:00:00 2001 From: driAn Date: Thu, 27 Apr 2006 18:07:39 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@283 e016b1c5-ed68-44aa-a2f7-31cac88cffde --- source/src/client.cpp | 2 +- source/src/clientextras.cpp | 2 +- source/src/clients2c.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/src/client.cpp b/source/src/client.cpp index d901a4b7..47e0db15 100644 --- a/source/src/client.cpp +++ b/source/src/client.cpp @@ -53,7 +53,7 @@ void ctf_team(char *name) }; void newname(char *name) { c2sinit = false; strn0cpy(player1->name, name, 16); }; -void newskin(int skin) { player1->nextskin = min(0, max(skin, (rb_team_int(player1->team)==TEAM_CLA ? 3 : 5))); c2sinit=false; }; +void newskin(int skin) { player1->nextskin = max(0, min(skin, (rb_team_int(player1->team)==TEAM_CLA ? 3 : 5))); c2sinit=false; }; void newteam(char *name) { if(m_teammode) ctf_team(name); diff --git a/source/src/clientextras.cpp b/source/src/clientextras.cpp index 1d047518..34166223 100644 --- a/source/src/clientextras.cpp +++ b/source/src/clientextras.cpp @@ -52,7 +52,7 @@ void renderplayer(dynent *d) if(!d) return; int team = rb_team_int(d->team); - sprintf_sd(mdl)("playermodels/%s/0%i", team==TEAM_CLA ? "terrorist" : "counterterrorist", 1 + min(0, max(d->skin, (rb_team_int(d->team)==TEAM_CLA ? 3 : 5)))); + sprintf_sd(mdl)("playermodels/%s/0%i", team==TEAM_CLA ? "terrorist" : "counterterrorist", 1 + max(0, min(d->skin, (team==TEAM_CLA ? 3 : 5)))); renderclient(d, isteam(player1->team, d->team), mdl, false, 1.6f); if(d->gunselect>=0 && d->gunselectname, text); sgetstr(); strcpy_s(d->team, text); - getint(p); + d->skin = getint(p); d->lifesequence = getint(p); break; };