mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-05-13 05:57:05 +03:00
Remove some instances of Lara global usage in motorbike.cpp; cleanup
This commit is contained in:
parent
4b381fa048
commit
e30eba578f
5 changed files with 1259 additions and 1272 deletions
|
@ -93,7 +93,7 @@ bool HandleLaraVehicle(ItemInfo* item, CollisionInfo* coll)
|
|||
break;
|
||||
|
||||
case ID_MOTORBIKE:
|
||||
MotorbikeControl();
|
||||
MotorbikeControl(item, coll);
|
||||
break;
|
||||
|
||||
case ID_KAYAK:
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -2,8 +2,6 @@
|
|||
#include "Game/items.h"
|
||||
#include "Game/collision/collide_room.h"
|
||||
|
||||
|
||||
|
||||
void InitialiseMotorbike(short itemNumber);
|
||||
void MotorbikeCollision(short itemNumber, ItemInfo* laraitem, CollisionInfo* coll);
|
||||
int MotorbikeControl(void);
|
||||
void MotorbikeCollision(short itemNumber, ItemInfo* laraItem, CollisionInfo* coll);
|
||||
bool MotorbikeControl(ItemInfo* laraItem, CollisionInfo* coll);
|
||||
|
|
|
@ -1,15 +1,21 @@
|
|||
#pragma once
|
||||
struct MotorbikeInfo {
|
||||
short wheelRight; // (two wheel: front and back)
|
||||
short wheelLeft; // (one wheel: left)
|
||||
int velocity;
|
||||
int revs;
|
||||
int engineRevs;
|
||||
short momentumAngle;
|
||||
short extraRotation;
|
||||
short wallShiftRotation;
|
||||
int bikeTurn;
|
||||
int pitch;
|
||||
short flags;
|
||||
short lightPower;
|
||||
};
|
||||
|
||||
struct MotorbikeInfo
|
||||
{
|
||||
short TurnRate;
|
||||
short MomentumAngle;
|
||||
short ExtraRotation;
|
||||
short WallShiftRotation;
|
||||
|
||||
int Velocity;
|
||||
|
||||
int Revs;
|
||||
int EngineRevs;
|
||||
int Pitch;
|
||||
|
||||
short RightWheelsRotation;
|
||||
short LeftWheelRotation;
|
||||
|
||||
short LightPower;
|
||||
short Flags;
|
||||
};
|
||||
|
|
|
@ -238,10 +238,10 @@ namespace TEN::Renderer
|
|||
{
|
||||
case 2:
|
||||
case 4:
|
||||
currentBone->ExtraRotation.x = TO_RAD(bike.wheelRight);
|
||||
currentBone->ExtraRotation.x = TO_RAD(bike.RightWheelsRotation);
|
||||
break;
|
||||
case 8:
|
||||
currentBone->ExtraRotation.x = TO_RAD(bike.wheelLeft);
|
||||
currentBone->ExtraRotation.x = TO_RAD(bike.LeftWheelRotation);
|
||||
break;
|
||||
}
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue