_________ __ __
/ _____// |_____________ _/ |______ ____ __ __ ______
\_____ \\ __\_ __ \__ \\ __\__ \ / ___\| | \/ ___/
/ \| | | | \// __ \| | / __ \_/ /_/ > | /\___ \
/_______ /|__| |__| (____ /__| (____ /\___ /|____//____ >
\/ \/ \//_____/ \/
______________________ ______________________
T H E W A R B E G I N S
Stratagus - A free fantasy real time strategy game engine
#include "stratagus.h"#include "unit.h"#include "iolib.h"#include "script.h"#include "unit_manager.h"#include "unittype.h"Classes | |
| class | CUnitGroup |
groups.cpp - The units' groups handling. | |
| #define | NUM_GROUPS 10 |
| static CUnitGroup | Groups [NUM_GROUPS] |
| group of units More... | |
| void | SaveGroups (CFile &file) |
| Number of groups predefined. More... | |
| void | CleanGroups () |
| Cleanup groups. More... | |
| bool | IsGroupTainted (int num) |
| const std::vector< CUnit * > & | GetUnitsOfGroup (int num) |
| Get the array of units of a particular group. More... | |
| void | ClearGroup (int num) |
| Remove all units from a group. More... | |
| void | AddToGroup (CUnit **units, unsigned int nunits, int num) |
| Add the array of units to the group. More... | |
| void | SetGroup (CUnit **units, unsigned int nunits, int num) |
| Set the contents of a particular group with an array of units. More... | |
| void | RemoveUnitFromGroups (CUnit &unit) |
| Remove a unit from a group. More... | |
| static int | CclGroup (lua_State *l) |
| void | GroupCclRegister () |
| Register CCL group features. More... | |
| #define NUM_GROUPS 10 |
How many groups supported
Add the array of units to the group.
Add units to group num contents from unit array "units"
| units | Array of units to place into group. |
| nunits | Number of units in array. |
| num | Group number for storage. |
|
static |
Define the group.
| l | Lua state. |
| void CleanGroups | ( | ) |
Cleanup groups.
Clean up group part.
| void ClearGroup | ( | int | num | ) |
Remove all units from a group.
Clear contents of group num
| num | Group number. |
| const std::vector<CUnit *>& GetUnitsOfGroup | ( | int | num | ) |
Get the array of units of a particular group.
Return the units of group num
| num | Group number. |
| void GroupCclRegister | ( | ) |
Register CCL group features.
Register CCL features for groups.
| bool IsGroupTainted | ( | int | num | ) |
Remove a unit from a group.
Remove unit from its groups
| unit | Unit to remove from group. |
Number of groups predefined.
Save groups.
Save groups.
| file | Output file. |
Set the contents of a particular group with an array of units.
Set group num contents to unit array "units"
| units | Array of units to place into group. |
| nunits | Number of units in array. |
| num | Group number for storage. |
|
static |
group of units
1.8.17
(C) Copyright 1998-2012 by The Stratagus Project under the GNU General Public License.