/polymer/eduke32/source/lunatic/bcheck.lua |
---|
111,7 → 111,7 |
return cstr |
end |
function bcheck.top_level(funcname) |
function bcheck.top_level(funcname, errlev) |
if (ffiC.g_elCallDepth > 0) then |
error("Invalid use of "..funcname..": must be called from top level", errlev or 3) |
end |
/polymer/eduke32/source/lunatic/defs.ilua |
---|
21,6 → 21,7 |
local ipairs = ipairs |
local loadstring = loadstring |
local pairs = pairs |
local pcall = pcall |
local rawget = rawget |
local rawset = rawset |
local select = select |
943,7 → 944,7 |
function actor_static_members.move(i, vec, cliptype, clipdist) |
check_sprite_idx(i) |
local vel = ivec3(vec.x, vec.y, vec.z) |
return ffiC.A_MoveSpriteClipdist(spritenum, vel, cliptype, clipdist or -1) |
return ffiC.A_MoveSpriteClipdist(i, vel, cliptype, clipdist or -1) |
end |
-- Delete sprite with index <i>. |
2049,7 → 2050,7 |
end |
function check_arg_number(name, argpos, val) |
local function check_arg_number(name, argpos, val) |
if (type(val) ~= "number") then |
errorf(3, "invalid '%s' argument (#%d) to gameactor: must be a number", name, argpos) |
end |
/polymer/eduke32/source/lunatic/engine_maptext.lua |
---|
4,6 → 4,8 |
local ffi = require("ffi") |
local ffiC = ffi.C |
local assert = assert |
local loadstring = loadstring |
local pairs = pairs |
local pcall = pcall |
local print = print |
/polymer/eduke32/source/lunatic/lunacon.lua |
---|
1372,7 → 1372,7 |
end |
-- Mark the last 'spriteflags' or 'sprite*' directive for the given actor. |
g_code.aflagsloc[tilenum] = getLocation(format("'%s' for actor", g_lastkw), pos) |
g_code.aflagsloc[tilenum] = getLocation(format("'%s' for actor", g_lastkw)) |
if (ffi and ok) then |
local tile = ffiC.g_tile[tilenum] |
3892,7 → 3892,7 |
end |
end |
function compare_gv(gva, gvb) |
local function compare_gv(gva, gvb) |
if (gva.loc[1] ~= gvb.loc[1]) then |
return gva.loc[1] < gvb.loc[1] |
end |