mirror of
https://github.com/ZDoom/Raze.git
synced 2025-02-21 11:01:01 +00:00
- all of int_ang in aizombf.cpp
Note that the z-offset in ThrowSeqCallback was not correct - eyeHeight is in pixels, but this was passed as a Build-z-parameter which is scaled by 256, effectively rendering the offset almost ineffective.
This commit is contained in:
parent
e4f8178947
commit
0577b678d2
1 changed files with 4 additions and 4 deletions
|
@ -52,10 +52,10 @@ void zombfHackSeqCallback(int, DBloodActor* actor)
|
||||||
if (!actor->ValidateTarget(__FUNCTION__)) return;
|
if (!actor->ValidateTarget(__FUNCTION__)) return;
|
||||||
auto target = actor->GetTarget();
|
auto target = actor->GetTarget();
|
||||||
DUDEINFO* pDudeInfo = getDudeInfo(actor->spr.type);
|
DUDEINFO* pDudeInfo = getDudeInfo(actor->spr.type);
|
||||||
int height = (pDudeInfo->eyeHeight * actor->spr.yrepeat);
|
double height = pDudeInfo->eyeHeight * actor->spr.yrepeat * REPEAT_SCALE * 0.25;
|
||||||
DUDEINFO* pDudeInfoT = getDudeInfo(target->spr.type);
|
DUDEINFO* pDudeInfoT = getDudeInfo(target->spr.type);
|
||||||
int height2 = (pDudeInfoT->eyeHeight * target->spr.yrepeat);
|
double height2 = pDudeInfoT->eyeHeight * target->spr.yrepeat * REPEAT_SCALE * 0.25;
|
||||||
actFireVector(actor, 0, 0, bcos(actor->int_ang()), bsin(actor->int_ang()), height - height2, kVectorCleaver);
|
actFireVector(actor, 0, 0, DVector3(actor->spr.angle.ToVector() * 64, height - height2), kVectorCleaver);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PukeSeqCallback(int, DBloodActor* actor)
|
void PukeSeqCallback(int, DBloodActor* actor)
|
||||||
|
@ -77,7 +77,7 @@ void PukeSeqCallback(int, DBloodActor* actor)
|
||||||
|
|
||||||
void ThrowSeqCallback(int, DBloodActor* actor)
|
void ThrowSeqCallback(int, DBloodActor* actor)
|
||||||
{
|
{
|
||||||
actFireMissile(actor, 0, -getDudeInfo(actor->spr.type)->eyeHeight, bcos(actor->int_ang()), bsin(actor->int_ang()), 0, kMissileButcherKnife);
|
actFireMissile(actor, 0, 0, DVector3(actor->spr.angle.ToVector(), 0), kMissileButcherKnife);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void zombfThinkSearch(DBloodActor* actor)
|
static void zombfThinkSearch(DBloodActor* actor)
|
||||||
|
|
Loading…
Reference in a new issue