当前位置:网站首页>Fgui project packaging and Publishing & importing unity & the way to display the UI
Fgui project packaging and Publishing & importing unity & the way to display the UI
2022-07-06 12:57:00 【SQ Liu】
FGUI Project package release & Import Unity& take UI Show the way
One 、 Package and publish project




Two 、Unity Running display in UI Two ways
Preface : If there is no previous Download FairyGUI, You can download it in the resource store and import it .

(1) Manually add , No code required



terms of settlement :


(2) Code control display


using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using FairyGUI;
public class FGUITest001 : MonoBehaviour
{
void Start()
{
GRoot.inst.SetContentScaleFactor(800, 600); // Initialize and set the appropriate proportion ( The resolution is set )
UIPackage.AddPackage("FGUI/Package1"); // Load the packaged project
GComponent component = UIPackage.CreateObject("Package1", "Component1").asCom;
// Load the corresponding component adopt .asCom( or as GComponent) Type conversion converts it to GComponent Component type
GRoot.inst.AddChild(component); // Instantiate the current component to UI Panel(GRoot It's actually UI Panel) Below
}
}
thus , Complete .
边栏推荐
- Compilation principle: preprocessing of source program and design and implementation of lexical analysis program (including code)
- Unity3d camera, the keyboard controls the front and rear left and right up and down movement, and the mouse controls the rotation, zoom in and out
- Sharing ideas of on-chip transplantation based on rtklib source code
- MySQL error warning: a long semaphore wait
- Fairygui joystick
- 【RTKLIB 2.4.3 b34 】版本更新简介一
- (the first set of course design) sub task 1-5 317 (100 points) (dijkstra: heavy edge self loop)
- Programming homework: educational administration management system (C language)
- KF UD decomposition pseudo code implementation advanced [2]
- GPS高程拟合抗差中误差的求取代码实现
猜你喜欢

Unity3D基础入门之粒子系统(属性介绍+火焰粒子系统案例制作)
![[算法] 剑指offer2 golang 面试题4:只出现一次的数字](/img/f7/23ffc81ec8e9161c15d863c1a67916.png)
[算法] 剑指offer2 golang 面试题4:只出现一次的数字

FairyGUI增益BUFF数值改变的显示
![[untitled]](/img/b1/9a2bebebb24132a405fc4e7d854e51.png)
[untitled]
![[算法] 剑指offer2 golang 面试题2:二进制加法](/img/c2/6f6c3bd4d70252ba73addad6a3a9c1.png)
[算法] 剑指offer2 golang 面试题2:二进制加法
![[algorithm] sword finger offer2 golang interview question 6: sum of two numbers in the sorting array](/img/d5/4bda133498f71ae9fd7a64c6cba8f0.png)
[algorithm] sword finger offer2 golang interview question 6: sum of two numbers in the sorting array
![[算法] 剑指offer2 golang 面试题8:和大于或等于k的最短子数组](/img/8c/1b6ba3b1830ad28176190170c98628.png)
[算法] 剑指offer2 golang 面试题8:和大于或等于k的最短子数组

Halcon knowledge: gray_ Tophat transform and bottom cap transform

闇の連鎖(LCA+树上差分)

Easy to use shortcut keys in idea
随机推荐
Unity3d, Alibaba cloud server, platform configuration
MySQL error warning: a long semaphore wait
FairyGUI增益BUFF数值改变的显示
VLSM variable length subnet mask partition tips
What are the functions and features of helm or terrain
Unity3D摄像机,键盘控制前后左右上下移动,鼠标控制旋转、放缩
Compile GDAL source code with nmake (win10, vs2022)
记录:下一不小心写了个递归
C programming exercise
GNSS定位精度指标计算
PRIDE-PPPAR源码解析
染色法判定二分图
[算法] 剑指offer2 golang 面试题4:只出现一次的数字
Sharing ideas of on-chip transplantation based on rtklib source code
FairyGUI簡單背包的制作
[算法] 剑指offer2 golang 面试题12:左右两边子数组的和相等
The service robots that have been hyped by capital and the Winter Olympics are not just a flash in the pan
Teach you to release a DeNO module hand in hand
Design and implementation of general interface open platform - (39) simple and crude implementation of API services
GNSS positioning accuracy index calculation