bool autocvar_sv_curl_serverpackages_auto;
bool autocvar_sv_db_saveasdump;
bool autocvar_sv_defaultcharacter;
+bool autocvar_sv_defaultcharacterskin;
string autocvar_sv_defaultplayercolors;
string autocvar_sv_defaultplayermodel;
string autocvar_sv_defaultplayermodel_blue;
defaultmodel = substring(defaultmodel, 0, i);
}
}
+ if(autocvar_sv_defaultcharacterskin && !defaultskin)
+ {
+ if(teamplay)
+ {
+ string s = Static_Team_ColorName_Lower(player.team);
+ if (s != "neutral")
+ defaultskin = cvar(strcat("sv_defaultplayerskin_", s));
+ }
+
+ if(!defaultskin)
+ defaultskin = autocvar_sv_defaultplayerskin;
+ }
+
MUTATOR_CALLHOOK(FixPlayermodel, defaultmodel, defaultskin);
defaultmodel = ret_string;
defaultskin = ret_int;
chmdl = true;
}
- oldskin = player.skin;
- player.skin = stof(player.playerskin);
+ if(!autocvar_sv_defaultcharacterskin)
+ {
+ oldskin = player.skin;
+ player.skin = stof(player.playerskin);
+ }
+ else
+ {
+ oldskin = player.skin;
+ player.skin = defaultskin;
+ }
}
if(chmdl || oldskin != player.skin) // model or skin has changed
BADCVAR("sv_autotaunt");
BADCVAR("sv_curl_defaulturl");
BADCVAR("sv_defaultcharacter");
+ BADCVAR("sv_defaultcharacterskin");
BADCVAR("sv_defaultplayercolors");
BADCVAR("sv_defaultplayermodel");
BADCVAR("sv_defaultplayerskin");