mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Backthrow Garden Top in look direction if on ground
This commit is contained in:
parent
134c4b7d66
commit
6c75c9b2b1
1 changed files with 4 additions and 1 deletions
|
|
@ -10277,10 +10277,13 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
||||||
{
|
{
|
||||||
if (player->throwdir == -1)
|
if (player->throwdir == -1)
|
||||||
{
|
{
|
||||||
|
const angle_t angle = P_IsObjectOnGround(player->mo) ?
|
||||||
|
player->mo->angle : K_MomentumAngle(player->mo);
|
||||||
|
|
||||||
mobj_t *top = Obj_GardenTopDestroy(player);
|
mobj_t *top = Obj_GardenTopDestroy(player);
|
||||||
|
|
||||||
// Fly off the Top at high speed
|
// Fly off the Top at high speed
|
||||||
P_Thrust(player->mo, K_MomentumAngle(player->mo), 80 * mapobjectscale);
|
P_InstaThrust(player->mo, angle, player->speed + (80 * mapobjectscale));
|
||||||
P_SetObjectMomZ(player->mo, player->mo->info->height / 8, true);
|
P_SetObjectMomZ(player->mo, player->mo->info->height / 8, true);
|
||||||
|
|
||||||
top->momx = player->mo->momx;
|
top->momx = player->mo->momx;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue