replacement = ftos(vlen(self.velocity - self.velocity_z * '0 0 1'));
else if (escape == "S")
replacement = ftos(vlen(self.velocity));
- else if (escape == "v") {
- float weapon_number;
- local entity stats;
-
- if(self.classname == "spectator")
- stats = self.enemy;
- else
- stats = self;
-
- weapon_number = stats.weapon;
-
- if (!weapon_number)
- weapon_number = stats.switchweapon;
-
- if (!weapon_number)
- weapon_number = stats.cnt;
-
- if(stats.cvar_cl_accuracy_data_share && stats.stats_fired[weapon_number - 1])
- replacement = ftos(bound(0, floor(100 * stats.stats_hit[weapon_number - 1] / stats.stats_fired[weapon_number - 1]), 100));
- else
- replacement = "~"; // or something to indicate NULL, not available
- }
msg = strcat(substring(msg, 0, p), replacement, substring(msg, p+2, strlen(msg) - (p+2)));
p = p + strlen(replacement);
return v;
};
+//#NO AUTOCVARS START
+
float g_pickup_shells;
float g_pickup_shells_max;
float g_pickup_nails;
readplayerstartcvars();
}
-/*
-// TODO sound pack system
-string soundpack;
-
-string precache_sound_builtin (string s) = #19;
-void(entity e, float chan, string samp, float vol, float atten) sound_builtin = #8;
-string precache_sound(string s)
-{
- return precache_sound_builtin(strcat(soundpack, s));
-}
-void play2(entity e, string filename)
-{
- stuffcmd(e, strcat("play2 ", soundpack, filename, "\n"));
-}
-void sound(entity e, float chan, string samp, float vol, float atten)
-{
- sound_builtin(e, chan, strcat(soundpack, samp), vol, atten);
-}
-*/
+//#NO AUTOCVARS END
// Sound functions
string precache_sound (string s) = #19;
}
#define PROJECTILE_TOUCH if(WarpZone_Projectile_Touch()) return
-float MAX_IPBAN_URIS = 16;
-
-float URI_GET_DISCARD = 0;
-float URI_GET_IPBAN = 1;
-float URI_GET_IPBAN_END = 16;
+float MAX_IPBAN_URIS = 16;
+
+float URI_GET_DISCARD = 0;
+float URI_GET_IPBAN = 1;
+float URI_GET_IPBAN_END = 16;
+float URI_GET_PLAYERSTATS_SENT = 17;
void URI_Get_Callback(float id, float status, string data)
{
// online ban list
OnlineBanList_URI_Get_Callback(id, status, data);
}
+ else if (id == URI_GET_PLAYERSTATS_SENT)
+ {
+ PlayerStats_Sent_URI_Get_Callback(id, status, data);
+ }
else
{
print("Received HTTP request data for an invalid id ", ftos(id), ".\n");