The Battle for Wesnoth  1.15.1+dev
Namespaces | Functions | Variables
lua_race.cpp File Reference
#include "scripting/lua_race.hpp"
#include "units/race.hpp"
#include "scripting/lua_common.hpp"
#include "units/types.hpp"
#include <string>
#include <cstring>
#include "lua/lua.h"
#include "lua/lauxlib.h"
Include dependency graph for lua_race.cpp:

Go to the source code of this file.

Namespaces

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

Functions

static int impl_race_get (lua_State *L)
 Gets some data on a race (__index metamethod). More...
 
std::string lua_race::register_metatable (lua_State *L)
 
void luaW_pushrace (lua_State *L, const unit_race &race)
 
void luaW_pushracetable (lua_State *L)
 

Variables

static const char * Race = "race"
 Implementation for a lua reference to a race, used by the wesnoth in-game races table. More...
 
static const char * Gen = "name generator"
 

Function Documentation

◆ impl_race_get()

static int impl_race_get ( lua_State L)
static

◆ luaW_pushrace()

void luaW_pushrace ( lua_State L,
const unit_race race 
)

◆ luaW_pushracetable()

void luaW_pushracetable ( lua_State L)

Variable Documentation

◆ Gen

const char* Gen = "name generator"
static

Definition at line 34 of file lua_race.cpp.

Referenced by impl_race_get().

◆ Race

const char* Race = "race"
static

Implementation for a lua reference to a race, used by the wesnoth in-game races table.

Definition at line 33 of file lua_race.cpp.

Referenced by luaW_pushrace(), and lua_race::register_metatable().