mirror of
https://github.com/DrBeef/Raze.git
synced 2025-01-19 23:51:01 +00:00
- simple replacements in sector and spawn code
This commit is contained in:
parent
1c05d80e53
commit
dfd098d719
4 changed files with 14 additions and 14 deletions
|
@ -2061,8 +2061,8 @@ void checkhitsprite_r(DDukeActor* targ, DDukeActor* proj)
|
|||
CreateActor(targ->sector(), targ->spr.pos.plusZ(-8), SCRAP6 + (krand() & 15), -8, 48, 48, krand() & 2047, (krand() & 63) + 64, -(krand() & 4095) - (targ->int_zvel() >> 2), targ, 5);
|
||||
break;
|
||||
case BOWLINGBALL:
|
||||
proj->set_int_xvel((targ->int_xvel() >> 1) + (targ->int_xvel() >> 2));
|
||||
proj->add_int_ang(-(krand() & 16));
|
||||
proj->vel.X = targ->vel.X * 0.75;
|
||||
if (krand() & 16) proj->spr.angle -= DAngle22_5 / 8;
|
||||
S_PlayActorSound(355, targ);
|
||||
break;
|
||||
|
||||
|
|
|
@ -406,7 +406,7 @@ void initshell(DDukeActor* actj, DDukeActor* act, bool isshell)
|
|||
|
||||
act->temp_data[0] = krand() & 1;
|
||||
act->spr.pos.Z = 3 + ps[snum].pos.Z + ps[snum].pyoff - (ps[snum].horizon.sum().asbuildf() * (1/16.)) + (!isshell ? 3 : 0);
|
||||
act->set_int_zvel(-(krand() & 255));
|
||||
act->vel.Z = -krandf(1);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -422,12 +422,12 @@ void initshell(DDukeActor* actj, DDukeActor* act, bool isshell)
|
|||
{
|
||||
// to the right, with feeling
|
||||
act->spr.angle = ang + DAngle90;
|
||||
act->set_int_xvel(30);
|
||||
act->vel.X = 1.875;
|
||||
}
|
||||
else
|
||||
{
|
||||
act->spr.angle = ang - DAngle90;
|
||||
act->set_int_xvel(20);
|
||||
act->vel.X = 1.25;
|
||||
}
|
||||
|
||||
act->spr.xrepeat = act->spr.yrepeat = isRR() && isshell? 2 : 4;
|
||||
|
@ -500,7 +500,7 @@ void initwaterdrip(DDukeActor* actj, DDukeActor* actor)
|
|||
}
|
||||
else actor->spr.pos.Z -= 13;
|
||||
actor->spr.angle = VecToAngle(ps[connecthead].pos.XY() - actor->spr.pos.XY());
|
||||
actor->set_int_xvel(48 - (krand() & 31));
|
||||
actor->vel.X = 3 - krandf(2);
|
||||
ssp(actor, CLIPMASK0);
|
||||
}
|
||||
else if (!actj)
|
||||
|
|
|
@ -203,8 +203,8 @@ DDukeActor* spawninit_d(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
if (actj)
|
||||
act->spr.angle = actj->spr.angle;
|
||||
act->spr.pos.Z -= gs.playerheight;
|
||||
act->set_int_zvel(256 - (krand() & 511));
|
||||
act->set_int_xvel(64 - (krand() & 127));
|
||||
act->vel.Z = 1 - krandf(2);
|
||||
act->vel.X = 4 - krandf(8);
|
||||
ChangeActorStat(act, 4);
|
||||
break;
|
||||
case NATURALLIGHTNING:
|
||||
|
@ -1107,7 +1107,7 @@ DDukeActor* spawninit_d(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
act->spr.angle = actj->spr.angle;
|
||||
act->spr.cstat = CSTAT_SPRITE_ALIGNMENT_WALL | CSTAT_SPRITE_YCENTER | CSTAT_SPRITE_TRANSLUCENT;
|
||||
act->spr.xrepeat = act->spr.yrepeat = 1;
|
||||
act->set_int_xvel(-8);
|
||||
act->vel.X = -0.5;
|
||||
ssp(act, CLIPMASK0);
|
||||
}
|
||||
[[fallthrough]];
|
||||
|
@ -1162,7 +1162,7 @@ DDukeActor* spawninit_d(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
act->spr.pal = 0;
|
||||
act->SetOwner(act);
|
||||
ChangeActorStat(act, STAT_STANDABLE);
|
||||
act->set_int_xvel(8);
|
||||
act->vel.X = 0.5;
|
||||
ssp(act, CLIPMASK0);
|
||||
break;
|
||||
|
||||
|
|
|
@ -285,8 +285,8 @@ DDukeActor* spawninit_r(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
if (actj)
|
||||
act->spr.angle = actj->spr.angle;
|
||||
act->spr.pos.Z -= gs.playerheight;
|
||||
act->set_int_zvel(256 - (krand() & 511));
|
||||
act->set_int_xvel(64 - (krand() & 127));
|
||||
act->vel.Z = 1 - krandf(2);
|
||||
act->vel.X = 4 - krandf(8);
|
||||
ChangeActorStat(act, 4);
|
||||
break;
|
||||
case TRANSPORTERSTAR:
|
||||
|
@ -1358,7 +1358,7 @@ DDukeActor* spawninit_r(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
act->spr.angle = actj->spr.angle;
|
||||
act->spr.cstat = CSTAT_SPRITE_ALIGNMENT_WALL | CSTAT_SPRITE_YCENTER | CSTAT_SPRITE_TRANSLUCENT;
|
||||
act->spr.xrepeat = act->spr.yrepeat = 1;
|
||||
act->set_int_xvel(-8);
|
||||
act->vel.X = -0.5;
|
||||
ssp(act, CLIPMASK0);
|
||||
}
|
||||
[[fallthrough]];
|
||||
|
@ -1400,7 +1400,7 @@ DDukeActor* spawninit_r(DDukeActor* actj, DDukeActor* act, TArray<DDukeActor*>*
|
|||
act->spr.pal = 0;
|
||||
act->SetOwner(act);
|
||||
ChangeActorStat(act, STAT_STANDABLE);
|
||||
act->set_int_xvel(8);
|
||||
act->vel.X = 0.5;
|
||||
ssp(act, CLIPMASK0);
|
||||
break;
|
||||
|
||||
|
|
Loading…
Reference in a new issue