当前位置:网站首页>Unity tool Luban learning notes 1
Unity tool Luban learning notes 1
2022-07-03 04:54:00 【Nian, Xiaoyu】
This article is for personal note only
Luban GitHub Address
Study of the Treasure fish video and luban Using document

Start game environment configuration
1、 establish unity The project
2、 Put this (luban_examples-main\Projects\Csharp_Unity_json\Assets\LubanLib) Folder LubanLib Copy to Engineering Assets Under the table of contents 
3、 Create a folder in the project root directory to store Luban Configure what you need 
4、 hold luban_examples-main In the catalog MiniDesignerConfigsTemplate Copy the folder to the newly created Luban Directory ( I am renaming to Config 了 )
5、 Make a random copy of bat File to Luban Directory , And input the content to save ( Name to gen_code_json.bat)
set WORKSPACE=..
set GEN_CLIENT=%WORKSPACE%\Luban\Luban.ClientServer\Luban.ClientServer.exe
set CONF_ROOT=%WORKSPACE%\Luban\Config
%GEN_CLIENT% -j cfg --^
-d %CONF_ROOT%\Defines\__root__.xml ^
--input_data_dir %CONF_ROOT%\Datas ^
--output_code_dir %WORKSPACE%/Assets/Gen ^
--output_data_dir ..\GenerateDatas\json ^
--gen_types code_cs_unity_json,data_json ^
-s all
pause
6、 open item.xlsx file (\Luban\Config\Datas\item.xlsx), And casually add a paragraph 
7、 Double-click on the run gen_code_json.bat I can generate , If you're wrong, watch the video and learn again .
8、 View the generated files , There's a json file , Open it and you can see 
7、 open unity Create test scripts Luban_Test, And write content
using System.IO;
using cfg;
using cfg.item;
using cfg.MyBean;
using SimpleJSON;
using UnityEngine;
public class Luban_Test : MonoBehaviour
{
void Start()
{
Tables table = new Tables(Loader); // initialization
Item item = table.TbItem.Get(10010);
Debug.Log($"{
item.Name} {
item.Desc}");
}
private JSONNode Loader(string fileName)
{
Debug.Log(fileName);
return JSON.Parse(File.ReadAllText(Application.dataPath + "/../GenerateDatas/json/" + fileName + ".json"));
}
}
Luban Catalog :
This case is over .
边栏推荐
- Without 50W bride price, my girlfriend was forcibly dragged away. What should I do
- Apache MPM model and ab stress test
- Leetcode simple question: check whether the array is sorted and rotated
- Learning record of arouter principle
- Handler understands the record
- General undergraduate college life pit avoidance Guide
- Leetcode simple problem delete an element to strictly increment the array
- Network security textual research recommendation
- Career planning of counter attacking College Students
- Market status and development prospect prediction of the global fire hose industry in 2022
猜你喜欢
![[set theory] relational representation (relational matrix | examples of relational matrix | properties of relational matrix | operations of relational matrix | relational graph | examples of relationa](/img/a9/92059db74ccde03b84c69dfce35b37.jpg)
[set theory] relational representation (relational matrix | examples of relational matrix | properties of relational matrix | operations of relational matrix | relational graph | examples of relationa

【工具跑SQL盲注】

I stepped on a foundation pit today

ZABBIX monitoring of lamp architecture (3): zabbix+mysql (to be continued)

论文阅读_ICD编码_MSMN

Do you know UVs in modeling?

Learn to use the idea breakpoint debugging tool

2022 registration examination for safety production management personnel of hazardous chemical production units and examination skills for safety production management personnel of hazardous chemical
![[set theory] relation properties (reflexivity | reflexivity theorem | reflexivity | reflexivity theorem | example)](/img/2a/362f3b0491f721d89336d4f468c9dd.jpg)
[set theory] relation properties (reflexivity | reflexivity theorem | reflexivity | reflexivity theorem | example)

SSM framework integration
随机推荐
并发操作-内存交互操作
Problems encountered in fuzzy query of SQL statements
Number of 1 in binary (simple difficulty)
Mount NFS in kubesphere
On typescript and grammar
[research materials] 2021 China's game industry brand report - Download attached
[research materials] 2021 annual report on mergers and acquisitions in the property management industry - Download attached
Blog building tool recommendation (text book delivery)
First + only! Alibaba cloud's real-time computing version of Flink passed the stability test of big data products of the Institute of ICT
Games101 Lesson 9 shading 3 Notes
C primre plus Chapter 10 question 6 inverted array
2022 chemical automation control instrument examination summary and chemical automation control instrument certificate examination
Current market situation and development prospect prediction of global direct energy deposition 3D printer industry in 2022
Without 50W bride price, my girlfriend was forcibly dragged away. What should I do
Thesis reading_ Chinese medical model_ eHealth
Pyqt control part (II)
Source insight garbled code solution
【工具跑SQL盲注】
Web security - CSRF (token)
Flutter monitors volume to realize waveform visualization of audio