mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-11 18:50:46 +00:00
Added a DEF command: animtilerange <tile1> <tile2> <speed> <type>.
Note: it must be used with dummytiles. git-svn-id: https://svn.eduke32.com/eduke32@928 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
95297e60e9
commit
2dc6f66dca
1 changed files with 22 additions and 0 deletions
|
@ -70,6 +70,7 @@ enum
|
|||
T_LOADGRP,
|
||||
T_DUMMYTILE,T_DUMMYTILERANGE,
|
||||
T_SETUPTILE,T_SETUPTILERANGE,
|
||||
T_ANIMTILERANGE,
|
||||
T_CACHESIZE,
|
||||
T_MUSIC,T_ID,T_SOUND,
|
||||
T_REDPAL,T_BLUEPAL,T_BROWNPAL,T_GREYPAL,T_GREENPAL,T_SPECPAL
|
||||
|
@ -123,6 +124,7 @@ static tokenlist basetokens[] =
|
|||
{ "dummytilerange", T_DUMMYTILERANGE },
|
||||
{ "setuptile", T_SETUPTILE },
|
||||
{ "setuptilerange", T_SETUPTILERANGE },
|
||||
{ "animtilerange", T_ANIMTILERANGE },
|
||||
{ "cachesize", T_CACHESIZE },
|
||||
};
|
||||
|
||||
|
@ -565,6 +567,26 @@ static int defsparser(scriptfile *script)
|
|||
}
|
||||
break;
|
||||
}
|
||||
case T_ANIMTILERANGE:
|
||||
{
|
||||
int tile1, tile2, spd, type, i;
|
||||
|
||||
if (scriptfile_getsymbol(script,&tile1)) break;
|
||||
if (tile1 >= MAXTILES)break;
|
||||
if (scriptfile_getsymbol(script,&tile2)) break;
|
||||
if (tile2 >= MAXTILES)break;
|
||||
if (scriptfile_getsymbol(script,&spd)) break;
|
||||
if (scriptfile_getsymbol(script,&type)) break;
|
||||
if (tile2 < tile1)
|
||||
{
|
||||
initprintf("Warning: backwards tile range on line %s:%d\n", script->filename, scriptfile_getlinum(script,cmdtokptr));
|
||||
i = tile2;
|
||||
tile2 = tile1;
|
||||
tile1 = i;
|
||||
}
|
||||
picanm[tile1]=(spd<<24)+(type<<6)+tile2-tile1;
|
||||
break;
|
||||
}
|
||||
case T_DUMMYTILE:
|
||||
{
|
||||
int tile, xsiz, ysiz, j;
|
||||
|
|
Loading…
Reference in a new issue