FairyGUI导出XLua接口

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/mingtingjian/article/details/62046909

因为这块比较简单,根据XLua的文档可以直接导出。

为了省事我就写完这个导出Wrap的代码。

using System.Collections.Generic;
using System;
using UnityEngine;
using XLua;
using FairyGUI;
/// <summary>
/// Fariry导出XLua接口
/// </summary>
public static class FairyGUIToXLuaConfig {
	[LuaCallCSharp]
	public static List<Type> LuaCallCSharp = new List<Type>() {
		(typeof(EventContext)),
		(typeof(EventDispatcher)),
		(typeof(EventListener)),
		(typeof(InputEvent)),
		(typeof(DisplayObject)),
		(typeof(Container)),
		(typeof(Stage)),
		(typeof(Controller)),
		(typeof(GObject)),
		(typeof(GGraph)),
		(typeof(GGroup)),
		(typeof(GImage)),
		(typeof(GLoader)),
		(typeof(PlayState)),
		(typeof(GMovieClip)),
		(typeof(TextFormat)),
		(typeof(GTextField)),
		(typeof(GRichTextField)),
		(typeof(GTextInput)),
		(typeof(GComponent)),
		(typeof(GList)),
		(typeof(GRoot)),
		(typeof(GLabel)),
		(typeof(GButton)),
		(typeof(GComboBox)),
		(typeof(GProgressBar)),
		(typeof(GSlider)),
		(typeof(PopupMenu)),
		(typeof(ScrollPane)),
		(typeof(Transition)),
		(typeof(UIPackage)),
		(typeof(Window)),
		(typeof(GObjectPool)),
		(typeof(Relations)),
		(typeof(RelationType)),
	};
}

之前有朋友询问是否有xlua结合fairygui的demo,现提供一个简单的demo。

链接:http://pan.baidu.com/s/1miNwUWK  密码:gy4t

demo运行环境为unity5.6.1,使用了CatLib框架做容器,鉴于catlib还没有发布正式版,我使用的是开发版,最终会和正式版有出入(PS:宣传一下,有参与贡献哟GITHUB:https://github.com/CatLib/CatLib)

xlua + fairyGUI + catlib

没有更多推荐了,返回首页