mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-11 18:50:46 +00:00
Ensure that anywhere the def parser takes a tilenum or palnum accepts defined tokens in addition to integer literals, if it doesn't already.
Affects fogpal, nofloorpalrange, setuptilerange, dummytilerange, undefinetilerange, definemodelframe, definevoxeltiles, texhitscanrange, nofullbrightrange, and light. git-svn-id: https://svn.eduke32.com/eduke32@6896 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
d2e4823feb
commit
9b495ea67f
2 changed files with 17 additions and 17 deletions
|
@ -595,7 +595,7 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t p,r,g,b;
|
||||
|
||||
if (scriptfile_getnumber(script,&p)) break;
|
||||
if (scriptfile_getsymbol(script,&p)) break;
|
||||
if (scriptfile_getnumber(script,&r)) break;
|
||||
if (scriptfile_getnumber(script,&g)) break;
|
||||
if (scriptfile_getnumber(script,&b)) break;
|
||||
|
@ -611,8 +611,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t b,e,i;
|
||||
|
||||
if (scriptfile_getnumber(script,&b)) break;
|
||||
if (scriptfile_getnumber(script,&e)) break;
|
||||
if (scriptfile_getsymbol(script,&b)) break;
|
||||
if (scriptfile_getsymbol(script,&e)) break;
|
||||
|
||||
b = max(b, 1);
|
||||
e = min(e, MAXPALOOKUPS-1);
|
||||
|
@ -722,8 +722,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t tile1,tile2,xsiz,ysiz,xoffs,yoffs,i;
|
||||
|
||||
if (scriptfile_getnumber(script,&tile1)) break;
|
||||
if (scriptfile_getnumber(script,&tile2)) break;
|
||||
if (scriptfile_getsymbol(script,&tile1)) break;
|
||||
if (scriptfile_getsymbol(script,&tile2)) break;
|
||||
if (scriptfile_getnumber(script,&xsiz)) break;
|
||||
if (scriptfile_getnumber(script,&ysiz)) break;
|
||||
if (scriptfile_getsymbol(script,&xoffs)) break;
|
||||
|
@ -1058,8 +1058,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t tile1,tile2,xsiz,ysiz,i;
|
||||
|
||||
if (scriptfile_getnumber(script,&tile1)) break;
|
||||
if (scriptfile_getnumber(script,&tile2)) break;
|
||||
if (scriptfile_getsymbol(script,&tile1)) break;
|
||||
if (scriptfile_getsymbol(script,&tile2)) break;
|
||||
if (scriptfile_getnumber(script,&xsiz)) break;
|
||||
if (scriptfile_getnumber(script,&ysiz)) break;
|
||||
|
||||
|
@ -1103,8 +1103,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t tile1, tile2;
|
||||
|
||||
if (scriptfile_getnumber(script,&tile1)) break;
|
||||
if (scriptfile_getnumber(script,&tile2)) break;
|
||||
if (scriptfile_getsymbol(script,&tile1)) break;
|
||||
if (scriptfile_getsymbol(script,&tile2)) break;
|
||||
|
||||
if (check_tile_range("undefinetilerange", &tile1, &tile2, script, cmdtokptr))
|
||||
break;
|
||||
|
@ -1152,8 +1152,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
int32_t ftilenume, ltilenume;
|
||||
|
||||
if (scriptfile_getstring(script,&framename)) break;
|
||||
if (scriptfile_getnumber(script,&ftilenume)) break; //first tile number
|
||||
if (scriptfile_getnumber(script,<ilenume)) break; //last tile number (inclusive)
|
||||
if (scriptfile_getsymbol(script,&ftilenume)) break; //first tile number
|
||||
if (scriptfile_getsymbol(script,<ilenume)) break; //last tile number (inclusive)
|
||||
|
||||
if (check_tile_range("definemodelframe", &ftilenume, <ilenume, script, cmdtokptr))
|
||||
break;
|
||||
|
@ -1311,8 +1311,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t ftilenume, ltilenume, tilex;
|
||||
|
||||
if (scriptfile_getnumber(script,&ftilenume)) break; //1st tile #
|
||||
if (scriptfile_getnumber(script,<ilenume)) break; //last tile #
|
||||
if (scriptfile_getsymbol(script,&ftilenume)) break; //1st tile #
|
||||
if (scriptfile_getsymbol(script,<ilenume)) break; //last tile #
|
||||
|
||||
if (check_tile_range("definevoxeltiles", &ftilenume, <ilenume, script, cmdtokptr))
|
||||
break;
|
||||
|
@ -1415,7 +1415,7 @@ static int32_t defsparser(scriptfile *script)
|
|||
switch (getatoken(script,modelframetokens,ARRAY_SIZE(modelframetokens)))
|
||||
{
|
||||
case T_PAL:
|
||||
scriptfile_getnumber(script,&pal); break;
|
||||
scriptfile_getsymbol(script,&pal); break;
|
||||
case T_FRAME:
|
||||
scriptfile_getstring(script,&framename); break;
|
||||
case T_TILE:
|
||||
|
@ -2539,8 +2539,8 @@ static int32_t defsparser(scriptfile *script)
|
|||
{
|
||||
int32_t b,e, i;
|
||||
|
||||
if (EDUKE32_PREDICT_FALSE(scriptfile_getnumber(script,&b))) break;
|
||||
if (EDUKE32_PREDICT_FALSE(scriptfile_getnumber(script,&e))) break;
|
||||
if (EDUKE32_PREDICT_FALSE(scriptfile_getsymbol(script,&b))) break;
|
||||
if (EDUKE32_PREDICT_FALSE(scriptfile_getsymbol(script,&e))) break;
|
||||
|
||||
b = max(b, 0);
|
||||
e = min(e, MAXUSERTILES-1);
|
||||
|
|
|
@ -303,7 +303,7 @@ int32_t engineLoadMHK(const char *filename)
|
|||
light.maxshade = value;
|
||||
scriptfile_getnumber(script, &value);
|
||||
light.priority = value;
|
||||
scriptfile_getnumber(script, &value);
|
||||
scriptfile_getsymbol(script, &value);
|
||||
light.tilenum = value;
|
||||
|
||||
light.publicflags.emitshadow = 1;
|
||||
|
|
Loading…
Reference in a new issue