summaryrefslogtreecommitdiff
path: root/src/hexen/mn_menu.c
diff options
context:
space:
mode:
authorSimon Howard2008-12-01 22:16:53 +0000
committerSimon Howard2008-12-01 22:16:53 +0000
commite3a806cc094848794d6115914eeb8bf0e0ae1b2a (patch)
tree9e9ff0ffbaa6d50fbc16ad1a55fb4613d81e7735 /src/hexen/mn_menu.c
parentc8ef0c4a75b12d1c35f9a6994bdca36aa8897055 (diff)
downloadchocolate-doom-e3a806cc094848794d6115914eeb8bf0e0ae1b2a.tar.gz
chocolate-doom-e3a806cc094848794d6115914eeb8bf0e0ae1b2a.tar.bz2
chocolate-doom-e3a806cc094848794d6115914eeb8bf0e0ae1b2a.zip
Do endianness conversion when accessing patch->width fields.
Subversion-branch: /branches/raven-branch Subversion-revision: 1399
Diffstat (limited to 'src/hexen/mn_menu.c')
-rw-r--r--src/hexen/mn_menu.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/hexen/mn_menu.c b/src/hexen/mn_menu.c
index e166022d..dd508e28 100644
--- a/src/hexen/mn_menu.c
+++ b/src/hexen/mn_menu.c
@@ -29,6 +29,7 @@
#include "h2def.h"
#include "doomkeys.h"
#include "i_system.h"
+#include "i_swap.h"
#include "i_video.h"
#include "p_local.h"
#include "r_local.h"
@@ -359,7 +360,7 @@ void MN_DrTextA(char *text, int x, int y)
{
p = W_CacheLumpNum(FontABaseLump + c - 33, PU_CACHE);
V_DrawPatch(x, y, p);
- x += p->width - 1;
+ x += SHORT(p->width) - 1;
}
}
}
@@ -414,7 +415,7 @@ int MN_TextAWidth(char *text)
else
{
p = W_CacheLumpNum(FontABaseLump + c - 33, PU_CACHE);
- width += p->width - 1;
+ width += SHORT(p->width) - 1;
}
}
return (width);
@@ -443,7 +444,7 @@ void MN_DrTextB(char *text, int x, int y)
{
p = W_CacheLumpNum(FontBBaseLump + c - 33, PU_CACHE);
V_DrawPatch(x, y, p);
- x += p->width - 1;
+ x += SHORT(p->width) - 1;
}
}
}
@@ -472,7 +473,7 @@ int MN_TextBWidth(char *text)
else
{
p = W_CacheLumpNum(FontBBaseLump + c - 33, PU_CACHE);
- width += p->width - 1;
+ width += SHORT(p->width) - 1;
}
}
return (width);