Axmol Engine 2.4.0-258ceca
Loading...
Searching...
No Matches
TMXObjectGroup Class Reference

TMXObjectGroup represents the TMX object group. More...

#include <TMXObjectGroup.h>

Inherits Object.

Public Member Functions

 TMXObjectGroup ()
 @js ctor
 
virtual ~TMXObjectGroup ()
 @js NA @lua NA
 
std::string_view getGroupName () const
 Get the group name.
 
void setGroupName (std::string_view groupName)
 Set the group name.
 
Value getProperty (std::string_view propertyName) const
 Return the value for the specific property name.
 
ValueMap getObject (std::string_view objectName) const
 Return the dictionary for the specific object name.
 
const Vec2getPositionOffset () const
 Gets the offset position of child objects.
 
void setPositionOffset (const Vec2 &offset)
 Sets the offset position of child objects.
 
const ValueMap & getProperties () const
 Gets the list of properties stored in a dictionary.
 
void setProperties (const ValueMap &properties)
 Sets the list of properties.
 
const ValueVector & getObjects () const
 Gets the array of the objects.
 
void setObjects (const ValueVector &objects)
 Sets the array of the objects.
 
- Public Member Functions inherited from Object
void retain ()
 Retains the ownership.
 
void release ()
 Releases the ownership immediately.
 
Objectautorelease ()
 Releases the ownership sometime soon automatically.
 
unsigned int getReferenceCount () const
 Returns the Object's current reference count.
 
virtual ~Object ()
 Destructor.
 

Additional Inherited Members

- Public Attributes inherited from Object
unsigned int _ID
 object id, ScriptSupport need public _ID
 
int _luaID
 Lua reference id.
 

Detailed Description

TMXObjectGroup represents the TMX object group.

Since
v0.99.0

Member Function Documentation

◆ getGroupName()

std::string_view getGroupName ( ) const
inline

Get the group name.

Returns
The group name.

◆ setGroupName()

void setGroupName ( std::string_view groupName)
inline

Set the group name.

Parameters
groupNameA string,it is used to set the group name.

◆ getProperty()

Value getProperty ( std::string_view propertyName) const

Return the value for the specific property name.

Parameters
propertyNameThe specific property name.
Returns
Return the value for the specific property name. @js NA

◆ getObject()

ValueMap getObject ( std::string_view objectName) const

Return the dictionary for the specific object name.

It will return the 1st object found on the array for the given name.

Returns
Return the dictionary for the specific object name.

◆ getPositionOffset()

const Vec2 & getPositionOffset ( ) const
inline

Gets the offset position of child objects.

Returns
The offset position of child objects.

◆ setPositionOffset()

void setPositionOffset ( const Vec2 & offset)
inline

Sets the offset position of child objects.

Parameters
offsetThe offset position of child objects.

◆ getProperties()

const ValueMap & getProperties ( ) const
inline

Gets the list of properties stored in a dictionary.

Returns
The list of properties stored in a dictionary.

◆ setProperties()

void setProperties ( const ValueMap & properties)
inline

Sets the list of properties.

Parameters
propertiesThe list of properties.

◆ getObjects()

const ValueVector & getObjects ( ) const
inline

Gets the array of the objects.

Returns
The array of the objects.

◆ setObjects()

void setObjects ( const ValueVector & objects)
inline

Sets the array of the objects.

Parameters
objectsThe array of the objects.

The documentation for this class was generated from the following file: