The Battle for Wesnoth  1.17.0-dev
Namespaces | Functions
lua_team.hpp File Reference
#include <string>
Include dependency graph for lua_team.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 lua_team
 This namespace contains bindings for lua to hold a pointer to a team, and to access and modify it.
 

Functions

std::string lua_team::register_metatable (lua_State *L)
 
void luaW_pushteam (lua_State *, team &)
 Create a full userdata containing a pointer to the team. More...
 
teamluaW_toteam (lua_State *, int)
 Test if the top stack element is a team, and if so, return it. More...
 
teamluaW_checkteam (lua_State *, int)
 Test if the top stack element is a team, and if not, error. More...
 
teamluaW_checkteam (lua_State *L, int idx, class game_board &board)
 Get a team either from a direct userdata or from a side number. More...
 

Function Documentation

◆ luaW_checkteam() [1/2]

team& luaW_checkteam ( lua_State ,
int   
)

◆ luaW_checkteam() [2/2]

team& luaW_checkteam ( lua_State L,
int  idx,
class game_board board 
)

Get a team either from a direct userdata or from a side number.

Definition at line 355 of file lua_team.cpp.

◆ luaW_pushteam()

void luaW_pushteam ( lua_State ,
team  
)

Create a full userdata containing a pointer to the team.

Definition at line 343 of file lua_team.cpp.

Referenced by game_lua_kernel::intf_get_side(), game_lua_kernel::intf_get_sides(), and game_lua_kernel::run_filter().

◆ luaW_toteam()

team* luaW_toteam ( lua_State ,
int   
)