Committing for aasimon. Callvote nextmap removed and replaced with cyclemap for .ini

This commit is contained in:
Richard Allen 2002-06-18 03:57:38 +00:00
parent 5cd0373234
commit b81813a8ae
5 changed files with 29 additions and 8 deletions

View file

@ -11,4 +11,5 @@
* Made it possible to add random bots when starting a game from the UI
* Items can now be dropped during bandaging
* Redid the visuals on callvote and callteamvote.
* M4 muzzleflash 25% smaller.
* M4 muzzleflash 25% smaller.
* Added callvote cyclemap. It replaces callvote nextmap

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.132 2002/06/18 03:57:38 jbravo
// Committing for aasimon. Callvote nextmap removed and replaced with cyclemap for .ini
//
// Revision 1.131 2002/06/17 16:57:39 jbravo
// Items can now be dropped during bandaging
//
@ -1788,7 +1791,7 @@ void Cmd_CallVote_f(gentity_t * ent)
return;
}
if (!Q_stricmp(arg1, "nextmap")) {
if (!Q_stricmp(arg1, "cyclemap")) {
} else if (!Q_stricmp(arg1, "map")) {
} else if (!Q_stricmp(arg1, "g_gametype")) {
} else if (!Q_stricmp(arg1, "kick")) {
@ -1796,7 +1799,7 @@ void Cmd_CallVote_f(gentity_t * ent)
} else {
trap_SendServerCommand(ent - g_entities, "print \"Invalid vote string.\n\"");
trap_SendServerCommand(ent - g_entities,
"print \"Vote commands are: nextmap, map <mapname>, g_gametype <n>, kick <player>, clientkick <clientnum>.\n\"");
"print \"Vote commands are: cyclemap, map <mapname>, g_gametype <n>, kick <player>, clientkick <clientnum>.\n\"");
return;
}
@ -1828,15 +1831,15 @@ void Cmd_CallVote_f(gentity_t * ent)
Com_sprintf(level.voteString, sizeof(level.voteString), "%s %s", arg1, arg2);
}
Com_sprintf(level.voteDisplayString, sizeof(level.voteDisplayString), "%s", level.voteString);
} else if (!Q_stricmp(arg1, "nextmap")) {
} else if (!Q_stricmp(arg1, "cyclemap")) {
char s[MAX_STRING_CHARS];
trap_Cvar_VariableStringBuffer("nextmap", s, sizeof(s));
/*trap_Cvar_VariableStringBuffer("nextmap", s, sizeof(s));
if (!*s) {
trap_SendServerCommand(ent - g_entities, "print \"nextmap not set.\n\"");
return;
}
Com_sprintf(level.voteString, sizeof(level.voteString), "vstr nextmap");
}*/
Com_sprintf(level.voteString, sizeof(level.voteString), "cyclemap");
Com_sprintf(level.voteDisplayString, sizeof(level.voteDisplayString), "%s", level.voteString);
} else {
Com_sprintf(level.voteString, sizeof(level.voteString), "%s \"%s\"", arg1, arg2);

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.88 2002/06/18 03:57:38 jbravo
// Committing for aasimon. Callvote nextmap removed and replaced with cyclemap for .ini
//
// Revision 1.87 2002/06/17 16:57:39 jbravo
// Items can now be dropped during bandaging
//
@ -2098,7 +2101,10 @@ void CheckVote(void)
{
if (level.voteExecuteTime && level.voteExecuteTime < level.time) {
level.voteExecuteTime = 0;
trap_SendConsoleCommand(EXEC_APPEND, va("%s\n", level.voteString));
if( Q_stricmp(level.voteString, "cyclemap") == 0)
BeginIntermission();
else
trap_SendConsoleCommand(EXEC_APPEND, va("%s\n", level.voteString));
}
if (!level.voteTime) {
return;

View file

@ -431,6 +431,7 @@ void Ref_Command(gentity_t * ent)
trap_SendServerCommand(ent - g_entities, "print \"map_restart\n\"");
trap_SendServerCommand(ent - g_entities, "print \"clearscores\n\"");
trap_SendServerCommand(ent - g_entities, "print \"pause\n\"");
trap_SendServerCommand(ent - g_entities, "print \"cyclemap\n\"");
return;
} else if (Q_stricmp(com, "kick") == 0) { // kick kick kick
trap_Argv(2, com, sizeof(com));
@ -473,6 +474,8 @@ void Ref_Command(gentity_t * ent)
} else
trap_SendServerCommand(ent - g_entities, "print \"No game is going..");
}
} else if (Q_stricmp(com, "cyclemap") == 0){
BeginIntermission();
} else
trap_SendServerCommand(ent - g_entities,
"print \"Invalid Referee comand. Type ref help to see a list of available commands\n\"");

View file

@ -5,6 +5,9 @@
//-----------------------------------------------------------------------------
//
// $Log$
// Revision 1.12 2002/06/18 03:57:38 jbravo
// Committing for aasimon. Callvote nextmap removed and replaced with cyclemap for .ini
//
// Revision 1.11 2002/06/16 20:06:14 jbravo
// Reindented all the source files with "indent -kr -ut -i8 -l120 -lc120 -sob -bad -bap"
//
@ -478,6 +481,11 @@ qboolean ConsoleCommand(void)
return qtrue;
}
if (Q_stricmp(cmd, "cyclemap") == 0 ) {
BeginIntermission();
return qtrue;
}
if (g_dedicated.integer) {
if (Q_stricmp(cmd, "say") == 0) {
trap_SendServerCommand(-1, va("print \"^1server: %s\n\"", ConcatArgs(1)));