All pastes #597418 Raw Edit

Min and menu

public c v1 · immutable
#597418 ·published 2007-06-30 16:31 UTC
rendered paste body
Index: src/d_clisrv.c===================================================================--- src/d_clisrv.c	(revision 1996)+++ src/d_clisrv.c	(working copy)@@ -802,8 +802,8 @@ 		}  		GetPackets();-		// connection closed by cancel or timeout-		if (!server && !netgame)+		// connection closed by cancel or timeout: in this case, server == true+		if (!netgame) 		{ 			cl_mode = cl_searching; 			return;Index: src/command.c===================================================================--- src/command.c	(revision 1995)+++ src/command.c	(working copy)@@ -971,7 +971,8 @@   */ static void Setvalue(consvar_t *var, const char *valstr) {-	int maxval = 0;+	boolean override = false;+	int overrideval = 0;  	if (var->PossibleValue) 	{@@ -992,12 +993,15 @@ 			{ 				v = var->PossibleValue[0].value; 				valstr = var->PossibleValue[0].strvalue;+				override = true;+				overrideval = v; 			} 			if (v > var->PossibleValue[i].value || !stricmp(valstr, "MAX")) 			{ 				v = var->PossibleValue[i].value; 				valstr = var->PossibleValue[i].strvalue;-				maxval = v;+				override = true;+				overrideval = v; 			} 		} 		else@@ -1067,8 +1071,8 @@ 		double d = atof(var->string); 		var->value = (int)(d * FRACUNIT); 	}-	else if (maxval)-		var->value = maxval;+	else if (override)+		var->value = overrideval; 	else 		var->value = atoi(var->string);