赞
踩
1.安装2018.3以上Unity版本创建并打开一个项目
2.下载UIWidgets插件,放入和Assets同级目录的Packages文件夹下。
下载连接:
github:https://github.com/UnityTech/UIWidgets.git
gitee: https://gitee.com/lucasmark/UIWidgets (推荐这个,比GitHub下载快,但是这个是2020-7-1的版本,以后如有更新,建议用github连接)
3.场景里面创建一个canvas,并在canvas上新建一个脚本。
4.打开新建脚本,将继承的MonoBehaviour改成继承UIWidgetsPanel,重写createWidget,createWidget里面就可以开始写你的页面了,
我的代码如下:
using System.Collections.Generic;
using Unity.UIWidgets.engine;
using Unity.UIWidgets.widgets;
using Unity.UIWidgets.painting;
using Unity.UIWidgets.material;
using UnityEngine;
using Unity.UIWidgets.foundation;
public class unity_Flutter : UIWidgetsPanel
{
protected
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。