Mercurial > hg > forks > yadex
changeset 51:a521308b47fb
Use the new helper functions here.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 26 Sep 2011 04:40:02 +0300 |
parents | 48d4f8e3fce5 |
children | 29a5fac5c75f |
files | src/objinfo.cc |
diffstat | 1 files changed, 4 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/src/objinfo.cc Mon Sep 26 04:39:34 2011 +0300 +++ b/src/objinfo.cc Mon Sep 26 04:40:02 2011 +0300 @@ -46,7 +46,7 @@ #include "sticker.h" #include "things.h" #include "wadres.h" - +#include "textures.h" static const int sprite_width = 90; static const int sprite_height = 90; @@ -92,11 +92,6 @@ out_y1 = 0; } -static int is_notexture(const char *name) -{ - return (name[0] == '-' && name[1] == 0); -} - static void draw_sidedef_info(int sidedef, int sd, int sd2, int obj_no, int x0, int y0, int ix0, int iy0, int s1, int s2, int width, int height) { DrawScreenBox3D(x0, y0, x0 + width - 1, y0 + height - 1); @@ -110,7 +105,7 @@ Sectors[s1].ceilh > Sectors[s2].ceilh && !(is_sky(Sectors[s1].ceilt) && is_sky(Sectors[s2].ceilt))) { - set_colour(is_notexture(SideDefs[sd].tex1) ? CLR_ERROR : WINFG); + set_colour(InvalidTextureName(SideDefs[sd].tex1) ? CLR_ERROR : WINFG); } else set_colour(WINFG_DIM); @@ -119,7 +114,7 @@ "\1Upper:\2 %.*s", WAD_TEX_NAME, SideDefs[sd].tex1); - set_colour(sd2 < 0 && is_notexture(SideDefs[sd].tex3) ? CLR_ERROR : WINFG); + set_colour(sd2 < 0 && InvalidTextureName(SideDefs[sd].tex3) ? CLR_ERROR : WINFG); DrawScreenText(-1, -1, "\1Middle:\2 %.*s", @@ -129,7 +124,7 @@ Sectors[s1].floorh < Sectors[s2].floorh && !(is_sky(Sectors[s1].floort) && is_sky(Sectors[s2].floort))) { - set_colour(is_notexture(SideDefs[sd].tex2) ? CLR_ERROR : WINFG); + set_colour(InvalidTextureName(SideDefs[sd].tex2) ? CLR_ERROR : WINFG); } else set_colour(WINFG_DIM);