载入中...
搜索中...
未找到
VehiclePhysicsAbsent.cpp
浏览该文件的文档.
2
3namespace eve::vehicle {
4
7}
8
11}
12
14
15bool VehiclePhysics::isAttached(VehicleEntity*) { return false; }
16
17float VehiclePhysics::height(VehicleEntity*) { return 0.f; }
18
21}
22
23void VehiclePhysics::syncTrackFromBody(VehicleEntity&) {}
24
25VehiclePhysicsStatus VehiclePhysics::tryTrackApply(VehicleEntity&, float, float) {
27}
28
30
31} // namespace eve::vehicle
Box3D rigid-body world. Script coordinates are meters (Box3D native), unlike 2D World which uses pixe...
Definition World3D.h:63
Box2D world wrapper (2D physics) with pixel-space coordinates. Handles stepping, gravity,...
Definition World.h:41
static VehiclePhysicsStatus detach(VehicleEntity *v)
Destroy attached bodies if any.
static VehiclePhysicsStatus tryWheelMove(VehicleEntity &v, float dt)
Step wheel/ship mobility from an attached body.
static void registerBuiltinMobility()
Register suspension mobility when physics is in the build.
static void syncTrackFromBody(VehicleEntity &v)
Copy attached body pose into motion for tracked vehicles.
static VehiclePhysicsStatus attach2D(VehicleEntity *v, eve::physics::World *world)
Attach a 2D dynamic body when physics is in the build.
static VehiclePhysicsStatus tryTrackApply(VehicleEntity &v, float headingRad, float speed)
Apply tracked heading/speed to an attached body.
static bool isAttached(VehicleEntity *v)
Whether the entity has a live, resolvable physics body.
static VehiclePhysicsStatus attach3D(VehicleEntity *v, eve::physics::World3D *world, float heightY)
Attach a 3D dynamic body when physics is in the build.
static float height(VehicleEntity *v)
3D body height, or 0 when no 3D body is attached.
驾驶者接口与玩家控制状态。
VehiclePhysicsStatus
Outcome of an optional physics attach, detach, or mobility step.
@ Unavailable
No physics module, no body, or invalid arguments.