diff --git a/source/games/duke/src/actors.cpp b/source/games/duke/src/actors.cpp index 1363a41cd..22f2e20be 100644 --- a/source/games/duke/src/actors.cpp +++ b/source/games/duke/src/actors.cpp @@ -1514,8 +1514,8 @@ bool queball(DDukeActor *actor, int pocket, int queball, int stripeball) if (act2 == nullptr) { if (actor->spr.pal == 12) - actor->set_int_xvel(164); - else actor->set_int_xvel(140); + actor->vel.X = 10.25; + else actor->vel.Z = 8.75; actor->set_int_ang(ps[p].angle.ang.Buildang()); ps[p].toggle_key_flag = 2; } @@ -4604,7 +4604,7 @@ void handle_se130(DDukeActor *actor, int countmax, int EXPLOSION2) k->spr.xrepeat = k->spr.yrepeat = 2 + (krand() & 7); k->spr.pos.Z = sc->floorz + krandf(x); k->add_int_ang(256 - (krand() % 511)); - k->set_int_xvel(krand() & 127); + k->vel.X = krandf(8); ssp(k, CLIPMASK0); } } diff --git a/source/games/duke/src/actors_d.cpp b/source/games/duke/src/actors_d.cpp index 79e43562d..3ef1f43e6 100644 --- a/source/games/duke/src/actors_d.cpp +++ b/source/games/duke/src/actors_d.cpp @@ -748,8 +748,8 @@ void movefallers_d(void) act->spr.lotag-=3; if (act->spr.lotag <= 0) { - act->set_int_xvel((32 + (krand() & 63))); - act->set_int_zvel(-(1024 + (krand() & 1023))); + act->vel.X = 2 + krandf(4); + act->vel.Z = -4 + krandf(4); } } else @@ -1313,8 +1313,8 @@ static bool movefireball(DDukeActor* actor) { actor->temp_actor = ball; - ball->set_int_xvel(actor->int_xvel()); - ball->set_int_zvel(actor->int_zvel()); + ball->vel.X = actor->vel.X; + ball->vel.Z = actor->vel.Z; if (actor->temp_data[0] > 1) { if (trail) @@ -1979,7 +1979,7 @@ void movetransports_d(void) auto k = spawn(act2, WATERSPLASH2); if (k && sectlotag == 1 && act2->spr.statnum == 4) { - k->set_int_xvel(act2->int_xvel() >> 1); + k->vel.X = act2->vel.X * 0.5; k->spr.angle = act2->spr.angle; ssp(k, CLIPMASK0); } diff --git a/source/games/duke/src/actors_r.cpp b/source/games/duke/src/actors_r.cpp index 0516216a4..6ae9dfed0 100644 --- a/source/games/duke/src/actors_r.cpp +++ b/source/games/duke/src/actors_r.cpp @@ -666,8 +666,8 @@ void movefallers_r(void) if (act->spr.lotag > 0) { act->spr.lotag -= 3; - act->set_int_xvel(((64 + krand()) & 127)); - act->set_int_zvel(-(1024 + (krand() & 1023))); + act->vel.X = 4 + krandf(8); + act->vel.Z = -4 + krandf(4); } else { @@ -1651,7 +1651,7 @@ void movetransports_r(void) auto spawned = spawn(act2, WATERSPLASH2); if (spawned && sectlotag == 1 && act2->spr.statnum == 4) { - spawned->set_int_xvel(act2->int_xvel() >> 1); + spawned->vel.X = act2->vel.X * 0.5; spawned->spr.angle = act2->spr.angle; ssp(spawned, CLIPMASK0); }