mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-12-04 02:02:06 +00:00
Rename the macros, reshape them slightly to avoid mixed declarations, and add a finalizer.
This commit is contained in:
parent
f7f9b68bb9
commit
cb2571b12c
1 changed files with 8 additions and 6 deletions
|
@ -29,23 +29,25 @@ void Taglist_AddToLines (const size_t tag, const size_t itemid);
|
|||
void Taglist_AddToMapthings (const size_t tag, const size_t itemid);
|
||||
#endif //__R_TAGLIST__
|
||||
|
||||
#define Tag_IterateSectors(tag, sc)\
|
||||
size_t kk;\
|
||||
#define TAG_ITER_SECTORS(tag, sc)\
|
||||
if(tags_sectors[tag])\
|
||||
{ size_t kk;\
|
||||
for(kk = 0, sc = tags_sectors[tag]->elements[0];\
|
||||
kk < tags_sectors[tag]->count;\
|
||||
sc = tags_sectors[tag]->elements[++kk])
|
||||
|
||||
#define Tag_IterateLines(tag, li)\
|
||||
size_t kk;\
|
||||
#define TAG_ITER_LINES(tag, li)\
|
||||
if(tags_lines[tag])\
|
||||
{ size_t kk;\
|
||||
for(kk = 0, li = tags_lines[tag]->elements[0];\
|
||||
kk < tags_lines[tag]->count;\
|
||||
li = tags_lines[tag]->elements[++kk])
|
||||
|
||||
#define Tag_IterateMapthings(tag, mt)\
|
||||
size_t kk;\
|
||||
#define TAG_ITER_THINGS(tag, mt)\
|
||||
if(tags_mapthings[tag])\
|
||||
{ size_t kk;\
|
||||
for(kk = 0, mt = tags_mapthings[tag]->elements[0];\
|
||||
kk < tags_mapthings[tag]->count;\
|
||||
mt = tags_mapthings[tag]->elements[++kk])
|
||||
|
||||
#define TAG_ITER_END }
|
||||
|
|
Loading…
Reference in a new issue