Categories > Coding > C++ >

[QUESTION] how does lua_load and lua_state work

Posts: 8

Threads: 5

Joined: Jul, 2024

Reputation: 0

Posted

how does Luau_load and luau_state work and why are they?, I know that luau_load executes the script, but then why luau_state?

  • 1

Astronemi

hot chocolate addict

Posts: 20

Threads: 2

Joined: May, 2020

Reputation: 38

Replied

luau_load simply loads the bytecode you provide it, luau_state is basically the luau instance that's running. Here's an example:

https://www.lua.org/pil/24.1.html

 

Enjoy!

  • 0

i like tiramisu

 

oh i also do c/c++ and other cool programming languages like javascript, typescript, c#, java and lua

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )