3 #include <boost/range/adaptor/map.hpp>
5 #include "engine/component.h"
6 #include "engine/system.h"
7 #include "engine/touchable.h"
8 #include "scripting/luabind.h"
9 #include "engine/typedefs.h"
11 #include <luabind/object.hpp>
13 #include <OgreCommon.h>
15 #include <OgreVector3.h>
16 #include <unordered_set>
25 using BoostCompoundMapIterator = boost::range_detail::select_second_mutable_range<std::unordered_map<std::string, CompoundId>>;
26 using BoostAbsorbedMapIterator = boost::range_detail::select_first_range<std::unordered_map<CompoundId, float>>;
124 void update(
int,
int)
override;
128 struct Implementation;
129 std::unique_ptr<Implementation> m_impl;
static luabind::scope luaBindings()
Lua bindings.
Definition: compound.cpp:32
static luabind::scope luaBindings()
Lua bindings.
Definition: compound.cpp:75
CompoundMovementSystem()
Constructor.
Definition: compound.cpp:92
~CompoundMovementSystem()
Destructor.
Definition: compound.cpp:98
Base class for components.
Definition: component.h:31
A system handles one specific part of the game.
Definition: system.h:23
Moves compound particles around.
Definition: compound.h:85
void load(const StorageContainer &storage) override
Loads the component.
Definition: compound.cpp:50
Definition: bullet_to_ogre_system.h:5
CompoundId m_compoundId
The compound id.
Definition: compound.h:59
Definition: bullet_ogre_conversion.h:6
Ogre::Vector3 m_velocity
The current velocity of the particle.
Definition: compound.h:69
GameState * gameState() const
Returns the system's game state.
Definition: system.cpp:183
Represents a distinct set of active systems and entities.
Definition: game_state.h:41
void update(int, int) override
Updates the system.
Definition: compound.cpp:118
float m_potency
The potency of this particle.
Definition: compound.h:64
StorageContainer storage() const override
Serializes the component.
Definition: compound.cpp:61
void shutdown() override
Shuts the system down.
Definition: compound.cpp:111
void init(GameState *gameState) override
Initializes the system.
Definition: compound.cpp:102
A key-value storage for serialization.
Definition: serialization.h:36
Component for entities that act as compound particles or agent particles Note that this class is stro...
Definition: compound.h:37