reverted sniper test scenario

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@3478 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
driAn
2008-11-09 22:20:03 +00:00
parent 20e2346879
commit 2441b1ca63
3 changed files with 5 additions and 7 deletions
+1 -1
View File
@@ -66,7 +66,7 @@ static guninfo guns[NUMGUNS] =
{ "pistol", S_PISTOL, S_RPISTOL, 1400, 170, 19, 0, 0, 80, 10, 8, 6, 5, 1, 40, 75, 150, 1, false },
{ "shotgun", S_SHOTGUN, S_RSHOTGUN, 2400, 1000, 5, 0, 0, 1, 35, 7, 9, 9, 1, 130, 500, 150, 1, false },
{ "subgun", S_SUBGUN, S_RSUBGUN, 1650, 80, 16, 0, 0, 70, 15, 30, 1, 2, 4, 40, 60, 200, 1, true },
{ "sniper", S_SNIPER, S_RSNIPER, 1950, 1500, 81, 0, 0, 1, 50, 5, 4, 4, 1, 100, 500, 100, 1, false },
{ "sniper", S_SNIPER, S_RSNIPER, 1950, 1500, 85, 0, 0, 60, 50, 5, 4, 4, 1, 100, 500, 100, 1, false },
{ "assault", S_ASSAULT, S_RASSAULT, 2000, 130, 24, 0, 0, 20, 40, 15, 0, 2, 2, 25, 60, 150, 1, true },
{ "grenade", S_NULL, S_NULL, 1000, 650, 200, 20, 6, 1, 1, 1, 3, 1, 0, 0, 0, 0, 3, false },
{ "pistol", S_PISTOL, S_RAKIMBO, 1400, 80, 19, 0, 0, 80, 10, 16, 6, 5, 4, 30, 75, 150, 1, true },
+3 -6
View File
@@ -1020,6 +1020,7 @@ bool sniperrifle::reload()
return r;
}
int sniperrifle::dynspread() { return scoped ? 1 : info.spread; }
float sniperrifle::dynrecoil() { return scoped ? info.recoil / 3 : info.recoil; }
bool sniperrifle::selectable() { return weapon::selectable() && !m_noprimary && this == owner->primweap; }
void sniperrifle::onselecting() { weapon::onselecting(); scoped = false; }
@@ -1029,12 +1030,8 @@ void sniperrifle::renderhudmodel() { if(!scoped) weapon::renderhudmodel(); }
void sniperrifle::renderaimhelp(bool teamwarning)
{
if(scoped)
{
drawscope();
drawcrosshair(owner, teamwarning ? CROSSHAIR_TEAMMATE : CROSSHAIR_SCOPE, NULL, 24.0f);
}
else weapon::renderaimhelp(teamwarning);
if(scoped) drawscope();
if(scoped || teamwarning) drawcrosshair(owner, teamwarning ? CROSSHAIR_TEAMMATE : CROSSHAIR_SCOPE, NULL, 24.0f);
}
void sniperrifle::setscope(bool enable) { if(this == owner->weaponsel && !reloading && owner->state == CS_ALIVE) scoped = enable; }
+1
View File
@@ -103,6 +103,7 @@ struct sniperrifle : gun
void attackfx(const vec &from, const vec &to, int millis);
bool reload();
int dynspread();
float dynrecoil();
bool selectable();
void onselecting();