stuffcmd(self, strcat("cl_cmd sendcvar ", name, "\n"));
}
}
-string W_FixWeaponOrder_ForceComplete(string s);
-string W_FixWeaponOrder_AllowIncomplete(string s);
float w_getbestweapon(entity e);
+string W_FixWeaponOrder_ForceComplete_AndBuildImpulseList(string wo)
+{
+ string o;
+ o = W_FixWeaponOrder_ForceComplete(wo);
+ if(self.weaponorder_byimpulse)
+ {
+ strunzone(self.weaponorder_byimpulse);
+ self.weaponorder_byimpulse = string_null;
+ }
+ self.weaponorder_byimpulse = strzone(W_FixWeaponOrder_BuildImpulseList(o));
+ return o;
+}
void GetCvars(float f)
{
string s;
GetCvars_handleFloat(s, f, cvar_cl_shownames, "cl_shownames");
GetCvars_handleString(s, f, cvar_g_xonoticversion, "g_xonoticversion");
GetCvars_handleFloat(s, f, cvar_cl_handicap, "cl_handicap");
- GetCvars_handleString_Fixup(s, f, cvar_cl_weaponpriority, "cl_weaponpriority", W_FixWeaponOrder_ForceComplete);
+ GetCvars_handleString_Fixup(s, f, cvar_cl_weaponpriority, "cl_weaponpriority", W_FixWeaponOrder_ForceComplete_AndBuildImpulseList);
GetCvars_handleString_Fixup(s, f, cvar_cl_weaponpriorities[0], "cl_weaponpriority0", W_FixWeaponOrder_AllowIncomplete);
GetCvars_handleString_Fixup(s, f, cvar_cl_weaponpriorities[1], "cl_weaponpriority1", W_FixWeaponOrder_AllowIncomplete);
GetCvars_handleString_Fixup(s, f, cvar_cl_weaponpriorities[2], "cl_weaponpriority2", W_FixWeaponOrder_AllowIncomplete);
#define INITPRIO_FIRST 0
#define INITPRIO_GAMETYPE 0
#define INITPRIO_GAMETYPE_FALLBACK 1
-#define INITPRIO_CVARS 5
#define INITPRIO_FINDTARGET 10
#define INITPRIO_DROPTOFLOOR 20
#define INITPRIO_SETLOCATION 90
for (i = 0; i <= LADDER_CNT; ++i) { // i = 0 because it is the speed award
if(i == 0) // speed award
{
- print("^1Hit! ", db_get(ServerProgsDB, strcat(MapInfo_Map_bspname, rr, "speed/speed")), "\n");
if(stof(db_get(ServerProgsDB, strcat(MapInfo_Map_bspname, rr, "speed/speed"))) == 0)
continue;
- print("^1Also hit after\n");
myuid = db_get(ServerProgsDB, strcat(MapInfo_Map_bspname, rr, "speed/crypto_idfp"));
}