![]()  | 
  
    GDevelop Core
    
   Core library for developing platforms and tools compatible with GDevelop. 
   | 
 
Contains the layers for a scene or a custom object. More...
#include <LayersContainer.h>
Public Member Functions | |
| bool | HasLayerNamed (const gd::String &name) const | 
| Return true if the layer called "name" exists.  | |
| Layer & | GetLayer (const gd::String &name) | 
| Return a reference to the layer called "name".  | |
| const Layer & | GetLayer (const gd::String &name) const | 
| Return a reference to the layer called "name".  | |
| Layer & | GetLayer (std::size_t index) | 
| Return a reference to the layer at position "index" in the layers list.  | |
| const Layer & | GetLayer (std::size_t index) const | 
| Return a reference to the layer at position "index" in the layers list.  | |
| std::size_t | GetLayerPosition (const gd::String &name) const | 
| Return the position of the layer called "name" in the layers list.  | |
| std::size_t | GetLayersCount () const | 
| void | InsertNewLayer (const gd::String &name, std::size_t position) | 
| void | InsertLayer (const Layer &theLayer, std::size_t position) | 
| void | RemoveLayer (const gd::String &name) | 
| void | SwapLayers (std::size_t firstLayerIndex, std::size_t secondLayerIndex) | 
| void | MoveLayer (std::size_t oldIndex, std::size_t newIndex) | 
| void | Reset () | 
| void | SerializeLayersTo (SerializerElement &element) const | 
| Serialize the layers.  | |
| void | UnserializeLayersFrom (const SerializerElement &element) | 
| Unserialize the layers.  | |
Contains the layers for a scene or a custom object.
| std::size_t gd::LayersContainer::GetLayersCount | ( | ) | const | 
The number of layers.
| void gd::LayersContainer::InsertLayer | ( | const Layer & | theLayer, | 
| std::size_t | position | ||
| ) | 
Add a new layer constructed from the layer passed as parameter.
| theLayer | The layer that must be copied and inserted. | 
| position | Insertion position. | 
| void gd::LayersContainer::InsertNewLayer | ( | const gd::String & | name, | 
| std::size_t | position | ||
| ) | 
Add a new empty the layer sheet called "name" at the specified position in the layers list.
| void gd::LayersContainer::MoveLayer | ( | std::size_t | oldIndex, | 
| std::size_t | newIndex | ||
| ) | 
Change the position of the specified layer.
| void gd::LayersContainer::RemoveLayer | ( | const gd::String & | name | ) | 
Delete the layer named "name".
| void gd::LayersContainer::SwapLayers | ( | std::size_t | firstLayerIndex, | 
| std::size_t | secondLayerIndex | ||
| ) | 
Swap the position of the specified layers.