MiMoEngine ASM: x86-64 MASM汇编+C混合架构游戏引擎
核心热路径(数学/内存/字符串/性能分析)用MASM汇编(SSE/AVX2) 外围系统(窗口/渲染/ECS/音频/UI/脚本)用C语言 含自研编辑器、VisualScript积木编程、中文渲染(glyph_atlas)
This commit is contained in:
commit
2d56cb3bc9
91 files changed
+9988
No files matched your search
@@ -0,0 +1,32 @@
|
||||
#pragma once
|
||||
|
||||
// ============================================================================
|
||||
// lua_engine.h - Lua脚本引擎
|
||||
// ============================================================================
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
// 前向声明
|
||||
struct lua_State;
|
||||
|
||||
typedef struct {
|
||||
struct lua_State* L;
|
||||
int initialized;
|
||||
} LuaEngine;
|
||||
|
||||
// 创建/销毁
|
||||
LuaEngine* lua_engine_create(void);
|
||||
void lua_engine_destroy(LuaEngine* engine);
|
||||
|
||||
// 初始化
|
||||
int lua_engine_init(LuaEngine* engine);
|
||||
|
||||
// 执行
|
||||
int lua_engine_do_file(LuaEngine* engine, const char* path);
|
||||
int lua_engine_do_string(LuaEngine* engine, const char* code);
|
||||
|
||||
// 注册C函数
|
||||
void lua_engine_register_function(LuaEngine* engine, const char* name, void* func);
|
||||
|
||||
// 获取状态
|
||||
struct lua_State* lua_engine_get_state(LuaEngine* engine);
|
||||
Reference in new issue
Block a user