密室逃脱模拟器

密室逃脱模拟器

31 个评价
Thoroniul's LUA Tutorial
   
奖励
收藏
已收藏
取消收藏
Type: Logics
Language: English
Themes: Other
文件大小
发表于
更新日期
57.464 MB
2022 年 5 月 18 日 下午 3:48
2023 年 1 月 3 日 下午 8:02
39 项改动说明 ( 查看 )

订阅以下载
Thoroniul's LUA Tutorial

描述
This room provides examples and code to build a working understanding on how to use the LUA editor.


Attributions
Enviroment metal/dielectric roughness test
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/MetalRoughSpheres
Ed Mackey
https://creativecommons.org/licenses/by/4.0/


Roughness Test
Ed Mackey
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/TransmissionRoughnessTest
https://creativecommons.org/licenses/by/4.0/

Transmission Test
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/TransmissionTest
https://creativecommons.org/publicdomain/zero/1.0/

Emission Test
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/EmissiveStrengthTest
Ed Mackey
https://creativecommons.org/licenses/by/4.0/

ClearCoat Test
Ed Mackey
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/ClearCoatTest
https://creativecommons.org/licenses/by/4.0/

Attentuation Test
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/AttenuationTest
https://creativecommons.org/licenses/by/4.0/

Toy Car
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/ToyCar
https://creativecommons.org/publicdomain/zero/1.0/

Mosquito in Amber
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/MosquitoInAmber
http://creativecommons.org/licenses/by/4.0/

Gram Velvet Sofa
https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/GlamVelvetSofa
https://creativecommons.org/licenses/by/4.0/

Crow Caw Sound
https://www.freesoundslibrary.com/crow-caw-sound/
https://creativecommons.org/licenses/by/4.0/

24 条留言
Thoroniul  [作者] 5 月 26 日 下午 5:39 
@Cpt. flint. Yes, this is possible. If you notice the eye, it always points at the object the viewer is looking at. There is also api.getMainPlayer(), api.getLocalPlayer(), api.getClosestPlayer(Vec3 pos) , Transform[] getAllPlayers(). To get access to different player situations.

https://docs.escapesimulator.com/docs/room-editor/lua-scripting

It is best to join the Pine discord channel for questions pertaining to lua. https://discord.com/channels/449578254433517578/974985136221335583
Captain Flint 5 月 26 日 下午 4:40 
This stuff is next level! Thank you!! I'm not sure if this is covered in the tutorial map, but is it possible to make a moving object track towards a player? I see player tracking is possible, But let's say I had an object that I wanted to move towards the player whatever direction the player is going. Any advice on where to start? Thank you!!
Ph0rx 2024 年 5 月 2 日 上午 5:04 
What happened to the "Rough Video" that was attached to this. I remember seeing some rotation code in there that I can't find anywhere else.
donnabeane57 2024 年 4 月 17 日 上午 4:38 
Thank you! This definitely gets me started!
Thoroniul  [作者] 2024 年 4 月 16 日 下午 6:21 
To copy just download the room into your own editor, and open the files in ugc.

For more information on lua, you could take a look at the wiki https://docs.escapesimulator.com/docs/room-editor/lua-scripting
donnabeane57 2024 年 4 月 16 日 上午 7:16 
Could you give me more information on copying? Where is the "workshop option"? if that means the workshop page where I edit my room, the only button there is <CREATE>. I noticed a sign somewhere in the tutorial that indicate I would need some prior knowledge. Could you tell me where to find what I will need to know? All I know about .lua is that it exists and seems to govern movement. I just published my first room. I want to do more and I know this will greatly increase my options for creating more interesting environments as well as possibly more creative puzzles. Please don't dismiss me on the grounds of my lack of knowledge. I am rather intuitive with code and have taught myself quite a bit simply by seeing examples of code and what they do, so I can learn this.
Lycos 2023 年 2 月 25 日 上午 11:14 
O my god, this i dident know. Thank you so much!
Thoroniul  [作者] 2023 年 2 月 24 日 下午 4:22 
In the top right corner of the workshop option there is a copy button. This copies the map folder into your own editor UGC enabling one to open the map in their own editor environment. One can open the map file and find the various .lua files.
Lycos 2023 年 2 月 24 日 下午 12:43 
Sorry, i have no idea what you mean with copy the map. I have downloaded it, but there is no folder to find for me.
Thoroniul  [作者] 2023 年 2 月 24 日 上午 10:46 
One can copy the map and search in the folder and just read the code directly.