From 40f177cafd05b3ac8b50f2f4603a52708a902e98 Mon Sep 17 00:00:00 2001 From: helixhorned Date: Mon, 25 May 2015 12:57:47 +0000 Subject: [PATCH] LunaCON: expose g_tile[] members of 'tiledata'. git-svn-id: https://svn.eduke32.com/eduke32@5232 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/lunatic/con_lang.lua | 21 +++++++++++++++++-- .../eduke32/source/lunatic/defs_common.lua | 6 ++++++ polymer/eduke32/source/lunatic/dynsymlist | 1 + polymer/eduke32/source/lunatic/dynsymlist_m32 | 1 + 4 files changed, 27 insertions(+), 2 deletions(-) diff --git a/polymer/eduke32/source/lunatic/con_lang.lua b/polymer/eduke32/source/lunatic/con_lang.lua index ddb14bbd6..7e336819d 100644 --- a/polymer/eduke32/source/lunatic/con_lang.lua +++ b/polymer/eduke32/source/lunatic/con_lang.lua @@ -851,7 +851,7 @@ end local UD = function(memb) return "_gud(_pli)"..memb end local UDRO = function(memb) return { UD(memb) } end --- NOTE: Only members that actually encountered in existing mods are added here. +-- NOTE: Only members that are actually encountered in existing mods are added here. -- TODO: r5043, r5044 local UserdefLabels = { althud = UD".althud", @@ -913,6 +913,22 @@ local InputLabels = { extbits = INP".extbits", } +local TileDataLabels = { + -- tilesiz[] + xsize = "g_tile.sizx[%s]", + ysize = "g_tile.sizy[%s]", + + -- picanm[] +-- "animframes", +-- "xoffset", +-- "yoffset", +-- "animspeed", +-- "animtype", + + -- g_tile[] + gameflags = { "g_tile[%s]._flags" }, +} + StructAccessCode = { sector = SectorLabels, @@ -924,7 +940,8 @@ StructAccessCode = thisprojectile = SpriteProjectileLabels, userdef = UserdefLabels, input = InputLabels, --- TODO: tiledata, paldata + tiledata = TileDataLabels, +-- TODO: tiledata picanm[] members, paldata } -- NOTE: These MUST be in reverse lexicographical order! diff --git a/polymer/eduke32/source/lunatic/defs_common.lua b/polymer/eduke32/source/lunatic/defs_common.lua index 22774bc74..04291cbd3 100644 --- a/polymer/eduke32/source/lunatic/defs_common.lua +++ b/polymer/eduke32/source/lunatic/defs_common.lua @@ -445,6 +445,12 @@ const int16_t headspritesect[MAXSECTORS+1], headspritestat[MAXSTATUS+1]; const int16_t prevspritesect[MAXSPRITES], prevspritestat[MAXSPRITES]; const int16_t nextspritesect[MAXSPRITES], nextspritestat[MAXSPRITES]; const vec2_t tilesiz[MAXTILES]; +typedef struct { + uint8_t num; // animate number + int8_t xofs, yofs; + uint8_t sf; // anim. speed and flags +} picanm_t; +const picanm_t picanm[MAXTILES]; uint8_t show2dsector[(MAXSECTORS+7)>>3]; diff --git a/polymer/eduke32/source/lunatic/dynsymlist b/polymer/eduke32/source/lunatic/dynsymlist index 1c736dc40..59cd168f4 100644 --- a/polymer/eduke32/source/lunatic/dynsymlist +++ b/polymer/eduke32/source/lunatic/dynsymlist @@ -47,6 +47,7 @@ prevspritestat; nextspritesect; nextspritestat; tilesiz; +picanm; show2dsector; diff --git a/polymer/eduke32/source/lunatic/dynsymlist_m32 b/polymer/eduke32/source/lunatic/dynsymlist_m32 index 27d17d4b6..99f65e01f 100644 --- a/polymer/eduke32/source/lunatic/dynsymlist_m32 +++ b/polymer/eduke32/source/lunatic/dynsymlist_m32 @@ -47,6 +47,7 @@ prevspritestat; nextspritesect; nextspritestat; tilesiz; +picanm; show2dsector;