mirror of
https://github.com/ZDoom/Raze.git
synced 2025-02-16 08:41:22 +00:00
fixed some bad copy/pasted dudeSlope calculations.
This commit is contained in:
parent
57f4dc7338
commit
0ad7e198d8
3 changed files with 3 additions and 3 deletions
|
@ -239,7 +239,7 @@ static void beastThinkChase(DBloodActor* actor)
|
|||
if (nDist < pDudeInfo->SeeDist() && nDeltaAngle <= pDudeInfo->Periphery())
|
||||
{
|
||||
aiSetTarget(actor, actor->GetTarget());
|
||||
actor->dudeSlope = nDist == 0 ? 0 : int(target->spr.pos.Z - actor->spr.pos.Z / nDist);
|
||||
actor->dudeSlope = nDist == 0 ? 0 : (target->spr.pos.Z - actor->spr.pos.Z) / nDist;
|
||||
if (nDist < 0x140 && nDist > 0xa0 && nDeltaAngle < DAngle15 && (target->spr.flags & 2)
|
||||
&& target->IsPlayerActor() && Chance(0x8000))
|
||||
{
|
||||
|
|
|
@ -158,7 +158,7 @@ static void calebThinkChase(DBloodActor* actor)
|
|||
if (nDist < pDudeInfo->SeeDist() && nDeltaAngle <= pDudeInfo->Periphery())
|
||||
{
|
||||
aiSetTarget(actor, actor->GetTarget());
|
||||
actor->dudeSlope = nDist == 0 ? 0 : target->spr.pos.Z - actor->spr.pos.Z / nDist;
|
||||
actor->dudeSlope = nDist == 0 ? 0 : (target->spr.pos.Z - actor->spr.pos.Z) / nDist;
|
||||
if (nDist < 89.5625 && abs(nDeltaAngle) < DAngle1 * 5)
|
||||
{
|
||||
int hit = HitScan(actor, actor->spr.pos.Z, DVector3(dvec, 0), CLIPMASK1, 0);
|
||||
|
|
|
@ -527,7 +527,7 @@ static void unicultThinkChase(DBloodActor* actor)
|
|||
if ((PlayClock & 64) == 0 && Chance(0x3000) && !spriteIsUnderwater(actor, false))
|
||||
playGenDudeSound(actor, kGenDudeSndChasing);
|
||||
|
||||
actor->dudeSlope = dist == 0 ? 0 : target->spr.pos.Z - actor->spr.pos.Z / dist;
|
||||
actor->dudeSlope = dist == 0 ? 0 : (target->spr.pos.Z - actor->spr.pos.Z) / dist;
|
||||
|
||||
int curWeapon = actor->genDudeExtra.curWeapon;
|
||||
int weaponType = actor->genDudeExtra.weaponType;
|
||||
|
|
Loading…
Reference in a new issue