mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2024-11-10 23:32:06 +00:00
Tweaking the replacement system a bit. Reactionmale now the default model
This commit is contained in:
parent
795160e9e4
commit
8dd02519ac
15 changed files with 398 additions and 205 deletions
|
@ -1,5 +1,6 @@
|
|||
# List fixes here for the 3.0 release
|
||||
|
||||
* Reactionmale is now the default model
|
||||
* Fixed Ignore so it now works on players with colored nicks
|
||||
* Added tmpbans on votekicks
|
||||
* Version now 3.0
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.71 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.70 2003/03/09 21:30:38 jbravo
|
||||
// Adding unlagged. Still needs work.
|
||||
//
|
||||
|
@ -529,7 +532,8 @@ static void CG_DrawStatusBar(void)
|
|||
|
||||
icon = cg_weapons[cg.predictedPlayerState.weapon].ammoIcon;
|
||||
//Don't draw ammo icon if holding grenade or knife
|
||||
if (icon && cg.predictedPlayerState.weapon != WP_KNIFE && cg.predictedPlayerState.weapon != WP_GRENADE)
|
||||
//if (icon && cg.predictedPlayerState.weapon != WP_KNIFE && cg.predictedPlayerState.weapon != WP_GRENADE)
|
||||
if (icon)
|
||||
CG_DrawPic(252, 440, SMICON_SIZE, SMICON_SIZE, icon);
|
||||
|
||||
if (cent->currentState.weapon) {
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.138 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.137 2003/03/09 21:30:38 jbravo
|
||||
// Adding unlagged. Still needs work.
|
||||
//
|
||||
|
@ -391,12 +394,12 @@
|
|||
#define MAX_MODEL_LEN 128
|
||||
|
||||
// Elder: changed to good ol' resdog
|
||||
#define DEFAULT_MODEL "grunt"
|
||||
#define DEFAULT_MODEL "reactionmale"
|
||||
// Elder: this is added
|
||||
#define DEFAULT_SKIN "resdog"
|
||||
#define DEFAULT_SKIN "default"
|
||||
|
||||
#define DEFAULT_TEAM_MODEL "grunt"
|
||||
#define DEFAULT_TEAM_HEAD "grunt"
|
||||
#define DEFAULT_TEAM_MODEL "reactionmale"
|
||||
#define DEFAULT_TEAM_HEAD "reactionmale"
|
||||
|
||||
// Elder: Changed
|
||||
#define DEFAULT_REDTEAM_NAME "Reservoir Dogs"
|
||||
|
@ -776,6 +779,7 @@ typedef struct weaponInfo_s {
|
|||
qhandle_t ammoIcon;
|
||||
|
||||
qhandle_t ammoModel;
|
||||
qhandle_t ammocustomSkin;
|
||||
|
||||
qhandle_t missileModel;
|
||||
sfxHandle_t missileSound;
|
||||
|
@ -1756,6 +1760,12 @@ extern vmCvar_t cg_RQ3_ammo_shells;
|
|||
extern vmCvar_t cg_RQ3_ammo_ssg3000;
|
||||
extern vmCvar_t cg_RQ3_ammo_mp5;
|
||||
extern vmCvar_t cg_RQ3_ammo_m4;
|
||||
// JBravo: replacement skins
|
||||
extern vmCvar_t cg_RQ3_ammo_mk23_skin;
|
||||
extern vmCvar_t cg_RQ3_ammo_shells_skin;
|
||||
extern vmCvar_t cg_RQ3_ammo_ssg3000_skin;
|
||||
extern vmCvar_t cg_RQ3_ammo_mp5_skin;
|
||||
extern vmCvar_t cg_RQ3_ammo_m4_skin;
|
||||
|
||||
//Blaze: Reaction weapon positions
|
||||
//extern vmCvar_t cg_RQ3_drawWeapon;
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.127 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.126 2003/03/22 20:29:26 jbravo
|
||||
// wrapping linkent and unlinkent calls
|
||||
//
|
||||
|
@ -494,6 +497,12 @@ vmCvar_t cg_RQ3_ammo_shells;
|
|||
vmCvar_t cg_RQ3_ammo_ssg3000;
|
||||
vmCvar_t cg_RQ3_ammo_mp5;
|
||||
vmCvar_t cg_RQ3_ammo_m4;
|
||||
// JBravo: replacement skin cvars
|
||||
vmCvar_t cg_RQ3_ammo_mk23_skin;
|
||||
vmCvar_t cg_RQ3_ammo_shells_skin;
|
||||
vmCvar_t cg_RQ3_ammo_ssg3000_skin;
|
||||
vmCvar_t cg_RQ3_ammo_mp5_skin;
|
||||
vmCvar_t cg_RQ3_ammo_m4_skin;
|
||||
|
||||
//Elder: muzzle flash toggle
|
||||
vmCvar_t cg_RQ3_flash;
|
||||
|
@ -755,7 +764,6 @@ static cvarTable_t cvarTable[] = { // bk001129
|
|||
{&cg_RQ3_m3_skin, "cg_RQ3_m3_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_akimbo_skin, "cg_RQ3_akimbo_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_grenade_skin, "cg_RQ3_grenade_skin", "default", CVAR_ARCHIVE},
|
||||
|
||||
//Blaze: replacement items
|
||||
{&cg_RQ3_bandolier, "cg_RQ3_bandolier", "bandolier", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_kevlar, "cg_RQ3_kevlar", "kevlar", CVAR_ARCHIVE},
|
||||
|
@ -776,6 +784,12 @@ static cvarTable_t cvarTable[] = { // bk001129
|
|||
{&cg_RQ3_ammo_ssg3000, "cg_RQ3_ammo_ssg3000", "ssg3000", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_mp5, "cg_RQ3_ammo_mp5", "mp5", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_m4, "cg_RQ3_ammo_m4", "m4", CVAR_ARCHIVE},
|
||||
// JBravo: replacement skins
|
||||
{&cg_RQ3_ammo_mk23_skin, "cg_RQ3_ammo_mk23_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_shells_skin, "cg_RQ3_ammo_shells_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_ssg3000_skin, "cg_RQ3_ammo_ssg3000_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_mp5_skin, "cg_RQ3_ammo_mp5_skin", "default", CVAR_ARCHIVE},
|
||||
{&cg_RQ3_ammo_m4_skin, "cg_RQ3_ammo_m4_skin", "default", CVAR_ARCHIVE},
|
||||
|
||||
// the following variables are created in other parts of the system,
|
||||
// but we also reference them here
|
||||
|
@ -861,8 +875,8 @@ static cvarTable_t cvarTable[] = { // bk001129
|
|||
// { &cg_RQ3_team_round_going, "cg_RQ3_team_round_going", "0", CVAR_ROM},
|
||||
{&cg_RQ3_team1name, "g_RQ3_team1name", "0", 0},
|
||||
{&cg_RQ3_team2name, "g_RQ3_team2name", "0", 0},
|
||||
{&cg_RQ3_team1model, "g_RQ3_team1model", "grunt/robber", 0},
|
||||
{&cg_RQ3_team2model, "g_RQ3_team2model", "grunt/police", 0},
|
||||
{&cg_RQ3_team1model, "g_RQ3_team1model", "reactionmale/default", 0},
|
||||
{&cg_RQ3_team2model, "g_RQ3_team2model", "reactionmale/robber", 0},
|
||||
{&ui_RQ3_teamCount1, "ui_RQ3_teamCount1", "0", CVAR_ROM},
|
||||
{&ui_RQ3_teamCount2, "ui_RQ3_teamCount2", "0", CVAR_ROM},
|
||||
{&ui_RQ3_numSpectators, "ui_RQ3_numSpectators", "0", CVAR_ROM},
|
||||
|
@ -935,6 +949,48 @@ void CG_RegisterCvars(void)
|
|||
trap_Cvar_Register(NULL, "headmodel", DEFAULT_MODEL, CVAR_USERINFO | CVAR_ARCHIVE);
|
||||
trap_Cvar_Register(NULL, "team_model", DEFAULT_TEAM_MODEL, CVAR_USERINFO | CVAR_ARCHIVE);
|
||||
trap_Cvar_Register(NULL, "team_headmodel", DEFAULT_TEAM_HEAD, CVAR_USERINFO | CVAR_ARCHIVE);
|
||||
|
||||
// JBravo: for defaults in weaponreplacements
|
||||
if (!strcmp(cg_RQ3_mk23.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_mk23", "mk23");
|
||||
if (!strcmp(cg_RQ3_knife.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_knife", "knife");
|
||||
if (!strcmp(cg_RQ3_m4.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_m4", "m4");
|
||||
if (!strcmp(cg_RQ3_ssg3000.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ssg3000", "ssg3000");
|
||||
if (!strcmp(cg_RQ3_mp5.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_mp5", "mp5");
|
||||
if (!strcmp(cg_RQ3_handcannon.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_handcannon", "handcannon");
|
||||
if (!strcmp(cg_RQ3_m3.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_m3", "m3");
|
||||
if (!strcmp(cg_RQ3_akimbo.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_akimbo", "akimbo");
|
||||
if (!strcmp(cg_RQ3_grenade.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_grenade", "grenade");
|
||||
if (!strcmp(cg_RQ3_kevlar.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_kevlar", "kevlar");
|
||||
if (!strcmp(cg_RQ3_silencer.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_silencer", "silencer");
|
||||
if (!strcmp(cg_RQ3_laser.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_laser", "laser");
|
||||
if (!strcmp(cg_RQ3_bandolier.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_bandolier", "bandolier");
|
||||
if (!strcmp(cg_RQ3_slippers.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_slippers", "slippers");
|
||||
if (!strcmp(cg_RQ3_helmet.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_helmet", "helmet");
|
||||
if (!strcmp(cg_RQ3_ammo_mk23.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ammo_mk23", "mk23");
|
||||
if (!strcmp(cg_RQ3_ammo_shells.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ammo_shells", "shells");
|
||||
if (!strcmp(cg_RQ3_ammo_ssg3000.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ammo_ssg3000", "ssg3000");
|
||||
if (!strcmp(cg_RQ3_ammo_mp5.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ammo_mp5", "mp5");
|
||||
if (!strcmp(cg_RQ3_ammo_m4.string, "default"))
|
||||
trap_Cvar_Set("cg_RQ3_ammo_m4", "m4");
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -2328,17 +2384,19 @@ Routine by JBravo to replace world_models in bg_itemlist
|
|||
void CG_ReplaceModels(void)
|
||||
{
|
||||
gitem_t *item;
|
||||
char str[256];
|
||||
|
||||
for (item = bg_itemlist + 1; item->classname; item++) {
|
||||
if (!strcmp(item->classname, "weapon_knife")) {
|
||||
if (strcmp(cg_RQ3_knife.string, "knife")) {
|
||||
Com_sprintf(RQ3_knife_model, MAX_MODEL_LEN, "models/weapons2/%s/knife.md3", cg_RQ3_knife.string);
|
||||
Com_sprintf(RQ3_knife_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_knife.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_knife", str, sizeof(str));
|
||||
if (strcmp(str, "knife")) {
|
||||
Com_sprintf(RQ3_knife_model, MAX_MODEL_LEN, "models/weapons2/%s/knife.md3", str);
|
||||
Com_sprintf(RQ3_knife_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_knife_model) && (strlen(RQ3_knife_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_knife_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_knife_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading knife replacement model %s\n", cg_RQ3_knife.string);
|
||||
CG_Printf("^1Error loading knife replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_knife_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_knife_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_knife_skin.string);
|
||||
|
@ -2349,14 +2407,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_pistol")) {
|
||||
if (strcmp(cg_RQ3_mk23.string, "mk23")) {
|
||||
Com_sprintf(RQ3_pistol_model, MAX_MODEL_LEN, "models/weapons2/%s/mk23.md3", cg_RQ3_mk23.string);
|
||||
Com_sprintf(RQ3_pistol_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_mk23.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_mk23", str, sizeof(str));
|
||||
if (strcmp(str, "mk23")) {
|
||||
Com_sprintf(RQ3_pistol_model, MAX_MODEL_LEN, "models/weapons2/%s/mk23.md3", str);
|
||||
Com_sprintf(RQ3_pistol_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_pistol_model) && (strlen(RQ3_pistol_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_pistol_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_pistol_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading pistol replacement model %s\n", cg_RQ3_mk23.string);
|
||||
CG_Printf("^1Error loading pistol replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_mk23_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_pistol_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_mk23_skin.string);
|
||||
|
@ -2367,14 +2426,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_m4")) {
|
||||
if (strcmp(cg_RQ3_m4.string, "m4")) {
|
||||
Com_sprintf(RQ3_m4_model, MAX_MODEL_LEN, "models/weapons2/%s/m4.md3", cg_RQ3_m4.string);
|
||||
Com_sprintf(RQ3_m4_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_m4.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_m4", str, sizeof(str));
|
||||
if (strcmp(str, "m4")) {
|
||||
Com_sprintf(RQ3_m4_model, MAX_MODEL_LEN, "models/weapons2/%s/m4.md3", str);
|
||||
Com_sprintf(RQ3_m4_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_m4_model) && (strlen(RQ3_m4_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_m4_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_m4_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading m4 replacement model %s\n", cg_RQ3_m4.string);
|
||||
CG_Printf("^1Error loading m4 replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_m4_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_m4_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_m4_skin.string);
|
||||
|
@ -2385,14 +2445,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_ssg3000")) {
|
||||
if (strcmp(cg_RQ3_ssg3000.string, "ssg3000")) {
|
||||
Com_sprintf(RQ3_ssg3000_model, MAX_MODEL_LEN, "models/weapons2/%s/ssg3000.md3", cg_RQ3_ssg3000.string);
|
||||
Com_sprintf(RQ3_ssg3000_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_ssg3000.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ssg3000", str, sizeof(str));
|
||||
if (strcmp(str, "ssg3000")) {
|
||||
Com_sprintf(RQ3_ssg3000_model, MAX_MODEL_LEN, "models/weapons2/%s/ssg3000.md3", str);
|
||||
Com_sprintf(RQ3_ssg3000_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_ssg3000_model) && (strlen(RQ3_ssg3000_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ssg3000_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ssg3000_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading ssg3000 replacement model %s\n", cg_RQ3_ssg3000.string);
|
||||
CG_Printf("^1Error loading ssg3000 replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_ssg3000_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ssg3000_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_ssg3000_skin.string);
|
||||
|
@ -2403,14 +2464,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_mp5")) {
|
||||
if (strcmp(cg_RQ3_mp5.string, "mp5")) {
|
||||
Com_sprintf(RQ3_mp5_model, MAX_MODEL_LEN, "models/weapons2/%s/mp5.md3", cg_RQ3_mp5.string);
|
||||
Com_sprintf(RQ3_mp5_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_mp5.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_mp5", str, sizeof(str));
|
||||
if (strcmp(str, "mp5")) {
|
||||
Com_sprintf(RQ3_mp5_model, MAX_MODEL_LEN, "models/weapons2/%s/mp5.md3", str);
|
||||
Com_sprintf(RQ3_mp5_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_mp5_model) && (strlen(RQ3_mp5_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_mp5_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_mp5_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading mp5 replacement model\n", cg_RQ3_mp5.string);
|
||||
CG_Printf("^1Error loading mp5 replacement model\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_mp5_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_mp5_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_mp5_skin.string);
|
||||
|
@ -2421,14 +2483,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_handcannon")) {
|
||||
if (strcmp(cg_RQ3_handcannon.string, "handcannon")) {
|
||||
Com_sprintf(RQ3_handcannon_model, MAX_MODEL_LEN, "models/weapons2/%s/handcannon.md3", cg_RQ3_handcannon.string);
|
||||
Com_sprintf(RQ3_handcannon_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_handcannon.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_handcannon", str, sizeof(str));
|
||||
if (strcmp(str, "handcannon")) {
|
||||
Com_sprintf(RQ3_handcannon_model, MAX_MODEL_LEN, "models/weapons2/%s/handcannon.md3", str);
|
||||
Com_sprintf(RQ3_handcannon_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_handcannon_model) && (strlen(RQ3_handcannon_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_handcannon_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_handcannon_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading handcannon replacement model %s\n", cg_RQ3_handcannon.string);
|
||||
CG_Printf("^1Error loading handcannon replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_handcannon_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_handcannon_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_handcannon_skin.string);
|
||||
|
@ -2439,14 +2502,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_m3")) {
|
||||
if (strcmp(cg_RQ3_m3.string, "m3")) {
|
||||
Com_sprintf(RQ3_m3_model, MAX_MODEL_LEN, "models/weapons2/%s/m3.md3", cg_RQ3_m3.string);
|
||||
Com_sprintf(RQ3_m3_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_m3.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_m3", str, sizeof(str));
|
||||
if (strcmp(str, "m3")) {
|
||||
Com_sprintf(RQ3_m3_model, MAX_MODEL_LEN, "models/weapons2/%s/m3.md3", str);
|
||||
Com_sprintf(RQ3_m3_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_m3_model) && (strlen(RQ3_m3_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_m3_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_m3_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading m3 replacement model %s\n", cg_RQ3_m3.string);
|
||||
CG_Printf("^1Error loading m3 replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_m3_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_m3_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_m3_skin.string);
|
||||
|
@ -2457,14 +2521,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_akimbo")) {
|
||||
if (strcmp(cg_RQ3_akimbo.string, "akimbo")) {
|
||||
Com_sprintf(RQ3_akimbo_model, MAX_MODEL_LEN, "models/weapons2/%s/akimbo.md3", cg_RQ3_akimbo.string);
|
||||
Com_sprintf(RQ3_akimbo_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_akimbo.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_akimbo", str, sizeof(str));
|
||||
if (strcmp(str, "akimbo")) {
|
||||
Com_sprintf(RQ3_akimbo_model, MAX_MODEL_LEN, "models/weapons2/%s/akimbo.md3", str);
|
||||
Com_sprintf(RQ3_akimbo_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_akimbo_model) && (strlen(RQ3_akimbo_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_akimbo_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_akimbo_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading akimbo replacement model %s\n", cg_RQ3_akimbo.string);
|
||||
CG_Printf("^1Error loading akimbo replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_akimbo_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_akimbo_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_akimbo_skin.string);
|
||||
|
@ -2475,14 +2540,15 @@ void CG_ReplaceModels(void)
|
|||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "weapon_grenade")) {
|
||||
if (strcmp(cg_RQ3_grenade.string, "grenade")) {
|
||||
Com_sprintf(RQ3_grenade_model, MAX_MODEL_LEN, "models/weapons2/%s/grenade.md3", cg_RQ3_grenade.string);
|
||||
Com_sprintf(RQ3_grenade_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_grenade.string);
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_grenade", str, sizeof(str));
|
||||
if (strcmp(str, "grenade")) {
|
||||
Com_sprintf(RQ3_grenade_model, MAX_MODEL_LEN, "models/weapons2/%s/grenade.md3", str);
|
||||
Com_sprintf(RQ3_grenade_icon, MAX_MODEL_LEN, "icons/iconw_%s", str);
|
||||
if (JB_FileExists(RQ3_grenade_model) && (strlen(RQ3_grenade_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_grenade_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_grenade_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading grenade replacement model %s\n", cg_RQ3_grenade.string);
|
||||
CG_Printf("^1Error loading grenade replacement model %s\n", str);
|
||||
}
|
||||
if (strcmp(cg_RQ3_grenade_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_grenade_icon, MAX_MODEL_LEN, "icons/iconw_%s", cg_RQ3_grenade_skin.string);
|
||||
|
@ -2492,149 +2558,213 @@ void CG_ReplaceModels(void)
|
|||
CG_Printf("^1Error loading grenade replacement icon %s\n", cg_RQ3_grenade_skin.string);
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_kevlar") && strcmp(cg_RQ3_kevlar.string, "kevlar")) {
|
||||
Com_sprintf(RQ3_kevlar_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_kevlar.string);
|
||||
Com_sprintf(RQ3_kevlar_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_kevlar.string);
|
||||
if (JB_FileExists(RQ3_kevlar_model) && (strlen(RQ3_kevlar_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_kevlar_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_kevlar_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading kevlar replacement model %s\n", cg_RQ3_kevlar.string);
|
||||
if (strcmp(cg_RQ3_kevlar_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_kevlar_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_kevlar_skin.string);
|
||||
if (JB_FileExists(RQ3_kevlar_icon))
|
||||
if (!strcmp(item->classname, "item_kevlar")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_kevlar", str, sizeof(str));
|
||||
if (strcmp(str, "kevlar")) {
|
||||
Com_sprintf(RQ3_kevlar_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_kevlar_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_kevlar_model) && (strlen(RQ3_kevlar_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_kevlar_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_kevlar_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading kevlar replacement icon %s\n", cg_RQ3_kevlar_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading kevlar replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_kevlar_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_kevlar_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_kevlar_skin.string);
|
||||
if (JB_FileExists(RQ3_kevlar_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_kevlar_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading kevlar replacement icon %s\n", cg_RQ3_kevlar_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_silencer") && strcmp(cg_RQ3_silencer.string, "silencer")) {
|
||||
Com_sprintf(RQ3_silencer_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_silencer.string);
|
||||
Com_sprintf(RQ3_silencer_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_silencer.string);
|
||||
if (JB_FileExists(RQ3_silencer_model) && (strlen(RQ3_silencer_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_silencer_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_silencer_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading silencer replacement model %s\n", cg_RQ3_silencer.string);
|
||||
if (strcmp(cg_RQ3_silencer_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_silencer_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_silencer_skin.string);
|
||||
if (JB_FileExists(RQ3_silencer_icon))
|
||||
if (!strcmp(item->classname, "item_silencer")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_silencer", str, sizeof(str));
|
||||
if (strcmp(str, "silencer")) {
|
||||
Com_sprintf(RQ3_silencer_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_silencer_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_silencer_model) && (strlen(RQ3_silencer_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_silencer_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_silencer_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading silencer replacement icon %s\n", cg_RQ3_silencer_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading silencer replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_silencer_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_silencer_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_silencer_skin.string);
|
||||
if (JB_FileExists(RQ3_silencer_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_silencer_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading silencer replacement icon %s\n", cg_RQ3_silencer_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_laser") && strcmp(cg_RQ3_laser.string, "laser")) {
|
||||
Com_sprintf(RQ3_laser_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_laser.string);
|
||||
Com_sprintf(RQ3_laser_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_laser.string);
|
||||
if (JB_FileExists(RQ3_laser_model) && (strlen(RQ3_laser_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_laser_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_laser_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading laser replacement model %s\n", cg_RQ3_laser.string);
|
||||
if (strcmp(cg_RQ3_laser_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_laser_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_laser_skin.string);
|
||||
if (JB_FileExists(RQ3_laser_icon))
|
||||
if (!strcmp(item->classname, "item_laser")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_laser", str, sizeof(str));
|
||||
if (strcmp(str, "laser")) {
|
||||
Com_sprintf(RQ3_laser_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_laser_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_laser_model) && (strlen(RQ3_laser_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_laser_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_laser_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading laser replacement icon %s\n", cg_RQ3_laser_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading laser replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_laser_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_laser_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_laser_skin.string);
|
||||
if (JB_FileExists(RQ3_laser_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_laser_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading laser replacement icon %s\n", cg_RQ3_laser_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_bandolier") && strcmp(cg_RQ3_bandolier.string, "bandolier")) {
|
||||
Com_sprintf(RQ3_bandolier_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_bandolier.string);
|
||||
Com_sprintf(RQ3_bandolier_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_bandolier.string);
|
||||
if (JB_FileExists(RQ3_bandolier_model) && (strlen(RQ3_bandolier_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_bandolier_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_bandolier_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading bandolier replacement model %s\n", cg_RQ3_bandolier.string);
|
||||
if (strcmp(cg_RQ3_bandolier_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_bandolier_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_bandolier_skin.string);
|
||||
if (JB_FileExists(RQ3_bandolier_icon))
|
||||
if (!strcmp(item->classname, "item_bandolier")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_bandolier", str, sizeof(str));
|
||||
if (strcmp(str, "bandolier")) {
|
||||
Com_sprintf(RQ3_bandolier_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_bandolier_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_bandolier_model) && (strlen(RQ3_bandolier_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_bandolier_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_bandolier_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading bandolier replacement icon %s\n", cg_RQ3_bandolier_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading bandolier replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_bandolier_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_bandolier_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_bandolier_skin.string);
|
||||
if (JB_FileExists(RQ3_bandolier_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_bandolier_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading bandolier replacement icon %s\n", cg_RQ3_bandolier_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_slippers") && strcmp(cg_RQ3_slippers.string, "slippers")) {
|
||||
Com_sprintf(RQ3_slippers_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_slippers.string);
|
||||
Com_sprintf(RQ3_slippers_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_slippers.string);
|
||||
if (JB_FileExists(RQ3_slippers_model) && (strlen(RQ3_slippers_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_slippers_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_slippers_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading slippers replacement model %s\n", cg_RQ3_slippers.string);
|
||||
if (strcmp(cg_RQ3_slippers_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_slippers_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_slippers_skin.string);
|
||||
if (JB_FileExists(RQ3_slippers_icon))
|
||||
if (!strcmp(item->classname, "item_slippers")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_slippers", str, sizeof(str));
|
||||
if (strcmp(str, "slippers")) {
|
||||
Com_sprintf(RQ3_slippers_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_slippers_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_slippers_model) && (strlen(RQ3_slippers_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_slippers_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_slippers_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading slippers replacement icon %s\n", cg_RQ3_slippers_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading slippers replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_slippers_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_slippers_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_slippers_skin.string);
|
||||
if (JB_FileExists(RQ3_slippers_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_slippers_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading slippers replacement icon %s\n", cg_RQ3_slippers_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "item_helmet") && strcmp(cg_RQ3_helmet.string, "helmet")) {
|
||||
Com_sprintf(RQ3_helmet_model, MAX_MODEL_LEN, "models/items/%s.md3", cg_RQ3_helmet.string);
|
||||
Com_sprintf(RQ3_helmet_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_helmet.string);
|
||||
if (JB_FileExists(RQ3_helmet_model) && (strlen(RQ3_helmet_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_helmet_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_helmet_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading helmet replacement model %s\n", cg_RQ3_helmet.string);
|
||||
if (strcmp(cg_RQ3_helmet_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_helmet_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_helmet_skin.string);
|
||||
if (JB_FileExists(RQ3_helmet_icon))
|
||||
if (!strcmp(item->classname, "item_helmet")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_helmet", str, sizeof(str));
|
||||
if (strcmp(str, "helmet")) {
|
||||
Com_sprintf(RQ3_helmet_model, MAX_MODEL_LEN, "models/items/%s.md3", str);
|
||||
Com_sprintf(RQ3_helmet_icon, MAX_MODEL_LEN, "icons/iconi_%s", str);
|
||||
if (JB_FileExists(RQ3_helmet_model) && (strlen(RQ3_helmet_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_helmet_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_helmet_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading helmet replacement icon %s\n", cg_RQ3_helmet_skin.string);
|
||||
} else
|
||||
CG_Printf("^1Error loading helmet replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_helmet_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_helmet_icon, MAX_MODEL_LEN, "icons/iconi_%s", cg_RQ3_helmet_skin.string);
|
||||
if (JB_FileExists(RQ3_helmet_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_helmet_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading helmet replacement icon %s\n", cg_RQ3_helmet_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_mk23") && strcmp(cg_RQ3_ammo_mk23.string, "mk23")) {
|
||||
Com_sprintf(RQ3_ammo_mk23_model, MAX_MODEL_LEN, "models/ammo/%s.md3", cg_RQ3_ammo_mk23.string);
|
||||
Com_sprintf(RQ3_ammo_mk23_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_mk23.string);
|
||||
if (JB_FileExists(RQ3_ammo_mk23_model) && (strlen(RQ3_ammo_mk23_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_mk23_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mk23_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading mk23 ammo replacement model %s\n", cg_RQ3_ammo_mk23.string);
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_shells") && strcmp(cg_RQ3_ammo_shells.string, "shells")) {
|
||||
Com_sprintf(RQ3_ammo_shells_model, MAX_MODEL_LEN, "models/ammo/%s.md3", cg_RQ3_ammo_shells.string);
|
||||
Com_sprintf(RQ3_ammo_shells_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_shells.string);
|
||||
if (JB_FileExists(RQ3_ammo_shells_model) && (strlen(RQ3_ammo_shells_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_shells_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_shells_icon;
|
||||
} else {
|
||||
CG_Printf("^1Error loading shells ammo replacement model %s\n", cg_RQ3_ammo_shells.string);
|
||||
if (!strcmp(item->classname, "ammo_mk23")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ammo_mk23", str, sizeof(str));
|
||||
if (strcmp(str, "mk23")) {
|
||||
Com_sprintf(RQ3_ammo_mk23_model, MAX_MODEL_LEN, "models/ammo/%s.md3", str);
|
||||
Com_sprintf(RQ3_ammo_mk23_icon, MAX_MODEL_LEN, "icons/icona_%s", str);
|
||||
if (JB_FileExists(RQ3_ammo_mk23_model) && (strlen(RQ3_ammo_mk23_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_mk23_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mk23_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading mk23 ammo replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_ammo_mk23_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ammo_mk23_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_mk23_skin.string);
|
||||
if (JB_FileExists(RQ3_ammo_mk23_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mk23_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading mk23 ammo replacement icon %s\n", cg_RQ3_ammo_mk23_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_ssg3000") && strcmp(cg_RQ3_ammo_ssg3000.string, "ssg3000")) {
|
||||
Com_sprintf(RQ3_ammo_ssg3000_model, MAX_MODEL_LEN, "models/ammo/%s.md3", cg_RQ3_ammo_ssg3000.string);
|
||||
Com_sprintf(RQ3_ammo_ssg3000_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_ssg3000.string);
|
||||
if (JB_FileExists(RQ3_ammo_ssg3000_model) && (strlen(RQ3_ammo_ssg3000_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_ssg3000_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_ssg3000_icon;
|
||||
} else {
|
||||
CG_Printf("^1Error loading ssg3000 ammo replacement model %s\n", cg_RQ3_ammo_ssg3000.string);
|
||||
if (!strcmp(item->classname, "ammo_shells")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ammo_shells", str, sizeof(str));
|
||||
if (strcmp(str, "shells")) {
|
||||
Com_sprintf(RQ3_ammo_shells_model, MAX_MODEL_LEN, "models/ammo/%s.md3", str);
|
||||
Com_sprintf(RQ3_ammo_shells_icon, MAX_MODEL_LEN, "icons/icona_%s", str);
|
||||
if (JB_FileExists(RQ3_ammo_shells_model) && (strlen(RQ3_ammo_shells_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_shells_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_shells_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading shells ammo replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_ammo_shells_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ammo_shells_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_shells_skin.string);
|
||||
if (JB_FileExists(RQ3_ammo_shells_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_shells_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading shells ammo replacement icon %s\n", cg_RQ3_ammo_shells_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_mp5") && strcmp(cg_RQ3_ammo_mp5.string, "mp5")) {
|
||||
Com_sprintf(RQ3_ammo_mp5_model, MAX_MODEL_LEN, "models/ammo/%s.md3", cg_RQ3_ammo_mp5.string);
|
||||
Com_sprintf(RQ3_ammo_mp5_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_mp5.string);
|
||||
if (JB_FileExists(RQ3_ammo_mp5_model) && (strlen(RQ3_ammo_mp5_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_mp5_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mp5_icon;
|
||||
} else {
|
||||
CG_Printf("^1Error loading mp5 ammo replacement model %s\n", cg_RQ3_ammo_mp5.string);
|
||||
if (!strcmp(item->classname, "ammo_ssg3000")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ammo_ssg3000", str, sizeof(str));
|
||||
if (strcmp(str, "ssg3000")) {
|
||||
Com_sprintf(RQ3_ammo_ssg3000_model, MAX_MODEL_LEN, "models/ammo/%s.md3", str);
|
||||
Com_sprintf(RQ3_ammo_ssg3000_icon, MAX_MODEL_LEN, "icons/icona_%s", str);
|
||||
if (JB_FileExists(RQ3_ammo_ssg3000_model) && (strlen(RQ3_ammo_ssg3000_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_ssg3000_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_ssg3000_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading ssg3000 ammo replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_ammo_ssg3000_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ammo_ssg3000_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_ssg3000_skin.string);
|
||||
if (JB_FileExists(RQ3_ammo_ssg3000_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_ssg3000_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading ssg3000 ammo replacement icon %s\n", cg_RQ3_ammo_ssg3000_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_m4") && strcmp(cg_RQ3_ammo_m4.string, "m4")) {
|
||||
Com_sprintf(RQ3_ammo_m4_model, MAX_MODEL_LEN, "models/ammo/%s.md3", cg_RQ3_ammo_m4.string);
|
||||
Com_sprintf(RQ3_ammo_m4_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_m4.string);
|
||||
if (JB_FileExists(RQ3_ammo_m4_model) && (strlen(RQ3_ammo_m4_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_m4_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_m4_icon;
|
||||
} else {
|
||||
CG_Printf("^1Error loading m4 ammo replacement model %s\n", cg_RQ3_ammo_m4.string);
|
||||
if (!strcmp(item->classname, "ammo_mp5")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ammo_mp5", str, sizeof(str));
|
||||
if (strcmp(str, "mp5")) {
|
||||
Com_sprintf(RQ3_ammo_mp5_model, MAX_MODEL_LEN, "models/ammo/%s.md3", str);
|
||||
Com_sprintf(RQ3_ammo_mp5_icon, MAX_MODEL_LEN, "icons/icona_%s", str);
|
||||
if (JB_FileExists(RQ3_ammo_mp5_model) && (strlen(RQ3_ammo_mp5_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_mp5_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mp5_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading mp5 ammo replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_ammo_mp5_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ammo_mp5_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_mp5_skin.string);
|
||||
if (JB_FileExists(RQ3_ammo_mp5_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_mp5_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading mp5 ammo replacement icon %s\n", cg_RQ3_ammo_mp5_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!strcmp(item->classname, "ammo_m4")) {
|
||||
trap_Cvar_VariableStringBuffer("cg_RQ3_ammo_m4", str, sizeof(str));
|
||||
if (strcmp(str, "m4")) {
|
||||
Com_sprintf(RQ3_ammo_m4_model, MAX_MODEL_LEN, "models/ammo/%s.md3", str);
|
||||
Com_sprintf(RQ3_ammo_m4_icon, MAX_MODEL_LEN, "icons/icona_%s", str);
|
||||
if (JB_FileExists(RQ3_ammo_m4_model) && (strlen(RQ3_ammo_m4_model) < MAX_MODEL_LEN)) {
|
||||
bg_itemlist[item - bg_itemlist].world_model[0] = (char *)&RQ3_ammo_m4_model;
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_m4_icon;
|
||||
} else
|
||||
CG_Printf("^1Error loading m4 ammo replacement model %s\n", str);
|
||||
if (strcmp(cg_RQ3_ammo_m4_skin.string, "default")) {
|
||||
Com_sprintf(RQ3_ammo_m4_icon, MAX_MODEL_LEN, "icons/icona_%s", cg_RQ3_ammo_m4_skin.string);
|
||||
if (JB_FileExists(RQ3_ammo_m4_icon))
|
||||
bg_itemlist[item - bg_itemlist].icon = (char *)&RQ3_ammo_m4_icon;
|
||||
else
|
||||
CG_Printf("^1Error loading m4 ammo replacement icon %s\n", cg_RQ3_ammo_m4_skin.string);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.107 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.106 2003/03/09 21:30:38 jbravo
|
||||
// Adding unlagged. Still needs work.
|
||||
//
|
||||
|
@ -625,12 +628,13 @@ void CG_RegisterWeapon(int weaponNum)
|
|||
int i;
|
||||
|
||||
qboolean weapAnimLoad = qtrue;
|
||||
weaponInfo = &cg_weapons[weaponNum];
|
||||
|
||||
if (weaponNum == 0) {
|
||||
if (weaponNum == 0 || weaponNum >= MAX_WEAPONS) {
|
||||
return;
|
||||
}
|
||||
|
||||
weaponInfo = &cg_weapons[weaponNum];
|
||||
|
||||
if (weaponInfo->registered) {
|
||||
return;
|
||||
}
|
||||
|
@ -729,10 +733,18 @@ void CG_RegisterWeapon(int weaponNum)
|
|||
weaponInfo->customSkin = trap_R_RegisterSkin (va("models/weapons2/%s/%s.skin",
|
||||
cg_RQ3_mk23.string, cg_RQ3_mk23_skin.string));
|
||||
if (!weaponInfo->customSkin) {
|
||||
Com_Printf("Weapon skin load failure: %s\n", va("models/weapons2/%s/%s.skin",
|
||||
Com_Printf("^1Weapon skin load failure: %s\n", va("models/weapons2/%s/%s.skin",
|
||||
cg_RQ3_mk23.string, cg_RQ3_mk23_skin.string));
|
||||
}
|
||||
}
|
||||
if (strcmp(cg_RQ3_ammo_mk23_skin.string, "default")) {
|
||||
weaponInfo->ammocustomSkin = trap_R_RegisterSkin (va("models/ammo/%s.skin",
|
||||
cg_RQ3_ammo_mk23_skin.string));
|
||||
if (!weaponInfo->ammocustomSkin) {
|
||||
Com_Printf("^1Weapon skin load failure: %s\n", va("models/ammo/%s.skin",
|
||||
cg_RQ3_ammo_mk23_skin.string));
|
||||
}
|
||||
}
|
||||
weaponInfo->ejectBrassFunc = CG_MachineGunEjectBrass;
|
||||
cgs.media.bulletExplosionShader = trap_R_RegisterShader("bulletExplosion");
|
||||
|
||||
|
@ -2258,7 +2270,7 @@ void CG_FireWeapon(centity_t * cent, int weapModification)
|
|||
}
|
||||
}
|
||||
// JBravo: unlagged
|
||||
CG_PredictWeaponEffects(cent);
|
||||
//CG_PredictWeaponEffects(cent);
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.15 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.14 2002/08/20 20:07:21 jbravo
|
||||
// Fixed the bot_minplayer system.
|
||||
//
|
||||
|
@ -644,7 +647,7 @@ static void G_AddBot(const char *name, float skill, const char *team, int delay,
|
|||
model = Info_ValueForKey(botinfo, "model");
|
||||
if (!*model) {
|
||||
// Elder: changed to our default
|
||||
model = "grunt/resdog";
|
||||
model = "reactionmale/default";
|
||||
}
|
||||
|
||||
Info_SetValueForKey(userinfo, "model", model);
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.128 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.127 2003/03/22 20:29:26 jbravo
|
||||
// wrapping linkent and unlinkent calls
|
||||
//
|
||||
|
@ -1110,14 +1113,14 @@ void ClientUserinfoChanged(int clientNum)
|
|||
if (skin2) {
|
||||
*skin2++ = '\0';
|
||||
} else {
|
||||
skin2 = "chowda";
|
||||
skin2 = "default";
|
||||
}
|
||||
if (RQ3_Validatemodel(model2) != -1) {
|
||||
Com_sprintf(model, sizeof(model), "%s/%s", model2, skin2);
|
||||
Com_sprintf(headModel, sizeof(headModel), "%s/%s", model2, skin2);
|
||||
} else {
|
||||
Com_sprintf(model, sizeof(model), "grunt/chowda");
|
||||
Com_sprintf(headModel, sizeof(headModel), "grunt/chowda");
|
||||
Com_sprintf(model, sizeof(model), "reactionmale/default");
|
||||
Com_sprintf(headModel, sizeof(headModel), "reactionmale/default");
|
||||
}
|
||||
} else {
|
||||
Q_strncpyz(model2, g_RQ3_team2model.string, sizeof(model));
|
||||
|
@ -1125,14 +1128,14 @@ void ClientUserinfoChanged(int clientNum)
|
|||
if (skin2) {
|
||||
*skin2++ = '\0';
|
||||
} else {
|
||||
skin2 = "cyrus";
|
||||
skin2 = "robber";
|
||||
}
|
||||
if (RQ3_Validatemodel(model2) != -1) {
|
||||
Com_sprintf(model, sizeof(model), "%s/%s", model2, skin2);
|
||||
Com_sprintf(headModel, sizeof(headModel), "%s/%s", model2, skin2);
|
||||
} else {
|
||||
Com_sprintf(model, sizeof(model), "grunt/cyrus");
|
||||
Com_sprintf(headModel, sizeof(headModel), "grunt/cyrus");
|
||||
Com_sprintf(model, sizeof(model), "reactionmale/robber");
|
||||
Com_sprintf(headModel, sizeof(headModel), "reactionmale/robber");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
@ -1150,8 +1153,8 @@ void ClientUserinfoChanged(int clientNum)
|
|||
trap_SendServerCommand(ent - g_entities,
|
||||
va("print \"^1Illegal player model (%s). Forcing change on server.\n\"",
|
||||
model2));
|
||||
Q_strncpyz(model, "grunt/resdog", sizeof("grunt/resdog"));
|
||||
Q_strncpyz(headModel, "grunt/resdog", sizeof("grunt/resdog"));
|
||||
Q_strncpyz(model, "reactionmale/default", sizeof("reactionmale/default"));
|
||||
Q_strncpyz(headModel, "reactionmale/default", sizeof("reactionmale/default"));
|
||||
client->radioGender = 0; // Male
|
||||
} else if (gender != GENDER_NEUTER)
|
||||
client->radioGender = gender;
|
||||
|
@ -1396,11 +1399,11 @@ char *ClientConnect(int clientNum, qboolean firstTime, qboolean isBot)
|
|||
// JBravo: moved from ClientBegin
|
||||
client->pers.enterTime = level.time;
|
||||
// JBravo: unlagged
|
||||
if (g_delagHitscan.integer) {
|
||||
/* if (g_delagHitscan.integer) {
|
||||
trap_SendServerCommand(clientNum, "print \"^3This server is Unlagged: full lag compensation is ^1ON!\n\"");
|
||||
} else {
|
||||
trap_SendServerCommand(clientNum, "print \"^3This server is Unlagged: full lag compensation is ^1OFF!\n\"");
|
||||
}
|
||||
} */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.180 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.179 2003/03/10 07:07:58 jbravo
|
||||
// Small unlagged fixes and voting delay added.
|
||||
//
|
||||
|
@ -1040,6 +1043,8 @@ void SetTeam(gentity_t * ent, char *s)
|
|||
team = TEAM_RED;
|
||||
} else if (!Q_stricmp(s, "blue") || !Q_stricmp(s, "b") || !Q_stricmp(s, "2")) {
|
||||
team = TEAM_BLUE;
|
||||
} else if (!Q_stricmp(s, "auto")) {
|
||||
team = PickTeam(clientNum);
|
||||
} else {
|
||||
// pick the team with the least number of players
|
||||
trap_SendServerCommand(ent->client->ps.clientNum,
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.135 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.134 2003/03/22 20:29:26 jbravo
|
||||
// wrapping linkent and unlinkent calls
|
||||
//
|
||||
|
@ -1184,7 +1187,7 @@ void player_die(gentity_t * self, gentity_t * inflictor, gentity_t * attacker, i
|
|||
return;
|
||||
}
|
||||
// JBravo: unlagged
|
||||
G_UnTimeShiftClient(self);
|
||||
// G_UnTimeShiftClient(self);
|
||||
|
||||
// JBravo: lets not bother with those CTF functions in Teamplay
|
||||
if (g_gametype.integer == GT_CTF) {
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.139 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.138 2003/03/22 20:29:26 jbravo
|
||||
// wrapping linkent and unlinkent calls
|
||||
//
|
||||
|
@ -399,6 +402,7 @@
|
|||
|
||||
int trap_RealTime(qtime_t * qtime);
|
||||
gentity_t *getEntByName(char *name);
|
||||
void AddIP(char *str);
|
||||
level_locals_t level;
|
||||
|
||||
typedef struct {
|
||||
|
@ -648,8 +652,8 @@ static cvarTable_t gameCvarTable[] = {
|
|||
{&g_RQ3_sniperup, "g_RQ3_sniperup", "0", CVAR_ARCHIVE, 0, qtrue},
|
||||
{&g_RQ3_team1name, "g_RQ3_team1name", "Team 1", CVAR_SYSTEMINFO | CVAR_SERVERINFO, 0, qfalse},
|
||||
{&g_RQ3_team2name, "g_RQ3_team2name", "Team 2", CVAR_SYSTEMINFO | CVAR_SERVERINFO, 0, qfalse},
|
||||
{&g_RQ3_team1model, "g_RQ3_team1model", "grunt/robber", CVAR_SYSTEMINFO, 0, qfalse},
|
||||
{&g_RQ3_team2model, "g_RQ3_team2model", "grunt/police", CVAR_SYSTEMINFO, 0, qfalse},
|
||||
{&g_RQ3_team1model, "g_RQ3_team1model", "reactionmale/default", CVAR_SYSTEMINFO, 0, qfalse},
|
||||
{&g_RQ3_team2model, "g_RQ3_team2model", "reactionmale/robber", CVAR_SYSTEMINFO, 0, qfalse},
|
||||
{&g_RQ3_tpcountdown, "g_RQ3_tpcountdown", "0", CVAR_ARCHIVE, 0, qfalse},
|
||||
{&g_RQ3_showOwnKills, "g_RQ3_showOwnKills", "0", CVAR_ARCHIVE, 0, qfalse},
|
||||
{&g_RQ3_gib, "g_RQ3_gib", "1", CVAR_ARCHIVE, 0, qtrue},
|
||||
|
@ -2675,7 +2679,7 @@ void G_RunFrame(int levelTime)
|
|||
G_RunThink(ent);
|
||||
}
|
||||
// JBravo: unlagged
|
||||
G_TimeShiftAllClients(level.previousTime, NULL);
|
||||
// G_TimeShiftAllClients(level.previousTime, NULL);
|
||||
ent = &g_entities[0];
|
||||
for (i=0 ; i<level.num_entities ; i++, ent++) {
|
||||
if (!ent->inuse) {
|
||||
|
@ -2688,7 +2692,7 @@ void G_RunFrame(int levelTime)
|
|||
G_RunMissile(ent);
|
||||
}
|
||||
}
|
||||
G_UnTimeShiftAllClients(NULL);
|
||||
// G_UnTimeShiftAllClients(NULL);
|
||||
|
||||
end = trap_Milliseconds();
|
||||
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.17 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.16 2002/09/29 16:06:45 jbravo
|
||||
// Work done at the HPWorld expo
|
||||
//
|
||||
|
@ -935,7 +938,6 @@ gentity_t *SelectRandomTeamSpawnPoint(int teamstate, team_t team)
|
|||
gentity_t *spots[MAX_TEAM_SPAWN_POINTS];
|
||||
char *classname;
|
||||
|
||||
// NiceAss: no longer use redplayer (people spawned in eachother)
|
||||
if (teamstate == TEAM_BEGIN) {
|
||||
if (team == TEAM_RED)
|
||||
classname = "team_CTF_redplayer";
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.150 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.149 2003/03/22 20:19:20 jbravo
|
||||
// Item replacement fixes, tmp ban after votekicks and ignore now works on
|
||||
// players with colors.
|
||||
|
@ -1439,6 +1442,10 @@ void RQ3_Respawn_CTB_players(int team)
|
|||
ent->client->idletime = 0;
|
||||
ResetKills(ent);
|
||||
ent->client->last_damaged_players[0] = '\0';
|
||||
if (level.lights_camera_action)
|
||||
ent->client->pers.teamState.state = TEAM_BEGIN;
|
||||
else
|
||||
ent->client->pers.teamState.state = TEAM_ACTIVE;
|
||||
ClientSpawn(ent);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.88 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.87 2003/03/22 20:29:26 jbravo
|
||||
// wrapping linkent and unlinkent calls
|
||||
//
|
||||
|
@ -525,9 +528,9 @@ void Bullet_Fire(gentity_t * ent, float spread, int damage, int MOD)
|
|||
passent = ent->s.number;
|
||||
for (i = 0; i < 10; i++) {
|
||||
// JBravo: unlagged
|
||||
G_DoTimeShiftFor(ent);
|
||||
// G_DoTimeShiftFor(ent);
|
||||
trap_Trace(&tr, muzzle, NULL, NULL, end, passent, MASK_SHOT);
|
||||
G_UndoTimeShiftFor(ent);
|
||||
// G_UndoTimeShiftFor(ent);
|
||||
|
||||
//Makro - saving the material flag to avoid useless calls to the GetMaterialFromFlag function
|
||||
Material = GetMaterialFromFlag(tr.surfaceFlags);
|
||||
|
@ -741,7 +744,7 @@ void ShotgunPattern(vec3_t origin, vec3_t origin2, int seed, gentity_t * ent, in
|
|||
hc_multipler = 5;
|
||||
}
|
||||
|
||||
G_DoTimeShiftFor(ent);
|
||||
// G_DoTimeShiftFor(ent);
|
||||
// generate the "random" spread pattern
|
||||
for (i = 0; i < count; i++) {
|
||||
if (shotType == WP_M3) {
|
||||
|
@ -773,7 +776,7 @@ void ShotgunPattern(vec3_t origin, vec3_t origin2, int seed, gentity_t * ent, in
|
|||
}
|
||||
}
|
||||
}
|
||||
G_UndoTimeShiftFor(ent);
|
||||
// G_UndoTimeShiftFor(ent);
|
||||
}
|
||||
|
||||
void weapon_supershotgun_fire(gentity_t * ent)
|
||||
|
@ -823,7 +826,7 @@ void weapon_railgun_fire(gentity_t * ent)
|
|||
VectorMA(muzzle, 8192, forward, end);
|
||||
|
||||
// trace only against the solids, so the railgun will go through people
|
||||
G_DoTimeShiftFor(ent);
|
||||
// G_DoTimeShiftFor(ent);
|
||||
unlinked = 0;
|
||||
hits = 0;
|
||||
passent = ent->s.number;
|
||||
|
@ -847,7 +850,7 @@ void weapon_railgun_fire(gentity_t * ent)
|
|||
unlinkedEntities[unlinked] = traceEnt;
|
||||
unlinked++;
|
||||
} while (unlinked < MAX_RAIL_HITS);
|
||||
G_UndoTimeShiftFor(ent);
|
||||
// G_UndoTimeShiftFor(ent);
|
||||
|
||||
// link back in any entities we unlinked
|
||||
for (i = 0; i < unlinked; i++) {
|
||||
|
@ -1282,7 +1285,7 @@ void Weapon_SSG3000_Fire(gentity_t * ent)
|
|||
damage = SNIPER_DAMAGE;
|
||||
|
||||
// JBravo: unlagged NEW
|
||||
G_DoTimeShiftFor(ent);
|
||||
// G_DoTimeShiftFor(ent);
|
||||
// trace only against the solids, so the SSG3000 will go through people
|
||||
unlinked = 0;
|
||||
hits = 0;
|
||||
|
@ -1378,7 +1381,7 @@ void Weapon_SSG3000_Fire(gentity_t * ent)
|
|||
unlinked++;
|
||||
}
|
||||
} while (unlinked < MAX_SSG3000_HITS);
|
||||
G_UndoTimeShiftFor(ent);
|
||||
// G_UndoTimeShiftFor(ent);
|
||||
|
||||
// link back in any entities we unlinked
|
||||
for (i = 0; i < unlinked; i++) {
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.64 2003/03/28 10:36:02 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.63 2003/03/02 21:12:46 jbravo
|
||||
// Version bumped to 3.0. Lets try and keep it list this.
|
||||
//
|
||||
|
@ -7339,7 +7342,7 @@ static cvarTable_t cvarTable[] = {
|
|||
{&ui_RQ3_ssgCrosshair, "ui_RQ3_ssgCrosshair", "0", 0},
|
||||
{&ui_RQ3_weapAfterJoin, "ui_RQ3_weapAfterJoin", "1", CVAR_ARCHIVE},
|
||||
//Makro - model cvar
|
||||
{&ui_RQ3_model, "model", "grunt/resdog", 0},
|
||||
{&ui_RQ3_model, "model", "reactionmale/default", 0},
|
||||
//Makro - team counts
|
||||
//Handled in cgame now
|
||||
//{ &ui_RQ3_teamCount1, "g_RQ3_teamCount1", "0", 0},
|
||||
|
|
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.7 2003/03/28 10:36:03 jbravo
|
||||
// Tweaking the replacement system a bit. Reactionmale now the default model
|
||||
//
|
||||
// Revision 1.6 2002/07/26 22:28:38 jbravo
|
||||
// Fixed the server about menu, made the UI handle illegal models and skins
|
||||
// better.
|
||||
|
@ -1007,14 +1010,14 @@ static qboolean UI_RegisterClientSkin(playerInfo_t * pi, const char *modelName,
|
|||
|
||||
if (!pi->legsSkin || !pi->torsoSkin || !pi->headSkin) {
|
||||
// JBravo: No need for errors if the skin doesnt exsist. Lets drop in a default instead.
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/lower_resdog.skin");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/lower_default.skin");
|
||||
pi->legsSkin = trap_R_RegisterSkin(filename);
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/upper_resdog.skin");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/upper_default.skin");
|
||||
pi->torsoSkin = trap_R_RegisterSkin(filename);
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/head_resdog.skin");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/head_default.skin");
|
||||
pi->headSkin = trap_R_RegisterSkin(filename);
|
||||
trap_Cvar_Set("model", "grunt/resdog");
|
||||
trap_Cvar_Set("headmodel", "grunt/resdog");
|
||||
trap_Cvar_Set("model", "reactionmale/default");
|
||||
trap_Cvar_Set("headmodel", "reactionmale/default");
|
||||
}
|
||||
|
||||
return qtrue;
|
||||
|
@ -1193,9 +1196,9 @@ qboolean UI_RegisterClientModelname(playerInfo_t * pi, const char *modelSkinName
|
|||
pi->legsModel = trap_R_RegisterModel(filename);
|
||||
if (!pi->legsModel) {
|
||||
// JBravo: no errors on bad models. Defaults in stead.
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/lower.md3");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/lower.md3");
|
||||
pi->legsModel = trap_R_RegisterModel(filename);
|
||||
trap_Cvar_Set("model", "grunt/resdog");
|
||||
trap_Cvar_Set("model", "reactionmale/default");
|
||||
//Com_Printf("Failed to load model file %s\n", filename);
|
||||
//return qfalse;
|
||||
}
|
||||
|
@ -1208,9 +1211,9 @@ qboolean UI_RegisterClientModelname(playerInfo_t * pi, const char *modelSkinName
|
|||
pi->torsoModel = trap_R_RegisterModel(filename);
|
||||
if (!pi->torsoModel) {
|
||||
// JBravo: no errors on bad models. Defaults in stead.
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/upper.md3");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/upper.md3");
|
||||
pi->torsoModel = trap_R_RegisterModel(filename);
|
||||
trap_Cvar_Set("model", "grunt/resdog");
|
||||
trap_Cvar_Set("model", "reactionmale/default");
|
||||
//Com_Printf("Failed to load model file %s\n", filename);
|
||||
//return qfalse;
|
||||
}
|
||||
|
@ -1229,9 +1232,9 @@ qboolean UI_RegisterClientModelname(playerInfo_t * pi, const char *modelSkinName
|
|||
}
|
||||
|
||||
if (!pi->headModel) {
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/head.md3");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/head.md3");
|
||||
pi->headModel = trap_R_RegisterModel(filename);
|
||||
trap_Cvar_Set("model", "grunt/resdog");
|
||||
trap_Cvar_Set("model", "reactionmale/default");
|
||||
//Com_Printf("Failed to load model file %s\n", filename);
|
||||
//return qfalse;
|
||||
}
|
||||
|
@ -1247,7 +1250,7 @@ qboolean UI_RegisterClientModelname(playerInfo_t * pi, const char *modelSkinName
|
|||
if (!UI_ParseAnimationFile(filename, pi->animations)) {
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/characters/%s/animation.cfg", modelName);
|
||||
if (!UI_ParseAnimationFile(filename, pi->animations)) {
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/grunt/animation.cfg");
|
||||
Com_sprintf(filename, sizeof(filename), "models/players/reactionmale/animation.cfg");
|
||||
if (!UI_ParseAnimationFile(filename, pi->animations)) {
|
||||
Com_Printf("Failed to load animation file %s\n", filename);
|
||||
return qfalse;
|
||||
|
|
Loading…
Reference in a new issue