3#include "Game/NameObj/NameObj.hpp"
4#include "Game/Gravity/GravityInfo.hpp"
5#include "Game/Gravity/PlanetGravity.hpp"
The most basic form of an object.
Registers and holds individual PlanetGravity instances. Also provides the main function for calculati...
PlanetGravityManager(const char *pName)
Constructs a new PlanetGravityManager instance.
virtual void init(const JMapInfoIter &rIter)
Effectively does nothing.
void bubbleDown(int i)
Swaps the PlanetGravity instance at the specified index with the one instance right before it.
void sortGravities()
Sorts all PlanetGravity instances by their priority in reverse order. The higher the priority is,...
bool calcTotalGravityVector(TVec3f *pGravity, GravityInfo *pInfo, const TVec3f &rPosition, u32 gravityType, u32 requester) const
Calculates the total gravity vector at the specified position in space. If the object that requests g...
void registerGravity(PlanetGravity *pGravity)
Registers a PlanetGravity instance to the array of gravities. The higher the gravity's priority is,...