mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-06 05:50:31 +00:00
truly a community project, this has been kicking around since 2003 in various forms. adds a path following shape that can be ridden.
This commit is contained in:
parent
f007700646
commit
f7f8faf47e
14 changed files with 1399 additions and 8 deletions
|
|
@ -36,17 +36,21 @@
|
|||
#include "gfx/gfxPrimitiveBuffer.h"
|
||||
#endif
|
||||
|
||||
class BaseMatInstance;
|
||||
#ifndef _STATICSHAPE_H_
|
||||
#include "T3D/staticShape.h"
|
||||
#endif
|
||||
|
||||
class BaseMatInstance;
|
||||
struct PathShapeData;
|
||||
|
||||
namespace SimPath
|
||||
{
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/// A path!
|
||||
class Path : public SimGroup
|
||||
class Path : public GameBase
|
||||
{
|
||||
typedef SimGroup Parent;
|
||||
typedef GameBase Parent;
|
||||
|
||||
public:
|
||||
enum : U32
|
||||
|
|
@ -57,8 +61,12 @@ class Path : public SimGroup
|
|||
|
||||
private:
|
||||
U32 mPathIndex;
|
||||
F32 mPathSpeed;
|
||||
bool mIsLooping;
|
||||
|
||||
PathShapeData* mDataBlock;
|
||||
S32 mSpawnCount;
|
||||
S32 mMinDelay;
|
||||
S32 mMaxDelay;
|
||||
protected:
|
||||
bool onAdd();
|
||||
void onRemove();
|
||||
|
|
@ -77,6 +85,7 @@ class Path : public SimGroup
|
|||
|
||||
DECLARE_CONOBJECT(Path);
|
||||
static void initPersistFields();
|
||||
DECLARE_CALLBACK(void, onAdd, (SimObjectId ID));
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue