如何创建这样的 Lua 对象:
players = {
{
pos = {x=12.43,y=6.91},
backpack = {22,54},
health = 99.71
name = "player1"
},
{
pos = {x=22.45,y=7.02},
backpack = {12,31},
health = 19.00
name = "player2"
}
}
在我的 C++ 源代码中,其值取自我的 C++ 代码的变量?
最后,它当然需要对所有脚本都可用。