mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
- Duke: Pitch-adjusted velocity for shootlaser()
when free-aiming.
This commit is contained in:
parent
1b499520a5
commit
9e60284ff6
1 changed files with 3 additions and 3 deletions
|
@ -817,15 +817,15 @@ static void shootrpg(DDukeActor *actor, int p, DVector3 pos, DAngle ang, int atw
|
|||
static void shootlaser(DDukeActor* actor, int p, DVector3 pos, DAngle ang)
|
||||
{
|
||||
auto sectp = actor->sector();
|
||||
double zvel;
|
||||
double vel = 1024., zvel;
|
||||
int j;
|
||||
HitInfo hit{};
|
||||
|
||||
if (p >= 0)
|
||||
zvel = ps[p].horizon.sum().Tan() * 16.;
|
||||
setFreeAimVelocity(vel, zvel, ps[p].horizon.sum(), 16.);
|
||||
else zvel = 0;
|
||||
|
||||
hitscan(pos, sectp, DVector3(ang.ToVector() * 1024, zvel * 64), hit, CLIPMASK1);
|
||||
hitscan(pos, sectp, DVector3(ang.ToVector() * vel, zvel * 64), hit, CLIPMASK1);
|
||||
|
||||
j = 0;
|
||||
if (hit.actor()) return;
|
||||
|
|
Loading…
Reference in a new issue