![]() |
GDevelop Core
Core library for developing platforms and tools compatible with GDevelop.
|
Contains effects applied to an entity on screen (i.e: a Layer or an Object). More...
#include <EffectsContainer.h>
Public Member Functions | |
| EffectsContainer (const EffectsContainer &other) | |
| EffectsContainer & | operator= (const EffectsContainer &rhs) |
| bool | HasEffectNamed (const gd::String &name) const |
| Return true if the effect called "name" exists. | |
| Effect & | GetEffect (const gd::String &name) |
| Return a reference to the effect called "name". | |
| const Effect & | GetEffect (const gd::String &name) const |
| Return a reference to the effect called "name". | |
| Effect & | GetEffect (std::size_t index) |
| const Effect & | GetEffect (std::size_t index) const |
| std::size_t | GetEffectPosition (const gd::String &name) const |
| std::size_t | GetEffectsCount () const |
| gd::Effect & | InsertNewEffect (const gd::String &name, std::size_t position) |
| void | InsertEffect (const Effect &theEffect, std::size_t position) |
| Add a copy of the specified effect in the effects list. More... | |
| void | RemoveEffect (const gd::String &name) |
| void | MoveEffect (std::size_t oldIndex, std::size_t newIndex) |
| Move the specified effect at a new position in the list. | |
| void | SwapEffects (std::size_t firstEffectIndex, std::size_t secondEffectIndex) |
| void | SerializeTo (SerializerElement &element) const |
| Serialize the effects container. | |
| void | UnserializeFrom (const SerializerElement &element) |
| Unserialize the effects container. | |
| void | Clear () |
| Clear all effects of the container. | |
| gd::Effect & gd::EffectsContainer::GetEffect | ( | std::size_t | index | ) |
Return a reference to the effect at position "index" in the effects list
| const gd::Effect & gd::EffectsContainer::GetEffect | ( | std::size_t | index | ) | const |
Return a reference to the effect at position "index" in the effects list
| std::size_t gd::EffectsContainer::GetEffectPosition | ( | const gd::String & | name | ) | const |
Return the position of the effect called "name" in the effects list
| std::size_t gd::EffectsContainer::GetEffectsCount | ( | ) | const |
Return the number of effects.
| void gd::EffectsContainer::InsertEffect | ( | const Effect & | theEffect, |
| std::size_t | position | ||
| ) |
Add a copy of the specified effect in the effects list.
| theEffect | The effect that must be copied and inserted into the effects list |
| position | Insertion position. |
| gd::Effect & gd::EffectsContainer::InsertNewEffect | ( | const gd::String & | name, |
| std::size_t | position | ||
| ) |
Add a new effect at the specified position in the effects list.
| void gd::EffectsContainer::RemoveEffect | ( | const gd::String & | name | ) |
Remove the specified effect.
| void gd::EffectsContainer::SwapEffects | ( | std::size_t | firstEffectIndex, |
| std::size_t | secondEffectIndex | ||
| ) |
Swap the position of two effects.