]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - common.c
properly support huge sideways friction
[xonotic/darkplaces.git] / common.c
index 26997319654de8e385b1e13e0335fab5be1ffcef..a9b21b6befcdaac4a4b81d650170aa0d2b830fc4 100644 (file)
--- a/common.c
+++ b/common.c
@@ -33,6 +33,7 @@ cvar_t cmdline = {0, "cmdline","0", "contains commandline the engine was launche
 char com_token[MAX_INPUTLINE];
 int com_argc;
 const char **com_argv;
+int com_selffd = -1;
 
 gamemode_t gamemode;
 const char *gamename;
@@ -104,6 +105,26 @@ void StoreBigLong (unsigned char *buffer, unsigned int i)
        buffer[3] = i         & 0xFF;
 }
 
+void StoreBigShort (unsigned char *buffer, unsigned short i)
+{
+       buffer[0] = (i >>  8) & 0xFF;
+       buffer[1] = i         & 0xFF;
+}
+
+void StoreLittleLong (unsigned char *buffer, unsigned int i)
+{
+       buffer[0] = i         & 0xFF;
+       buffer[1] = (i >>  8) & 0xFF;
+       buffer[2] = (i >> 16) & 0xFF;
+       buffer[3] = (i >> 24) & 0xFF;
+}
+
+void StoreLittleShort (unsigned char *buffer, unsigned short i)
+{
+       buffer[0] = i         & 0xFF;
+       buffer[1] = (i >>  8) & 0xFF;
+}
+
 /*
 ============================================================================
 
@@ -714,7 +735,6 @@ int COM_Wordwrap(const char *string, size_t length, float continuationWidth, flo
                                result += processLine(passthroughPL, startOfLine, cursor - startOfLine, spaceUsedInLine, isContinuation);
                                isContinuation = false;
                                goto out;
-                               break;
                        case '\n': // end of line
                                result += processLine(passthroughPL, startOfLine, cursor - startOfLine, spaceUsedInLine, isContinuation);
                                isContinuation = false;
@@ -1479,15 +1499,15 @@ static const gamemode_info_t gamemode_info [GAME_COUNT] =
 // GAME_EDU2P
 // COMMANDLINEOPTION: Game: -edu2p runs the game Edu2 prototype
 { "edu2p", "-edu2p", "EDU2 Prototype", "id1", "edu2", "edu2_p", "edu2prototype" },
-// GAME_BLADEMASTER
-// COMMANDLINEOPTION: Game: -blademaster runs the game Prophecy: Return of the BladeMaster
-{ "blademaster", "-blademaster", "Prophecy: Return of the BladeMaster", "basebm", NULL, "blademaster", "blademaster" },
 // GAME_PROPHECY
-// COMMANDLINEOPTION: Game: -prophecy runs the game Quake (default)
+// COMMANDLINEOPTION: Game: -prophecy runs the game Prophecy
 { "prophecy",                          "-prophecy",            "Prophecy",             "data",         NULL,                   "prophecy",                     "prophecy" },
 // GAME_BLOODOMNICIDE
 // COMMANDLINEOPTION: Game: -omnicide runs the game Blood Omnicide
 { "omnicide", "-omnicide", "Blood Omnicide", "kain", NULL, "omnicide", "omnicide" },
+// GAME_STEELSTORM
+// COMMANDLINEOPTION: Game: -steelstorm runs the game Steel Storm
+{ "steelstorm",                                "-steelstorm",          "Steel-Storm",          "gamedata",             NULL,                   "ss",                   "steelstorm" },
 };
 
 void COM_InitGameType (void)