Commit de7daad9 authored by nanahira's avatar nanahira

format

parent aa44b443
......@@ -335,13 +335,11 @@ static const struct luaL_Reg effectlib[] = {
};
static const struct luaL_Reg grouplib[] = {
//metatable
{ "__add", scriptlib::group_meta_add },
{ "__bor", scriptlib::group_meta_add },
{ "__sub", scriptlib::group_meta_sub },
{ "__band", scriptlib::group_meta_band },
{ "__bxor", scriptlib::group_meta_bxor },
{ "CreateGroup", scriptlib::group_new },
{ "KeepAlive", scriptlib::group_keep_alive },
{ "DeleteGroup", scriptlib::group_delete },
......
......@@ -11,8 +11,6 @@
#include "effect.h"
#include "duel.h"
//metatables
//metatable functions
int32 scriptlib::group_meta_add(lua_State* L) {
check_param_count(L, 2);
if(!check_param(L, PARAM_TYPE_CARD, 1, TRUE) && !check_param(L, PARAM_TYPE_GROUP, 1, TRUE))
......@@ -130,7 +128,6 @@ int32 scriptlib::group_meta_bxor(lua_State* L) {
interpreter::group2value(L, pgroup);
return 1;
}
int32 scriptlib::group_new(lua_State *L) {
duel* pduel = interpreter::get_duel_info(L);
group* pgroup = pduel->new_group();
......
......@@ -35,12 +35,6 @@ public:
static int32 duel_move_turn_count(lua_State *L);
static int32 duel_get_cards_in_zone(lua_State *L);
static int32 duel_xyz_summon_by_rose(lua_State *L);
//metatable
static int32 group_meta_add(lua_State *L);
static int32 group_meta_sub(lua_State *L);
static int32 group_meta_band(lua_State *L);
static int32 group_meta_bxor(lua_State *L);
//card lib
static int32 card_get_code(lua_State *L);
static int32 card_get_origin_code(lua_State *L);
......@@ -593,6 +587,13 @@ public:
static int32 duel_venom_swamp_check(lua_State *L);
static int32 duel_swap_deck_and_grave(lua_State *L);
static int32 duel_majestic_copy(lua_State *L);
//group metamethods
//__len is in the group lib, which is same as group_get_count
static int32 group_meta_add(lua_State *L);
static int32 group_meta_sub(lua_State *L);
static int32 group_meta_band(lua_State *L);
static int32 group_meta_bxor(lua_State *L);
//preload
static int32 debug_message(lua_State *L);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment