feat: 添加Squirrel脚本支持并完善平台相关功能
- 新增SquirrelVM类实现脚本引擎功能 - 添加Windows平台初始化代码以支持UTF-8控制台输出 - 在各平台构建配置中添加squirrel依赖 - 创建测试脚本main.nut验证中文支持 - 更新.gitignore排除nul文件
This commit is contained in:
@@ -4,6 +4,7 @@ add_requires("libsdl2_image")
|
||||
add_requires("libsdl2_mixer")
|
||||
add_requires("glm")
|
||||
add_requires("zlib")
|
||||
add_requires("squirrel")
|
||||
|
||||
target("Frostbite2D")
|
||||
set_kind("binary")
|
||||
@@ -19,6 +20,7 @@ target("Frostbite2D")
|
||||
add_packages("libsdl2_mixer")
|
||||
add_packages("glm")
|
||||
add_packages("zlib")
|
||||
add_packages("squirrel")
|
||||
|
||||
-- 复制着色器文件到输出目录
|
||||
after_build(function (target)
|
||||
|
||||
@@ -7,6 +7,7 @@ add_requires("libsdl2_mixer", {configs = {shared = true}})
|
||||
add_requires("libsdl2_ttf", {configs = {shared = true}})
|
||||
add_requires("glm")
|
||||
add_requires("zlib")
|
||||
add_requires("squirrel")
|
||||
|
||||
target("Frostbite2D")
|
||||
set_kind("binary")
|
||||
@@ -23,6 +24,7 @@ target("Frostbite2D")
|
||||
add_packages("libsdl2_ttf")
|
||||
add_packages("glm")
|
||||
add_packages("zlib")
|
||||
add_packages("squirrel")
|
||||
|
||||
-- 复制 assets 目录到输出目录
|
||||
after_build(function (target)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
|
||||
|
||||
target("Frostbite2D")
|
||||
set_kind("binary")
|
||||
add_files(path.join(os.projectdir(), "Frostbite2D/src/**.cpp"))
|
||||
@@ -40,7 +41,7 @@ target("Frostbite2D")
|
||||
add_includedirs(path.join(devkitPro, "portlibs/switch/include/SDL2"))
|
||||
add_linkdirs(path.join(devkitPro, "portlibs/switch/lib"))
|
||||
|
||||
add_syslinks("SDL2_mixer", "SDL2_image", "SDL2_ttf", "SDL2", "freetype", "harfbuzz" , "bz2" , "webp", "png", "jpeg", "z", "opusfile", "opus", "vorbisidec", "ogg","modplug", "mpg123", "FLAC", "GLESv2", "EGL", "glapi", "drm_nouveau",{public = true})
|
||||
add_syslinks("SDL2_mixer", "SDL2_image", "SDL2_ttf", "SDL2", "freetype", "harfbuzz" , "squirrel_static", "sqstdlib_static", "bz2" , "webp", "png", "jpeg", "z", "opusfile", "opus", "vorbisidec", "ogg","modplug", "mpg123", "FLAC", "GLESv2", "EGL", "glapi", "drm_nouveau",{public = true})
|
||||
add_syslinks("nx", "m")
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user