mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2024-11-27 14:32:15 +00:00
Presets menu + editor
This commit is contained in:
parent
86f54c5dea
commit
f1f29a7c5a
7 changed files with 246 additions and 20 deletions
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.7 2002/08/26 00:41:52 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.6 2002/06/16 20:06:14 jbravo
|
// Revision 1.6 2002/06/16 20:06:14 jbravo
|
||||||
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
||||||
//
|
//
|
||||||
|
@ -211,6 +214,18 @@
|
||||||
//Makro - for SSG crosshair selection
|
//Makro - for SSG crosshair selection
|
||||||
#define UI_SSG_CROSSHAIR 150
|
#define UI_SSG_CROSSHAIR 150
|
||||||
|
|
||||||
|
//Makro - radio presets
|
||||||
|
#define UI_RQ3_RADIOPRESET1 151
|
||||||
|
#define UI_RQ3_RADIOPRESET2 152
|
||||||
|
#define UI_RQ3_RADIOPRESET3 153
|
||||||
|
#define UI_RQ3_RADIOPRESET4 154
|
||||||
|
#define UI_RQ3_RADIOPRESET5 155
|
||||||
|
#define UI_RQ3_RADIOPRESET6 156
|
||||||
|
#define UI_RQ3_RADIOPRESET7 157
|
||||||
|
#define UI_RQ3_RADIOPRESET8 158
|
||||||
|
#define UI_RQ3_RADIOPRESET9 159
|
||||||
|
#define UI_RQ3_RADIOPRESET10 160
|
||||||
|
|
||||||
#define UI_OWNERDRAW_BASE 200
|
#define UI_OWNERDRAW_BASE 200
|
||||||
#define UI_HANDICAP 200
|
#define UI_HANDICAP 200
|
||||||
#define UI_EFFECTS 201
|
#define UI_EFFECTS 201
|
||||||
|
|
|
@ -3,16 +3,34 @@
|
||||||
<pre>
|
<pre>
|
||||||
<h1>Build Log</h1>
|
<h1>Build Log</h1>
|
||||||
<h3>
|
<h3>
|
||||||
|
--------------------Configuration: cgame - Win32 Release--------------------
|
||||||
|
</h3>
|
||||||
|
<h3>Command Lines</h3>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<h3>Results</h3>
|
||||||
|
cgamex86.dll - 0 error(s), 0 warning(s)
|
||||||
|
<h3>
|
||||||
|
--------------------Configuration: game - Win32 Release--------------------
|
||||||
|
</h3>
|
||||||
|
<h3>Command Lines</h3>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<h3>Results</h3>
|
||||||
|
qagamex86.dll - 0 error(s), 0 warning(s)
|
||||||
|
<h3>
|
||||||
--------------------Configuration: ui - Win32 Release TA--------------------
|
--------------------Configuration: ui - Win32 Release TA--------------------
|
||||||
</h3>
|
</h3>
|
||||||
<h3>Command Lines</h3>
|
<h3>Command Lines</h3>
|
||||||
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP5FC.tmp" with contents
|
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP841.tmp" with contents
|
||||||
[
|
[
|
||||||
/nologo /G6 /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "UI_EXPORTS" /Fp"Release_TA/ta_ui.pch" /YX /Fo"Release_TA/" /Fd"Release_TA/" /FD /c
|
/nologo /G6 /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "UI_EXPORTS" /Fp"Release_TA/ta_ui.pch" /YX /Fo"Release_TA/" /Fd"Release_TA/" /FD /c
|
||||||
"C:\Games\Quake3\rq3source\reaction\ta_ui\ui_main.c"
|
"C:\Games\Quake3\rq3source\reaction\ta_ui\ui_shared.c"
|
||||||
]
|
]
|
||||||
Creating command line "cl.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP5FC.tmp"
|
Creating command line "cl.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP841.tmp"
|
||||||
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP5FD.tmp" with contents
|
Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP842.tmp" with contents
|
||||||
[
|
[
|
||||||
/nologo /base:"0x40000000" /dll /incremental:no /pdb:"Release_TA/uix86.pdb" /map:"Release_TA/uix86.map" /machine:I386 /def:".\ui.def" /out:"../Release/uix86.dll" /implib:"Release_TA/uix86.lib"
|
/nologo /base:"0x40000000" /dll /incremental:no /pdb:"Release_TA/uix86.pdb" /map:"Release_TA/uix86.map" /machine:I386 /def:".\ui.def" /out:"../Release/uix86.dll" /implib:"Release_TA/uix86.lib"
|
||||||
.\Release_TA\bg_misc.obj
|
.\Release_TA\bg_misc.obj
|
||||||
|
@ -26,10 +44,10 @@ Creating temporary file "D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP5FD.tmp" with conte
|
||||||
.\Release_TA\ui_syscalls.obj
|
.\Release_TA\ui_syscalls.obj
|
||||||
.\Release_TA\ui_util.obj
|
.\Release_TA\ui_util.obj
|
||||||
]
|
]
|
||||||
Creating command line "link.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP5FD.tmp"
|
Creating command line "link.exe @D:\DOCUME~1\Andrei\LOCALS~1\Temp\RSP842.tmp"
|
||||||
<h3>Output Window</h3>
|
<h3>Output Window</h3>
|
||||||
Compiling...
|
Compiling...
|
||||||
ui_main.c
|
ui_shared.c
|
||||||
Linking...
|
Linking...
|
||||||
Creating library Release_TA/uix86.lib and object Release_TA/uix86.exp
|
Creating library Release_TA/uix86.lib and object Release_TA/uix86.exp
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.15 2002/08/26 00:41:52 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.14 2002/07/02 09:51:29 makro
|
// Revision 1.14 2002/07/02 09:51:29 makro
|
||||||
// In-game server info code
|
// In-game server info code
|
||||||
//
|
//
|
||||||
|
@ -444,6 +447,11 @@ qboolean UI_ConsoleCommand(int realTime)
|
||||||
Com_Printf("Not playing a team-based game.\n");
|
Com_Printf("Not playing a team-based game.\n");
|
||||||
return qtrue;
|
return qtrue;
|
||||||
}
|
}
|
||||||
|
//Makro - presets menu
|
||||||
|
if (Q_stricmp(cmd, "ui_RQ3_presets") == 0) {
|
||||||
|
_UI_SetActiveMenu(UIMENU_RQ3_PRESETS);
|
||||||
|
return qtrue;
|
||||||
|
}
|
||||||
//Makro - I've always wanted a command to inc/dec a cvar :)
|
//Makro - I've always wanted a command to inc/dec a cvar :)
|
||||||
if (Q_stricmp(cmd, "inc") == 0) {
|
if (Q_stricmp(cmd, "inc") == 0) {
|
||||||
if (trap_Argc() >= 2) {
|
if (trap_Argc() >= 2) {
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.18 2002/08/26 00:41:52 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.17 2002/07/02 09:51:29 makro
|
// Revision 1.17 2002/07/02 09:51:29 makro
|
||||||
// In-game server info code
|
// In-game server info code
|
||||||
//
|
//
|
||||||
|
@ -184,6 +187,37 @@ extern vmCvar_t ui_RQ3_forceteamtalk;
|
||||||
extern vmCvar_t ui_RQ3_limchasecam;
|
extern vmCvar_t ui_RQ3_limchasecam;
|
||||||
extern vmCvar_t ui_RQ3_tgren;
|
extern vmCvar_t ui_RQ3_tgren;
|
||||||
extern vmCvar_t ui_RQ3_friendlyFire;
|
extern vmCvar_t ui_RQ3_friendlyFire;
|
||||||
|
//Makro - radio presets menu cvars
|
||||||
|
//1
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset1Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset1Script;
|
||||||
|
//2
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset2Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset2Script;
|
||||||
|
//3
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset3Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset3Script;
|
||||||
|
//4
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset4Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset4Script;
|
||||||
|
//5
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset5Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset5Script;
|
||||||
|
//6
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset6Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset6Script;
|
||||||
|
//7
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset7Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset7Script;
|
||||||
|
//8
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset8Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset8Script;
|
||||||
|
//9
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset9Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset9Script;
|
||||||
|
//10
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset10Desc;
|
||||||
|
extern vmCvar_t ui_RQ3_radioPreset10Script;
|
||||||
|
|
||||||
//Makro - specify server option
|
//Makro - specify server option
|
||||||
extern vmCvar_t ui_RQ3_joinAddress;
|
extern vmCvar_t ui_RQ3_joinAddress;
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.46 2002/08/26 00:41:52 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.45 2002/07/26 22:28:38 jbravo
|
// Revision 1.45 2002/07/26 22:28:38 jbravo
|
||||||
// Fixed the server about menu, made the UI handle illegal models and skins
|
// Fixed the server about menu, made the UI handle illegal models and skins
|
||||||
// better.
|
// better.
|
||||||
|
@ -23,6 +26,9 @@
|
||||||
// Revision 1.41 2002/07/02 09:51:29 makro
|
// Revision 1.41 2002/07/02 09:51:29 makro
|
||||||
// In-game server info code
|
// In-game server info code
|
||||||
//
|
//
|
||||||
|
// Revision 1.40 2002/06/29 04:15:15 jbravo
|
||||||
|
// CTF is now CTB. no weapons while the case is in hand other than pistol or knife
|
||||||
|
//
|
||||||
// Revision 1.39 2002/06/28 21:20:44 makro
|
// Revision 1.39 2002/06/28 21:20:44 makro
|
||||||
// More MM...
|
// More MM...
|
||||||
//
|
//
|
||||||
|
@ -238,6 +244,27 @@ static const char *sortKeys[] = {
|
||||||
};
|
};
|
||||||
static const int numSortKeys = sizeof(sortKeys) / sizeof(const char *);
|
static const int numSortKeys = sizeof(sortKeys) / sizeof(const char *);
|
||||||
|
|
||||||
|
//Makro - radio presets
|
||||||
|
typedef struct {
|
||||||
|
vmCvar_t *Text, *Script;
|
||||||
|
} radioPreset_t;
|
||||||
|
radioPreset_t radioPresets[] =
|
||||||
|
{
|
||||||
|
{&ui_RQ3_radioPreset1Desc, &ui_RQ3_radioPreset1Script},
|
||||||
|
{&ui_RQ3_radioPreset2Desc, &ui_RQ3_radioPreset2Script},
|
||||||
|
{&ui_RQ3_radioPreset3Desc, &ui_RQ3_radioPreset3Script},
|
||||||
|
{&ui_RQ3_radioPreset4Desc, &ui_RQ3_radioPreset4Script},
|
||||||
|
{&ui_RQ3_radioPreset5Desc, &ui_RQ3_radioPreset5Script},
|
||||||
|
{&ui_RQ3_radioPreset6Desc, &ui_RQ3_radioPreset6Script},
|
||||||
|
{&ui_RQ3_radioPreset7Desc, &ui_RQ3_radioPreset7Script},
|
||||||
|
{&ui_RQ3_radioPreset8Desc, &ui_RQ3_radioPreset8Script},
|
||||||
|
{&ui_RQ3_radioPreset9Desc, &ui_RQ3_radioPreset9Script},
|
||||||
|
{&ui_RQ3_radioPreset10Desc, &ui_RQ3_radioPreset10Script}
|
||||||
|
};
|
||||||
|
static const int numRadioPresets = sizeof(radioPresets) / sizeof(radioPreset_t);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static char *netnames[] = {
|
static char *netnames[] = {
|
||||||
"???",
|
"???",
|
||||||
"UDP",
|
"UDP",
|
||||||
|
@ -1360,6 +1387,17 @@ static void UI_DrawTeamName(rectDef_t * rect, float scale, vec4_t color, qboolea
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Makro - added for radio presets
|
||||||
|
static void UI_RQ3_DrawPreset(rectDef_t * rect, float scale, vec4_t color, int num, int textStyle)
|
||||||
|
{
|
||||||
|
//char *text = "(empty)";
|
||||||
|
char *text = "\0";
|
||||||
|
if (radioPresets[num-1].Text->string[0]) {
|
||||||
|
text = radioPresets[num-1].Text->string;
|
||||||
|
}
|
||||||
|
Text_Paint(rect->x, rect->y, scale, color, text, 0, 0, textStyle);
|
||||||
|
}
|
||||||
|
|
||||||
static void UI_DrawTeamMember(rectDef_t * rect, float scale, vec4_t color, qboolean blue, int num, int textStyle)
|
static void UI_DrawTeamMember(rectDef_t * rect, float scale, vec4_t color, qboolean blue, int num, int textStyle)
|
||||||
{
|
{
|
||||||
// 0 - None
|
// 0 - None
|
||||||
|
@ -2304,14 +2342,14 @@ void UI_BuildIngameServerInfoList()
|
||||||
}
|
}
|
||||||
AddIngameLine("Match mode", (matchmode != 0) ? "On" : "Off");
|
AddIngameLine("Match mode", (matchmode != 0) ? "On" : "Off");
|
||||||
if (matchmode) {
|
if (matchmode) {
|
||||||
int refID = atoi(Info_ValueForKey(info, "g_RQ3_refID"));
|
//int refID = atoi(Info_ValueForKey(info, "g_RQ3_refID"));
|
||||||
int allowRef = atoi(Info_ValueForKey(info, "g_RQ3_allowRef"));
|
int allowRef = atoi(Info_ValueForKey(info, "g_RQ3_allowRef"));
|
||||||
AddIngameLine("Allow referee", (allowRef != 0) ? "On" : "Off");
|
AddIngameLine("Allow referee", (allowRef != 0) ? "On" : "Off");
|
||||||
if (allowRef && refID != -1) {
|
//if (allowRef && refID != -1) {
|
||||||
char info2[MAX_INFO_STRING];
|
// char info2[MAX_INFO_STRING];
|
||||||
trap_GetConfigString(CS_PLAYERS + refID, info2, sizeof(info2));
|
// trap_GetConfigString(CS_PLAYERS + refID, info2, sizeof(info2));
|
||||||
AddIngameLine("Referee", Info_ValueForKey(info2, "name"));
|
// AddIngameLine("Referee", Info_ValueForKey(info2, "name"));
|
||||||
}
|
//}
|
||||||
}
|
}
|
||||||
AddIngameLine("Max clients", Info_ValueForKey(info, "sv_maxClients"));
|
AddIngameLine("Max clients", Info_ValueForKey(info, "sv_maxClients"));
|
||||||
AddIngameLine("Bot/min players", Info_ValueForKey(info, "bot_minplayers"));
|
AddIngameLine("Bot/min players", Info_ValueForKey(info, "bot_minplayers"));
|
||||||
|
@ -2686,10 +2724,23 @@ static void UI_OwnerDraw(float x, float y, float w, float h, float text_x, float
|
||||||
case UI_CROSSHAIR:
|
case UI_CROSSHAIR:
|
||||||
UI_DrawCrosshair(&rect, scale, color);
|
UI_DrawCrosshair(&rect, scale, color);
|
||||||
break;
|
break;
|
||||||
//Makro - adding SSG crosshair
|
//Makro - adding SSG crosshair
|
||||||
case UI_SSG_CROSSHAIR:
|
case UI_SSG_CROSSHAIR:
|
||||||
UI_DrawSSGCrosshair(&rect);
|
UI_DrawSSGCrosshair(&rect);
|
||||||
break;
|
break;
|
||||||
|
//Makro - radio presets
|
||||||
|
case UI_RQ3_RADIOPRESET1:
|
||||||
|
case UI_RQ3_RADIOPRESET2:
|
||||||
|
case UI_RQ3_RADIOPRESET3:
|
||||||
|
case UI_RQ3_RADIOPRESET4:
|
||||||
|
case UI_RQ3_RADIOPRESET5:
|
||||||
|
case UI_RQ3_RADIOPRESET6:
|
||||||
|
case UI_RQ3_RADIOPRESET7:
|
||||||
|
case UI_RQ3_RADIOPRESET8:
|
||||||
|
case UI_RQ3_RADIOPRESET9:
|
||||||
|
case UI_RQ3_RADIOPRESET10:
|
||||||
|
UI_RQ3_DrawPreset(&rect, scale, color, ownerDraw - UI_RQ3_RADIOPRESET1 + 1, textStyle);
|
||||||
|
break;
|
||||||
case UI_SELECTEDPLAYER:
|
case UI_SELECTEDPLAYER:
|
||||||
UI_DrawSelectedPlayer(&rect, scale, color, textStyle);
|
UI_DrawSelectedPlayer(&rect, scale, color, textStyle);
|
||||||
break;
|
break;
|
||||||
|
@ -4053,6 +4104,22 @@ static void UI_RunMenuScript(char **args)
|
||||||
//Makro - build server info list
|
//Makro - build server info list
|
||||||
} else if (Q_stricmp(name, "refreshIngameServerInfo") == 0) {
|
} else if (Q_stricmp(name, "refreshIngameServerInfo") == 0) {
|
||||||
UI_BuildIngameServerInfoList();
|
UI_BuildIngameServerInfoList();
|
||||||
|
//Makro - run a preset command
|
||||||
|
} else if (Q_stricmp(name, "runPreset") == 0) {
|
||||||
|
int index;
|
||||||
|
if (Int_Parse(args, &index)) {
|
||||||
|
if (index >=1 && index <= numRadioPresets) {
|
||||||
|
char *cmd = radioPresets[index-1].Script->string;
|
||||||
|
|
||||||
|
if (cmd[0]) {
|
||||||
|
trap_Cmd_ExecuteText(EXEC_APPEND, va("%s\n", radioPresets[index-1].Script->string));
|
||||||
|
} else {
|
||||||
|
Com_Printf("Empty slot (%i)\n", index);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
Com_Printf("Preset number out of range (%i)\n", index);
|
||||||
|
}
|
||||||
|
}
|
||||||
//Makro - change the SSG crosshair
|
//Makro - change the SSG crosshair
|
||||||
} else if (Q_stricmp(name, "nextSSGCrosshair") == 0) {
|
} else if (Q_stricmp(name, "nextSSGCrosshair") == 0) {
|
||||||
int current, offset;
|
int current, offset;
|
||||||
|
@ -6422,6 +6489,7 @@ void _UI_SetActiveMenu(uiMenuCommand_t menu)
|
||||||
Menus_CloseAll();
|
Menus_CloseAll();
|
||||||
Menus_ActivateByName("ingame");
|
Menus_ActivateByName("ingame");
|
||||||
return;
|
return;
|
||||||
|
//Makro - RQ3 menus
|
||||||
case UIMENU_RQ3_WEAPON:
|
case UIMENU_RQ3_WEAPON:
|
||||||
trap_Cvar_Set("cl_paused", "1");
|
trap_Cvar_Set("cl_paused", "1");
|
||||||
trap_Key_SetCatcher(KEYCATCH_UI);
|
trap_Key_SetCatcher(KEYCATCH_UI);
|
||||||
|
@ -6447,6 +6515,13 @@ void _UI_SetActiveMenu(uiMenuCommand_t menu)
|
||||||
Menus_CloseAll();
|
Menus_CloseAll();
|
||||||
Menus_ActivateByName("ingame_tkok");
|
Menus_ActivateByName("ingame_tkok");
|
||||||
return;
|
return;
|
||||||
|
case UIMENU_RQ3_PRESETS:
|
||||||
|
trap_Cvar_Set("cl_paused", "1");
|
||||||
|
trap_Key_SetCatcher(KEYCATCH_UI);
|
||||||
|
UI_BuildPlayerList();
|
||||||
|
Menus_CloseAll();
|
||||||
|
Menus_ActivateByName("ingame_presets");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6828,6 +6903,38 @@ vmCvar_t ui_RQ3_tgren;
|
||||||
vmCvar_t ui_RQ3_friendlyFire;
|
vmCvar_t ui_RQ3_friendlyFire;
|
||||||
//Makro - in-game server info
|
//Makro - in-game server info
|
||||||
vmCvar_t ui_RQ3_ingameDetails;
|
vmCvar_t ui_RQ3_ingameDetails;
|
||||||
|
//Makro - radio presets menu cvars
|
||||||
|
//1
|
||||||
|
vmCvar_t ui_RQ3_radioPreset1Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset1Script;
|
||||||
|
//2
|
||||||
|
vmCvar_t ui_RQ3_radioPreset2Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset2Script;
|
||||||
|
//3
|
||||||
|
vmCvar_t ui_RQ3_radioPreset3Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset3Script;
|
||||||
|
//4
|
||||||
|
vmCvar_t ui_RQ3_radioPreset4Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset4Script;
|
||||||
|
//5
|
||||||
|
vmCvar_t ui_RQ3_radioPreset5Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset5Script;
|
||||||
|
//6
|
||||||
|
vmCvar_t ui_RQ3_radioPreset6Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset6Script;
|
||||||
|
//7
|
||||||
|
vmCvar_t ui_RQ3_radioPreset7Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset7Script;
|
||||||
|
//8
|
||||||
|
vmCvar_t ui_RQ3_radioPreset8Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset8Script;
|
||||||
|
//9
|
||||||
|
vmCvar_t ui_RQ3_radioPreset9Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset9Script;
|
||||||
|
//10
|
||||||
|
vmCvar_t ui_RQ3_radioPreset10Desc;
|
||||||
|
vmCvar_t ui_RQ3_radioPreset10Script;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// bk001129 - made static to avoid aliasing
|
// bk001129 - made static to avoid aliasing
|
||||||
|
@ -6977,7 +7084,38 @@ static cvarTable_t cvarTable[] = {
|
||||||
{&ui_RQ3_tgren, "ui_RQ3_tgren", "0", 0},
|
{&ui_RQ3_tgren, "ui_RQ3_tgren", "0", 0},
|
||||||
{&ui_RQ3_friendlyFire, "ui_RQ3_friendlyFire", "0", 0},
|
{&ui_RQ3_friendlyFire, "ui_RQ3_friendlyFire", "0", 0},
|
||||||
//Makro - in-game server info
|
//Makro - in-game server info
|
||||||
{&ui_RQ3_ingameDetails, "ui_RQ3_ingameDetails", "0", CVAR_ARCHIVE}
|
{&ui_RQ3_ingameDetails, "ui_RQ3_ingameDetails", "0", CVAR_ARCHIVE},
|
||||||
|
//Makro - radio presets menu cvars
|
||||||
|
//1
|
||||||
|
{&ui_RQ3_radioPreset1Desc, "ui_RQ3_radioPreset1Desc", "Enemy spotted", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset1Script, "ui_RQ3_radioPreset1Script", "say_team Enemy spotted; radio enemys", CVAR_ARCHIVE},
|
||||||
|
//2
|
||||||
|
{&ui_RQ3_radioPreset2Desc, "ui_RQ3_radioPreset2Desc", "Reporting in", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset2Script, "ui_RQ3_radioPreset2Script", "say_team Reporting in with $W and $H health; radio reportin", CVAR_ARCHIVE},
|
||||||
|
//3
|
||||||
|
{&ui_RQ3_radioPreset3Desc, "ui_RQ3_radioPreset3Desc", "Team, report in !", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset3Script, "ui_RQ3_radioPreset3Script", "say_team Team, report in; radio treport", CVAR_ARCHIVE},
|
||||||
|
//4
|
||||||
|
{&ui_RQ3_radioPreset4Desc, "ui_RQ3_radioPreset4Desc", "Go !", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset4Script, "ui_RQ3_radioPreset4Script", "say_team Go !; radio go", CVAR_ARCHIVE},
|
||||||
|
//5
|
||||||
|
{&ui_RQ3_radioPreset5Desc, "ui_RQ3_radioPreset5Desc", "I'm hit !", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset5Script, "ui_RQ3_radioPreset5Script", "say_team I'm hit, I've got $H left !; radio imhit", CVAR_ARCHIVE},
|
||||||
|
//6
|
||||||
|
{&ui_RQ3_radioPreset6Desc, "ui_RQ3_radioPreset6Desc", "I've got your back !", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset6Script, "ui_RQ3_radioPreset6Script", "say_team I've got your back !; radio escort2", CVAR_ARCHIVE},
|
||||||
|
//7
|
||||||
|
{&ui_RQ3_radioPreset7Desc, "ui_RQ3_radioPreset7Desc", "Teammate down", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset7Script, "ui_RQ3_radioPreset7Script", "say_team Teammate down !; radio teamdown", CVAR_ARCHIVE},
|
||||||
|
//8
|
||||||
|
{&ui_RQ3_radioPreset8Desc, "ui_RQ3_radioPreset8Desc", "Enemy down", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset8Script, "ui_RQ3_radioPreset8Script", "say_team $K eliminated; radio enemyd", CVAR_ARCHIVE},
|
||||||
|
//9
|
||||||
|
{&ui_RQ3_radioPreset9Desc, "ui_RQ3_radioPreset9Desc", "Right", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset9Script, "ui_RQ3_radioPreset9Script", "say_team Right; radio right", CVAR_ARCHIVE},
|
||||||
|
//10
|
||||||
|
{&ui_RQ3_radioPreset10Desc, "ui_RQ3_radioPreset10Desc", "", CVAR_ARCHIVE},
|
||||||
|
{&ui_RQ3_radioPreset10Script, "ui_RQ3_radioPreset10Script", "", CVAR_ARCHIVE}
|
||||||
};
|
};
|
||||||
|
|
||||||
// bk001129 - made static to avoid aliasing
|
// bk001129 - made static to avoid aliasing
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.7 2002/08/26 00:41:52 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.6 2002/06/16 20:06:15 jbravo
|
// Revision 1.6 2002/06/16 20:06:15 jbravo
|
||||||
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
||||||
//
|
//
|
||||||
|
@ -146,7 +149,10 @@ typedef enum {
|
||||||
UIMENU_RQ3_WEAPON,
|
UIMENU_RQ3_WEAPON,
|
||||||
//Makro - added join menu
|
//Makro - added join menu
|
||||||
UIMENU_RQ3_JOIN,
|
UIMENU_RQ3_JOIN,
|
||||||
UIMENU_RQ3_TKOK
|
//Makro - tkok yes/no menu
|
||||||
|
UIMENU_RQ3_TKOK,
|
||||||
|
//Makro - radio presets menu
|
||||||
|
UIMENU_RQ3_PRESETS
|
||||||
} uiMenuCommand_t;
|
} uiMenuCommand_t;
|
||||||
|
|
||||||
#define SORT_HOST 0
|
#define SORT_HOST 0
|
||||||
|
|
|
@ -5,6 +5,9 @@
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// $Log$
|
// $Log$
|
||||||
|
// Revision 1.22 2002/08/26 00:41:53 makro
|
||||||
|
// Presets menu + editor
|
||||||
|
//
|
||||||
// Revision 1.21 2002/06/16 20:06:15 jbravo
|
// Revision 1.21 2002/06/16 20:06:15 jbravo
|
||||||
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
|
||||||
//
|
//
|
||||||
|
@ -236,8 +239,11 @@ int UI_RQ3_KeyNumFromChar(const char *keystr)
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; RQ3_KeyAliases[i].Value != K_LAST_KEY; i++) {
|
for (i = 0; RQ3_KeyAliases[i].Value != K_LAST_KEY; i++) {
|
||||||
if (Q_stricmp(RQ3_KeyAliases[i].Name, keystr) == 0) {
|
//let's make sure we have valid strings
|
||||||
return RQ3_KeyAliases[i].Value;
|
if (RQ3_KeyAliases[i].Name[0] && keystr && keystr[0]) {
|
||||||
|
if (Q_stricmp(RQ3_KeyAliases[i].Name, keystr) == 0) {
|
||||||
|
return RQ3_KeyAliases[i].Value;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3288,6 +3294,7 @@ qboolean UI_RQ3_TriggerShortcut(menuDef_t * menu, int key)
|
||||||
for (i = 0; i < menu->itemCount; i++) {
|
for (i = 0; i < menu->itemCount; i++) {
|
||||||
if (menu->items[i]->window.shortcutKey == key && UI_RQ3_IsActiveItem(menu->items[i])) {
|
if (menu->items[i]->window.shortcutKey == key && UI_RQ3_IsActiveItem(menu->items[i])) {
|
||||||
Item_Action(menu->items[i]);
|
Item_Action(menu->items[i]);
|
||||||
|
//Item_HandleKey(menu->items[i], K_ENTER, qtrue);
|
||||||
return qtrue;
|
return qtrue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3930,10 +3937,10 @@ static bind_t g_bindings[] = {
|
||||||
{"irvision", 'v', -1, -1, -1},
|
{"irvision", 'v', -1, -1, -1},
|
||||||
//Makro - this one was missing
|
//Makro - this one was missing
|
||||||
{"specialweapon", 'e', -1, -1, -1},
|
{"specialweapon", 'e', -1, -1, -1},
|
||||||
//Makro - for the weapon/item, join and radio menus
|
//Makro - for the weapon/item, join, presets and tkok menus
|
||||||
{"ui_RQ3_loadout", 'l', -1, -1, -1},
|
{"ui_RQ3_loadout", 'l', -1, -1, -1},
|
||||||
{"ui_RQ3_joinTeam", 'j', -1, -1, -1},
|
{"ui_RQ3_joinTeam", 'j', -1, -1, -1},
|
||||||
{"ui_RQ3_radio", -1, -1, -1, -1},
|
{"ui_RQ3_presets", -1, -1, -1, -1},
|
||||||
{"ui_RQ3_tkok", -1, -1, -1, -1},
|
{"ui_RQ3_tkok", -1, -1, -1, -1},
|
||||||
{"screenshot", -1, -1, -1. - 1},
|
{"screenshot", -1, -1, -1. - 1},
|
||||||
{"screenshotJPEG", K_F12, -1, -1. - 1}
|
{"screenshotJPEG", K_F12, -1, -1. - 1}
|
||||||
|
@ -7025,7 +7032,7 @@ static void Menu_CacheContents(menuDef_t * menu)
|
||||||
DC->registerSound(menu->soundName, qfalse);
|
DC->registerSound(menu->soundName, qfalse);
|
||||||
}
|
}
|
||||||
//Makro - caching sound intro
|
//Makro - caching sound intro
|
||||||
if (menu->soundName && *menu->soundIntro) {
|
if (menu->soundIntro && *menu->soundIntro) {
|
||||||
DC->registerSound(menu->soundIntro, qfalse);
|
DC->registerSound(menu->soundIntro, qfalse);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue