- Tota la API canviada. Fent la documentació.
- v1.0 RC1
This commit is contained in:
2
Makefile
2
Makefile
@@ -24,4 +24,4 @@ linux:
|
||||
strip -s -R .comment -R .gnu.version --strip-unneeded "$(executable)"
|
||||
|
||||
linux_debug:
|
||||
g++ $(source) -D LUA_USE_LINUX -D DEBUG -g -Wall -Os -ffunction-sections -fdata-sections -Wl,--gc-sections -lSDL2 -o "$(executable)_debug"
|
||||
g++ $(source) -D LUA_USE_LINUX -D DEBUG -g -Wall -lSDL2 -o "$(executable)_debug"
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
other = require "other"
|
||||
--other = require "other"
|
||||
|
||||
x=0
|
||||
|
||||
function _init()
|
||||
text=other.peiv()
|
||||
keyRight = tonumber(getconf("keyright")) or KEY_RIGHT
|
||||
keyLeft = tonumber(getconf("keyleft")) or KEY_LEFT
|
||||
_update=normal_update
|
||||
--text=other.peiv()
|
||||
--keyRight = tonumber(getconf("keyright")) or KEY_RIGHT
|
||||
--keyLeft = tonumber(getconf("keyleft")) or KEY_LEFT
|
||||
--_update=normal_update
|
||||
--turbo(false)
|
||||
local perico = "péricòñ"
|
||||
print(utf8.len(perico))
|
||||
--local perico = "péricòñ"
|
||||
--print(utf8.len(perico))
|
||||
end
|
||||
|
||||
function _update()
|
||||
if key.press(key.ESCAPE) then
|
||||
sys.quit()
|
||||
end
|
||||
|
||||
draw.cls(5)
|
||||
draw.print("HOLA",0,0)
|
||||
end
|
||||
|
||||
function normal_update()
|
||||
|
||||
6
mini.cpp
6
mini.cpp
@@ -294,11 +294,17 @@ int main(int argc,char*argv[]){
|
||||
|
||||
if (argc>1)
|
||||
{
|
||||
if (strstr(argv[1], ".lua")!=nullptr) {
|
||||
file_setresourcefolder("./");
|
||||
file_setsource(SOURCE_FOLDER);
|
||||
strcpy(main_lua_file, argv[1]);
|
||||
strcpy(window_title, argv[1]);
|
||||
override_ini = true;
|
||||
} else {
|
||||
char path[256] = "./";
|
||||
strcat(path, argv[1]);
|
||||
file_setresourcefolder(path);
|
||||
}
|
||||
}
|
||||
|
||||
while (!should_quit) {
|
||||
|
||||
Reference in New Issue
Block a user