X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fclient%2Fcasings.qc;h=02e06001ece8b504e01ae8ac17badd35883bbe0d;hb=7116827232f791ad3592afa2f2f065905e3aa460;hp=2225c0f35260d6ac88320cc2027939d4ba5d528e;hpb=bf20397b0c62c9de0335ef9d70d60842fde9d0b2;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/client/casings.qc b/qcsrc/client/casings.qc index 2225c0f35..02e06001e 100644 --- a/qcsrc/client/casings.qc +++ b/qcsrc/client/casings.qc @@ -1,4 +1,4 @@ -.float silent; +.bool silent; void Casing_Delete() { @@ -44,16 +44,15 @@ void Casing_Touch() if(time >= self.nextthink) { string s; - float f; + int f = floor(prandom() * 3) + 1; - f = floor(prandom() * 3) + 1; switch(self.state) { case 1: - s = strcat("weapons/casings", ftos(f), ".wav"); + s = strcat("weapons/casings", itos(f), ".wav"); break; default: - s = strcat("weapons/brass", ftos(f), ".wav"); + s = strcat("weapons/brass", itos(f), ".wav"); break; } @@ -65,7 +64,7 @@ void Casing_Touch() self.nextthink = time + 0.2; } -void Casing_Damage(float thisdmg, float hittype, vector org, vector thisforce) +void Casing_Damage(float thisdmg, int hittype, vector org, vector thisforce) { if(thisforce_z < 0) thisforce_z = 0;