示例#1
0
int lua_register_cocos2dx_ValueTypeJudgeInTable(lua_State* L)
{
    tolua_usertype(L,"cc.ValueTypeJudgeInTable");
    tolua_cclass(L,"ValueTypeJudgeInTable","cc.ValueTypeJudgeInTable","cc.Node",nullptr);
    
    tolua_beginmodule(L,"ValueTypeJudgeInTable");
        tolua_function(L,"create", lua_cocos2dx_ValueTypeJudgeInTable_create);
    tolua_endmodule(L);
    std::string typeName = typeid(cocos2d::ValueTypeJudgeInTable).name();
    g_luaType[typeName] = "cc.ValueTypeJudgeInTable";
    g_typeCast["ValueTypeJudgeInTable"] = "cc.ValueTypeJudgeInTable";
    return 1;
}
TOLUA_API int register_all_cocos2dx_spine(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,"sp",0);
	tolua_beginmodule(tolua_S,"sp");

	lua_register_cocos2dx_spine_Skeleton(tolua_S);
	lua_register_cocos2dx_spine_SkeletonAnimation(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}
示例#3
0
int lua_register_Enhance_Enhance(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"Enhance");
    tolua_cclass(tolua_S,"Enhance","Enhance","Entity",nullptr);

    tolua_beginmodule(tolua_S,"Enhance");
        tolua_function(tolua_S,"create", lua_Enhance_Enhance_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(Enhance).name();
    g_luaType[typeName] = "Enhance";
    g_typeCast["Enhance"] = "Enhance";
    return 1;
}
示例#4
0
void cManualBindings::BindWorld(lua_State * tolua_S)
{
	tolua_beginmodule(tolua_S, nullptr);
		tolua_beginmodule(tolua_S, "cWorld");
			tolua_function(tolua_S, "BroadcastParticleEffect",   tolua_cWorld_BroadcastParticleEffect);
			tolua_function(tolua_S, "ChunkStay",                 tolua_cWorld_ChunkStay);
			tolua_function(tolua_S, "DoWithBlockEntityAt",       DoWithXYZ<cWorld, cBlockEntity,        &cWorld::DoWithBlockEntityAt>);
			tolua_function(tolua_S, "DoWithBeaconAt",            DoWithXYZ<cWorld, cBeaconEntity,       &cWorld::DoWithBeaconAt>);
			tolua_function(tolua_S, "DoWithChestAt",             DoWithXYZ<cWorld, cChestEntity,        &cWorld::DoWithChestAt>);
			tolua_function(tolua_S, "DoWithDispenserAt",         DoWithXYZ<cWorld, cDispenserEntity,    &cWorld::DoWithDispenserAt>);
			tolua_function(tolua_S, "DoWithDropSpenserAt",       DoWithXYZ<cWorld, cDropSpenserEntity,  &cWorld::DoWithDropSpenserAt>);
			tolua_function(tolua_S, "DoWithDropperAt",           DoWithXYZ<cWorld, cDropperEntity,      &cWorld::DoWithDropperAt>);
			tolua_function(tolua_S, "DoWithEntityByID",          DoWithID< cWorld, cEntity,             &cWorld::DoWithEntityByID>);
			tolua_function(tolua_S, "DoWithFurnaceAt",           DoWithXYZ<cWorld, cFurnaceEntity,      &cWorld::DoWithFurnaceAt>);
			tolua_function(tolua_S, "DoWithNoteBlockAt",         DoWithXYZ<cWorld, cNoteEntity,         &cWorld::DoWithNoteBlockAt>);
			tolua_function(tolua_S, "DoWithCommandBlockAt",      DoWithXYZ<cWorld, cCommandBlockEntity, &cWorld::DoWithCommandBlockAt>);
			tolua_function(tolua_S, "DoWithMobHeadAt",           DoWithXYZ<cWorld, cMobHeadEntity,      &cWorld::DoWithMobHeadAt>);
			tolua_function(tolua_S, "DoWithFlowerPotAt",         DoWithXYZ<cWorld, cFlowerPotEntity,    &cWorld::DoWithFlowerPotAt>);
			tolua_function(tolua_S, "DoWithPlayer",              DoWith<   cWorld, cPlayer,             &cWorld::DoWithPlayer>);
			tolua_function(tolua_S, "FindAndDoWithPlayer",       DoWith<   cWorld, cPlayer,             &cWorld::FindAndDoWithPlayer>);
			tolua_function(tolua_S, "DoWithPlayerByUUID",        DoWith<   cWorld, cPlayer,             &cWorld::DoWithPlayerByUUID>);
			tolua_function(tolua_S, "ForEachBlockEntityInChunk", ForEachInChunk<cWorld, cBlockEntity,   &cWorld::ForEachBlockEntityInChunk>);
			tolua_function(tolua_S, "ForEachChestInChunk",       ForEachInChunk<cWorld, cChestEntity,   &cWorld::ForEachChestInChunk>);
			tolua_function(tolua_S, "ForEachEntity",             ForEach<       cWorld, cEntity,        &cWorld::ForEachEntity>);
			tolua_function(tolua_S, "ForEachEntityInBox",        ForEachInBox<  cWorld, cEntity,        &cWorld::ForEachEntityInBox>);
			tolua_function(tolua_S, "ForEachEntityInChunk",      ForEachInChunk<cWorld, cEntity,        &cWorld::ForEachEntityInChunk>);
			tolua_function(tolua_S, "ForEachFurnaceInChunk",     ForEachInChunk<cWorld, cFurnaceEntity, &cWorld::ForEachFurnaceInChunk>);
			tolua_function(tolua_S, "ForEachPlayer",             ForEach<       cWorld, cPlayer,        &cWorld::ForEachPlayer>);
			tolua_function(tolua_S, "GetBlockInfo",              tolua_cWorld_GetBlockInfo);
			tolua_function(tolua_S, "GetBlockTypeMeta",          tolua_cWorld_GetBlockTypeMeta);
			tolua_function(tolua_S, "GetSignLines",              tolua_cWorld_GetSignLines);
			tolua_function(tolua_S, "PrepareChunk",              tolua_cWorld_PrepareChunk);
			tolua_function(tolua_S, "QueueTask",                 tolua_cWorld_QueueTask);
			tolua_function(tolua_S, "ScheduleTask",              tolua_cWorld_ScheduleTask);
			tolua_function(tolua_S, "SetSignLines",              tolua_cWorld_SetSignLines);
			tolua_function(tolua_S, "TryGetHeight",              tolua_cWorld_TryGetHeight);
		tolua_endmodule(tolua_S);
	tolua_endmodule(tolua_S);
}
示例#5
0
int tolua_ftk_fs_init(lua_State* L)
{
	tolua_open(L);
	tolua_reg_types(L);
	tolua_module(L, NULL, 0);
	tolua_beginmodule(L, NULL);
	tolua_cclass(L,"FtkFs", "FtkFs", "", NULL);
	tolua_beginmodule(L, "FtkFs");
	tolua_function(L, "Delete", lua_ftk_fs_delete);
	tolua_function(L, "DeleteDir", lua_ftk_fs_delete_dir);
	tolua_function(L, "DeleteFile", lua_ftk_fs_delete_file);
	tolua_function(L, "CreateDir", lua_ftk_fs_create_dir);
	tolua_function(L, "ChangeDir", lua_ftk_fs_change_dir);
	tolua_function(L, "Move", lua_ftk_fs_move);
	tolua_function(L, "Copy", lua_ftk_fs_copy);
	tolua_function(L, "IsRoot", lua_ftk_fs_is_root);
	tolua_endmodule(L);
	tolua_endmodule(L);


	return 1;
}
int lua_register_Blur_Action_BloomUp(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"BloomUp");
    tolua_cclass(tolua_S,"BloomUp","BloomUp","cc.ActionInterval",nullptr);

    tolua_beginmodule(tolua_S,"BloomUp");
        tolua_function(tolua_S,"create", lua_Blur_Action_BloomUp_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(BloomUp).name();
    g_luaType[typeName] = "BloomUp";
    g_typeCast["BloomUp"] = "BloomUp";
    return 1;
}
int lua_register_cocos2dx_audioengine_AudioProfile(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"ccexp.AudioProfile");
    tolua_cclass(tolua_S,"AudioProfile","ccexp.AudioProfile","",nullptr);

    tolua_beginmodule(tolua_S,"AudioProfile");
        tolua_function(tolua_S,"new",lua_cocos2dx_audioengine_AudioProfile_constructor);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(cocos2d::experimental::AudioProfile).name();
    g_luaType[typeName] = "ccexp.AudioProfile";
    g_typeCast["AudioProfile"] = "ccexp.AudioProfile";
    return 1;
}
TOLUA_API int register_all_cocos2dx_audioengine(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,"ccexp",0);
	tolua_beginmodule(tolua_S,"ccexp");

	lua_register_cocos2dx_audioengine_AudioProfile(tolua_S);
	lua_register_cocos2dx_audioengine_AudioEngine(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}
int lua_register_Blur_Action_RedFilter(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"RedFilter");
    tolua_cclass(tolua_S,"RedFilter","RedFilter","cc.ActionInterval",nullptr);

    tolua_beginmodule(tolua_S,"RedFilter");
        tolua_function(tolua_S,"create", lua_Blur_Action_RedFilter_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(RedFilter).name();
    g_luaType[typeName] = "RedFilter";
    g_typeCast["RedFilter"] = "RedFilter";
    return 1;
}
TOLUA_API int register_all_cocos2dx_experimental(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,"ccexp",0);
	tolua_beginmodule(tolua_S,"ccexp");

	lua_register_cocos2dx_experimental_TMXTiledMap(tolua_S);
	lua_register_cocos2dx_experimental_TMXLayer(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}
int lua_register_GameShareButton_GameShareButton(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"bs.GameShareButton");
    tolua_cclass(tolua_S,"GameShareButton","bs.GameShareButton","cc.Node",nullptr);

    tolua_beginmodule(tolua_S,"GameShareButton");
        tolua_function(tolua_S,"create", lua_GameShareButton_GameShareButton_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(bubble_second::GameShareButton).name();
    g_luaType[typeName] = "bs.GameShareButton";
    g_typeCast["GameShareButton"] = "bs.GameShareButton";
    return 1;
}
示例#12
0
void tolua_building_open(lua_State * L)
{
    /* register user types */
    tolua_usertype(L, TOLUA_CAST "building");

    tolua_module(L, NULL, 0);
    tolua_beginmodule(L, NULL);
    {
        tolua_cclass(L, TOLUA_CAST "building", TOLUA_CAST "building", TOLUA_CAST "",
            NULL);
        tolua_beginmodule(L, TOLUA_CAST "building");
        {
            tolua_function(L, TOLUA_CAST "create", tolua_building_create);
            tolua_function(L, TOLUA_CAST "destroy", tolua_building_destroy);
            tolua_function(L, TOLUA_CAST "__tostring", tolua_building_tostring);

            tolua_variable(L, TOLUA_CAST "id", tolua_building_get_id, NULL);
            tolua_variable(L, TOLUA_CAST "owner", tolua_building_get_owner,
                tolua_building_set_owner);
            tolua_variable(L, TOLUA_CAST "type", tolua_building_get_type, NULL);
            tolua_variable(L, TOLUA_CAST "name", tolua_building_get_name,
                tolua_building_set_name);
            tolua_variable(L, TOLUA_CAST "info", tolua_building_get_info,
                tolua_building_set_info);
            tolua_variable(L, TOLUA_CAST "units", tolua_building_get_units, NULL);
            tolua_variable(L, TOLUA_CAST "region", tolua_building_get_region,
                tolua_building_set_region);
            tolua_variable(L, TOLUA_CAST "size", tolua_building_get_size,
                tolua_building_set_size);
            tolua_function(L, TOLUA_CAST "get_typename", tolua_building_get_typename);
            tolua_variable(L, TOLUA_CAST "objects", tolua_building_get_objects, 0);
            tolua_variable(L, TOLUA_CAST "working", tolua_building_get_working, tolua_building_set_working);

        }
        tolua_endmodule(L);
    }
    tolua_endmodule(L);
}
示例#13
0
int lua_register_cocos2dx_tui_TuiUtil(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"tui.TuiUtil");
    tolua_cclass(tolua_S,"TuiUtil","tui.TuiUtil","",nullptr);

    tolua_beginmodule(tolua_S,"TuiUtil");
        tolua_function(tolua_S,"createAnimWithName", lua_cocos2dx_tui_TuiUtil_createAnimWithName);
        tolua_function(tolua_S,"createAnimWithNameAndNum", lua_cocos2dx_tui_TuiUtil_createAnimWithNameAndNum);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(cocos2d::tui::TuiUtil).name();
    g_luaType[typeName] = "tui.TuiUtil";
    g_typeCast["TuiUtil"] = "tui.TuiUtil";
    return 1;
}
//打开Dialog库
int  game_client_tree_open(lua_State* L)
{
	tolua_open(L);
	game_client_tree_reg_types(L);
	tolua_module(L,NULL,0);
	tolua_beginmodule(L,NULL);
	{
		tolua_module(L,"Game",0);
		tolua_beginmodule(L,"Game");
		{
			tolua_cclass(L,"GameClientTree","CTreeGameClient","",NULL);
			tolua_beginmodule(L,"GameClientTree");
			{
				tolua_function(L,"insert_client_item",	game_client_tree_insert_client_item);
				tolua_function(L,"delete_client_item",	game_client_tree_delete_client_item);
			}
			tolua_endmodule(L);
		}
		tolua_endmodule(L);
	}
	tolua_endmodule(L);
	return 1;
}
int lua_register_GameLotteryAwardItem_GameLotteryAwardItem(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"bs.GameLotteryAwardItem");
    tolua_cclass(tolua_S,"GameLotteryAwardItem","bs.GameLotteryAwardItem","cc.Node",nullptr);

    tolua_beginmodule(tolua_S,"GameLotteryAwardItem");
        tolua_function(tolua_S,"getAwardSprite",lua_GameLotteryAwardItem_GameLotteryAwardItem_getAwardSprite);
        tolua_function(tolua_S,"create", lua_GameLotteryAwardItem_GameLotteryAwardItem_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(bubble_second::GameLotteryAwardItem).name();
    g_luaType[typeName] = "bs.GameLotteryAwardItem";
    g_typeCast["GameLotteryAwardItem"] = "bs.GameLotteryAwardItem";
    return 1;
}
TOLUA_API int register_all_cocos2dx_controller(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,"cc",0);
	tolua_beginmodule(tolua_S,"cc");

	lua_register_cocos2dx_controller_EventListenerController(tolua_S);
	lua_register_cocos2dx_controller_Controller(tolua_S);
	lua_register_cocos2dx_controller_EventController(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}
int lua_register_qt_Cocos2dxBridge(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"Cocos2dxBridge");
    tolua_cclass(tolua_S,"Cocos2dxBridge","Cocos2dxBridge","",nullptr);

    tolua_beginmodule(tolua_S,"Cocos2dxBridge");
        tolua_function(tolua_S,"cocos2dxEvent",lua_qt_Cocos2dxBridge_cocos2dxEvent);
        tolua_function(tolua_S,"getInstance", lua_qt_Cocos2dxBridge_getInstance);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(Cocos2dxBridge).name();
    g_luaType[typeName] = "Cocos2dxBridge";
    g_typeCast["Cocos2dxBridge"] = "Cocos2dxBridge";
    return 1;
}
示例#18
0
int tolua_ftk_sprite_init(lua_State* L)
{
	tolua_open(L);
	tolua_reg_types(L);
	tolua_module(L, NULL, 0);
	tolua_beginmodule(L, NULL);
	tolua_cclass(L,"FtkSprite", "FtkSprite", "", NULL);
	tolua_beginmodule(L, "FtkSprite");
	tolua_function(L, "Create", lua_ftk_sprite_create);
	tolua_function(L, "GetX", lua_ftk_sprite_get_x);
	tolua_function(L, "GetY", lua_ftk_sprite_get_y);
	tolua_function(L, "IsVisible", lua_ftk_sprite_is_visible);
	tolua_function(L, "Show", lua_ftk_sprite_show);
	tolua_function(L, "Move", lua_ftk_sprite_move);
	tolua_function(L, "SetIcon", lua_ftk_sprite_set_icon);
	tolua_function(L, "SetMoveListener", lua_ftk_sprite_set_move_listener);
	tolua_function(L, "Destroy", lua_ftk_sprite_destroy);
	tolua_endmodule(L);
	tolua_endmodule(L);


	return 1;
}
示例#19
0
TOLUA_API int register_all_cocos2dx_tui(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,nullptr,0);
	tolua_beginmodule(tolua_S,nullptr);

	lua_register_cocos2dx_tui_TuiBase(tolua_S);
	lua_register_cocos2dx_tui_TuiManager(tolua_S);
	lua_register_cocos2dx_tui_TuiUtil(tolua_S);

	tolua_endmodule(tolua_S);
	return 1;
}
示例#20
0
    // lua_reg
    int lua_reg_ActionEx(lua_State* L)
    {
        tolua_open(L);
        tolua_module(L, "ccex", 0);
        tolua_beginmodule(L, "ccex");

        lua_reg_ActionGroup(L);
        lua_reg_Sequence(L);
        lua_reg_Spawn(L);
        
        tolua_endmodule(L);

        return 1;
    }
TOLUA_API int register_all_PluginReviewLua(lua_State* tolua_S)
{
	tolua_open(tolua_S);
	
	tolua_module(tolua_S,"sdkbox",0);
	tolua_beginmodule(tolua_S,"sdkbox");

	lua_register_PluginReviewLua_PluginReview(tolua_S);

	tolua_endmodule(tolua_S);

	sdkbox::setProjectType("lua");
	return 1;
}
int lua_register_PluginBee7Lua_PluginBee7(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"sdkbox.PluginBee7");
    tolua_cclass(tolua_S,"PluginBee7","sdkbox.PluginBee7","",nullptr);

    tolua_beginmodule(tolua_S,"PluginBee7");
        tolua_function(tolua_S,"showGameWall", lua_PluginBee7Lua_PluginBee7_showGameWall);
        tolua_function(tolua_S,"init", lua_PluginBee7Lua_PluginBee7_init);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(sdkbox::PluginBee7).name();
    g_luaType[typeName] = "sdkbox.PluginBee7";
    g_typeCast["PluginBee7"] = "sdkbox.PluginBee7";
    return 1;
}
int lua_register_Blur_Action_SharpFilterAct(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"SharpFilterAct");
    tolua_cclass(tolua_S,"SharpFilterAct","SharpFilterAct","cc.ActionInterval",nullptr);

    tolua_beginmodule(tolua_S,"SharpFilterAct");
        tolua_function(tolua_S,"setShader",lua_Blur_Action_SharpFilterAct_setShader);
        tolua_function(tolua_S,"create", lua_Blur_Action_SharpFilterAct_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(SharpFilterAct).name();
    g_luaType[typeName] = "SharpFilterAct";
    g_typeCast["SharpFilterAct"] = "SharpFilterAct";
    return 1;
}
int lua_register_cocos2dx_mycustomclass_MyCustomClass(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"MyCustomClass");
    tolua_cclass(tolua_S,"MyCustomClass","MyCustomClass","",nullptr);

    tolua_beginmodule(tolua_S,"MyCustomClass");
        tolua_function(tolua_S,"new",lua_cocos2dx_mycustomclass_MyCustomClass_constructor);
        tolua_function(tolua_S,"addTest", lua_cocos2dx_mycustomclass_MyCustomClass_addTest);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(MyCustomClass).name();
    g_luaType[typeName] = "MyCustomClass";
    g_typeCast["MyCustomClass"] = "MyCustomClass";
    return 1;
}
示例#25
0
int lua_register_PluginTuneLua_PluginTune(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"sdkbox.PluginTune");
    tolua_cclass(tolua_S,"PluginTune","sdkbox.PluginTune","",nullptr);

    tolua_beginmodule(tolua_S,"PluginTune");
        tolua_function(tolua_S,"setUserName", lua_PluginTuneLua_PluginTune_setUserName);
        tolua_function(tolua_S,"setGoogleUserId", lua_PluginTuneLua_PluginTune_setGoogleUserId);
        tolua_function(tolua_S,"setFacebookEventLogging", lua_PluginTuneLua_PluginTune_setFacebookEventLogging);
        tolua_function(tolua_S,"measureSession", lua_PluginTuneLua_PluginTune_measureSession);
        tolua_function(tolua_S,"setAppAdTracking", lua_PluginTuneLua_PluginTune_setAppAdTracking);
        tolua_function(tolua_S,"setAppleAdvertisingIdentifier", lua_PluginTuneLua_PluginTune_setAppleAdvertisingIdentifier);
        tolua_function(tolua_S,"setPackageName", lua_PluginTuneLua_PluginTune_setPackageName);
        tolua_function(tolua_S,"setTRUSTeId", lua_PluginTuneLua_PluginTune_setTRUSTeId);
        tolua_function(tolua_S,"automateIapEventMeasurement", lua_PluginTuneLua_PluginTune_automateIapEventMeasurement);
        tolua_function(tolua_S,"setUseCookieTracking", lua_PluginTuneLua_PluginTune_setUseCookieTracking);
        tolua_function(tolua_S,"openLogId", lua_PluginTuneLua_PluginTune_openLogId);
        tolua_function(tolua_S,"setLatitude", lua_PluginTuneLua_PluginTune_setLatitude);
        tolua_function(tolua_S,"setAllowDuplicateRequests", lua_PluginTuneLua_PluginTune_setAllowDuplicateRequests);
        tolua_function(tolua_S,"setUserId", lua_PluginTuneLua_PluginTune_setUserId);
        tolua_function(tolua_S,"applicationDidOpenURL", lua_PluginTuneLua_PluginTune_applicationDidOpenURL);
        tolua_function(tolua_S,"setExistingUser", lua_PluginTuneLua_PluginTune_setExistingUser);
        tolua_function(tolua_S,"setShouldAutoDetectJailbroken", lua_PluginTuneLua_PluginTune_setShouldAutoDetectJailbroken);
        tolua_function(tolua_S,"init", lua_PluginTuneLua_PluginTune_init);
        tolua_function(tolua_S,"checkForDeferredDeepLink", lua_PluginTuneLua_PluginTune_checkForDeferredDeepLink);
        tolua_function(tolua_S,"setAppleVendorIdentifier", lua_PluginTuneLua_PluginTune_setAppleVendorIdentifier);
        tolua_function(tolua_S,"setGender", lua_PluginTuneLua_PluginTune_setGender);
        tolua_function(tolua_S,"setCurrencyCode", lua_PluginTuneLua_PluginTune_setCurrencyCode);
        tolua_function(tolua_S,"setJailbroken", lua_PluginTuneLua_PluginTune_setJailbroken);
        tolua_function(tolua_S,"startAppToAppTracking", lua_PluginTuneLua_PluginTune_startAppToAppTracking);
        tolua_function(tolua_S,"setAge", lua_PluginTuneLua_PluginTune_setAge);
        tolua_function(tolua_S,"setPhoneNumber", lua_PluginTuneLua_PluginTune_setPhoneNumber);
        tolua_function(tolua_S,"measureEventName", lua_PluginTuneLua_PluginTune_measureEventName);
        tolua_function(tolua_S,"setRedirectUrl", lua_PluginTuneLua_PluginTune_setRedirectUrl);
        tolua_function(tolua_S,"setShouldAutoGenerateAppleVendorIdentifier", lua_PluginTuneLua_PluginTune_setShouldAutoGenerateAppleVendorIdentifier);
        tolua_function(tolua_S,"isPayingUser", lua_PluginTuneLua_PluginTune_isPayingUser);
        tolua_function(tolua_S,"setUserEmail", lua_PluginTuneLua_PluginTune_setUserEmail);
        tolua_function(tolua_S,"setFacebookUserId", lua_PluginTuneLua_PluginTune_setFacebookUserId);
        tolua_function(tolua_S,"setTwitterUserId", lua_PluginTuneLua_PluginTune_setTwitterUserId);
        tolua_function(tolua_S,"tuneId", lua_PluginTuneLua_PluginTune_tuneId);
        tolua_function(tolua_S,"setDeepLink", lua_PluginTuneLua_PluginTune_setDeepLink);
        tolua_function(tolua_S,"measureEventId", lua_PluginTuneLua_PluginTune_measureEventId);
        tolua_function(tolua_S,"setPayingUser", lua_PluginTuneLua_PluginTune_setPayingUser);
        tolua_function(tolua_S,"setDebugMode", lua_PluginTuneLua_PluginTune_setDebugMode);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(sdkbox::PluginTune).name();
    g_luaType[typeName] = "sdkbox.PluginTune";
    g_typeCast["PluginTune"] = "sdkbox.PluginTune";
    return 1;
}
示例#26
0
int tolua_ftk_structs_init(lua_State* L)
{
	tolua_open(L);
	tolua_reg_types(L);
	tolua_module(L, NULL, 0);
	tolua_beginmodule(L, NULL);

	tolua_cclass(L, "FtkEvent", "FtkEvent", "", NULL);
	tolua_beginmodule(L, "FtkEvent");
	tolua_function(L, "Create", lua_ftk_event_create);
	tolua_variable(L, "type",tolua_get_FtkEvent_type, tolua_set_FtkEvent_type);
	tolua_variable(L, "widget",tolua_get_FtkEvent_widget, tolua_set_FtkEvent_widget);
	tolua_variable(L, "time",tolua_get_FtkEvent_time, tolua_set_FtkEvent_time);
	tolua_variable(L, "u_key_code",tolua_get_FtkEvent_u_key_code, tolua_set_FtkEvent_u_key_code);
	tolua_variable(L, "u_mouse_press",tolua_get_FtkEvent_u_mouse_press, tolua_set_FtkEvent_u_mouse_press);
	tolua_variable(L, "u_mouse_button",tolua_get_FtkEvent_u_mouse_button, tolua_set_FtkEvent_u_mouse_button);
	tolua_variable(L, "u_mouse_x",tolua_get_FtkEvent_u_mouse_x, tolua_set_FtkEvent_u_mouse_x);
	tolua_variable(L, "u_mouse_y",tolua_get_FtkEvent_u_mouse_y, tolua_set_FtkEvent_u_mouse_y);
	tolua_endmodule(L);
	
	tolua_cclass(L, "FtkGc", "FtkGc", "", NULL);
	tolua_beginmodule(L, "FtkGc");
	tolua_function(L, "Create", lua_ftk_gc_create);
	tolua_variable(L, "ref",tolua_get_FtkGc_ref, tolua_set_FtkGc_ref);
	tolua_variable(L, "mask",tolua_get_FtkGc_mask, tolua_set_FtkGc_mask);
	tolua_variable(L, "bg",tolua_get_FtkGc_bg, tolua_set_FtkGc_bg);
	tolua_variable(L, "fg",tolua_get_FtkGc_fg, tolua_set_FtkGc_fg);
	tolua_variable(L, "font",tolua_get_FtkGc_font, tolua_set_FtkGc_font);
	tolua_variable(L, "bitmap",tolua_get_FtkGc_bitmap, tolua_set_FtkGc_bitmap);
	tolua_variable(L, "alpha",tolua_get_FtkGc_alpha, tolua_set_FtkGc_alpha);
	tolua_variable(L, "line_mask",tolua_get_FtkGc_line_mask, tolua_set_FtkGc_line_mask);
	tolua_endmodule(L);
	
	tolua_endmodule(L);

	return 1;
}
int lua_register_cocos2dx_TDGAVirtualCurrency(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"TDGAVirtualCurrency");
    tolua_cclass(tolua_S,"TDGAVirtualCurrency","TDGAVirtualCurrency","",nullptr);

    tolua_beginmodule(tolua_S,"TDGAVirtualCurrency");
        tolua_function(tolua_S,"onChargeRequest", lua_cocos2dx_TDGAVirtualCurrency_onChargeRequest);
        tolua_function(tolua_S,"onReward", lua_cocos2dx_TDGAVirtualCurrency_onReward);
        tolua_function(tolua_S,"onChargeSuccess", lua_cocos2dx_TDGAVirtualCurrency_onChargeSuccess);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(TDCCVirtualCurrency).name();
    g_luaType[typeName] = "TDGAVirtualCurrency";
    g_typeCast["TDGAVirtualCurrency"] = "TDGAVirtualCurrency";
    return 1;
}
示例#28
0
int lua_register_PrintSTM_PrintSTM(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"PrintSTM");
    tolua_cclass(tolua_S,"PrintSTM","PrintSTM","cc.Ref",nullptr);

    tolua_beginmodule(tolua_S,"PrintSTM");
    tolua_function(tolua_S,"say",lua_PrintSTM_PrintSTM_say);
    tolua_function(tolua_S,"init",lua_PrintSTM_PrintSTM_init);
    tolua_function(tolua_S,"create", lua_PrintSTM_PrintSTM_create);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(PrintSTM).name();
    g_luaType[typeName] = "PrintSTM";
    g_typeCast["PrintSTM"] = "PrintSTM";
    return 1;
}
示例#29
0
/* Open function */
TOLUA_API int tolua_tfunction_open (lua_State* tolua_S)
{
 tolua_open(tolua_S);
 tolua_reg_types(tolua_S);
 tolua_module(tolua_S,NULL,0);
 tolua_beginmodule(tolua_S,NULL);
  #ifdef __cplusplus
  tolua_cclass(tolua_S,"Role","Role","",tolua_collect_Role);
  #else
  tolua_cclass(tolua_S,"Role","Role","",NULL);
  #endif
  tolua_beginmodule(tolua_S,"Role");
   tolua_function(tolua_S,"new",tolua_tfunction_Role_new00);
   tolua_function(tolua_S,"new_local",tolua_tfunction_Role_new00_local);
   tolua_function(tolua_S,".call",tolua_tfunction_Role_new00_local);
   tolua_function(tolua_S,"SetLV",tolua_tfunction_Role_SetLV00);
   tolua_function(tolua_S,"SetExp",tolua_tfunction_Role_SetExp00);
   tolua_function(tolua_S,"GetLV",tolua_tfunction_Role_GetLV00);
   tolua_function(tolua_S,"Change",tolua_tfunction_Role_Change00);
  tolua_endmodule(tolua_S);
  #ifdef __cplusplus
  tolua_cclass(tolua_S,"TestClass","TestClass","",tolua_collect_TestClass);
  #else
  tolua_cclass(tolua_S,"TestClass","TestClass","",NULL);
  #endif
  tolua_beginmodule(tolua_S,"TestClass");
   tolua_function(tolua_S,"new",tolua_tfunction_TestClass_new00);
   tolua_function(tolua_S,"new_local",tolua_tfunction_TestClass_new00_local);
   tolua_function(tolua_S,".call",tolua_tfunction_TestClass_new00_local);
   tolua_function(tolua_S,"delete",tolua_tfunction_TestClass_delete00);
   tolua_function(tolua_S,"LvAdd",tolua_tfunction_TestClass_LvAdd00);
   tolua_function(tolua_S,"MakeObj",tolua_tfunction_TestClass_MakeObj00);
  tolua_endmodule(tolua_S);
 tolua_endmodule(tolua_S);
 return 1;
}
int lua_register_PluginAgeCheqLua_PluginAgeCheq(lua_State* tolua_S)
{
    tolua_usertype(tolua_S,"sdkbox.PluginAgeCheq");
    tolua_cclass(tolua_S,"PluginAgeCheq","sdkbox.PluginAgeCheq","",nullptr);

    tolua_beginmodule(tolua_S,"PluginAgeCheq");
        tolua_function(tolua_S,"init", lua_PluginAgeCheqLua_PluginAgeCheq_init);
        tolua_function(tolua_S,"associateData", lua_PluginAgeCheqLua_PluginAgeCheq_associateData);
        tolua_function(tolua_S,"check", lua_PluginAgeCheqLua_PluginAgeCheq_check);
    tolua_endmodule(tolua_S);
    std::string typeName = typeid(sdkbox::PluginAgeCheq).name();
    g_luaType[typeName] = "sdkbox.PluginAgeCheq";
    g_typeCast["PluginAgeCheq"] = "sdkbox.PluginAgeCheq";
    return 1;
}