mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-10-02 10:53:44 +00:00
The ActivatePhysics trigger command was a TODO. The client activates or deactivates the object's physics component (LWOPhysicsSystemComponent::msgActivatePhysics, 1.10.64 0x00ccf970); the server now does the same to phantom physics: switching it off takes the volume out of the physics world (dpWorld::DetachEntity, without deleting it) and makes whatever was inside leave, switching it on adds it back and whatever is inside enters on the next step. This lets trigger driven volumes like the monument lasers turn on and off. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
28 lines
542 B
C++
28 lines
542 B
C++
#pragma once
|
|
|
|
#include <cstdint>
|
|
|
|
class dNavMesh;
|
|
class dpEntity;
|
|
|
|
namespace dpWorld {
|
|
void Initialize(uint32_t zoneID, bool generateNewNavMesh = true);
|
|
void Shutdown();
|
|
void Reload();
|
|
|
|
bool ShouldUseSP(uint32_t zoneID);
|
|
bool IsLoaded();
|
|
|
|
void StepWorld(float deltaTime);
|
|
|
|
void AddEntity(dpEntity* entity);
|
|
void RemoveEntity(dpEntity* entity);
|
|
|
|
/**
|
|
* Takes an entity out of the world without deleting it, so it can be added back later (a volume switched off)
|
|
*/
|
|
void DetachEntity(dpEntity* entity);
|
|
|
|
dNavMesh* GetNavMesh();
|
|
};
|