Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
次のようなluaファイルがあります。
tableA = {…} tableB = {…} tableC = {…}
ファイルで定義されたすべてのテーブルの名前を含む std::vector を取得したい: {"tableA", "tableB", "tableC"}
Lua C API でこれを行うにはどうすればよいですか?
スクリプト ファイルの実行中に作成されたランダム グローバル変数の名前を取得するには、環境ゲームを使用して、独自の「グローバル」コンテキストでスクリプトを実行する必要があります。
スクリプトを変更できる場合は、呼び出し元のスクリプトにテーブル (または名前のみ) を返す方がはるかに簡単です。