From 0eea7760655a62b16201a753b9562b0461f0563f Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Fri, 30 Sep 2022 19:16:36 +0200 Subject: [PATCH] - moved RS_ bits to gamehud.h because that's all that uses these flags. --- source/build/include/build.h | 26 ------------------- source/core/gamehud.h | 20 ++++++++++++++ wadsrc/static/zscript/games/duke/ui/sbar_d.zs | 2 +- 3 files changed, 21 insertions(+), 27 deletions(-) diff --git a/source/build/include/build.h b/source/build/include/build.h index 9b9898ad1..6fee52aea 100644 --- a/source/build/include/build.h +++ b/source/build/include/build.h @@ -41,32 +41,6 @@ enum #define POINT2(i) (wall[wall[i].point2]) -// rotatesprite 'orientation' (actually much more) bits -enum { - RS_TRANS1 = 1, - RS_AUTO = 2, - RS_YFLIP = 4, - RS_NOCLIP = 8, - RS_TOPLEFT = 16, - RS_TRANS2 = 32, - RS_NOMASK = 64, - RS_PERM = 128, - - RS_ALIGN_L = 256, - RS_ALIGN_R = 512, - RS_ALIGN_MASK = 768, - RS_STRETCH = 1024, - - RS_MODELSUBST= 4096, - // ROTATESPRITE_MAX-1 is the mask of all externally available orientation bits - ROTATESPRITE_MAX = 8192, - RS_XFLIPHUD = RS_YFLIP, - RS_YFLIPHUD = 16384, // this is for hud_drawsprite which uses RS_YFLIP for x-flipping but needs both flags - - RS_CENTER = (1<<29), // proper center align. - RS_CENTERORIGIN = (1<<30), -}; - #include "maptypes.h" #include "clip.h" diff --git a/source/core/gamehud.h b/source/core/gamehud.h index 0fdfb12d0..e06b0b216 100644 --- a/source/core/gamehud.h +++ b/source/core/gamehud.h @@ -6,3 +6,23 @@ extern F2DDrawer twodpsp; void DrawRateStuff(); void hud_drawsprite(double sx, double sy, double sz, double a, int picnum, int dashade, int dapalnum, int dastat, double alpha = 1); + +// orientation bits for hud_drawsprite. +enum { + RS_TRANS1 = 1, + RS_YFLIP = 4, + RS_TOPLEFT = 16, + RS_TRANS2 = 32, + RS_NOMASK = 64, + + RS_ALIGN_L = 256, + RS_ALIGN_R = 512, + RS_ALIGN_MASK = 768, + RS_STRETCH = 1024, + + RS_XFLIPHUD = RS_YFLIP, + RS_YFLIPHUD = 16384, // this is for hud_drawsprite which uses RS_YFLIP for x-flipping but needs both flags + + RS_CENTER = (1 << 29), // proper center align. +}; + diff --git a/wadsrc/static/zscript/games/duke/ui/sbar_d.zs b/wadsrc/static/zscript/games/duke/ui/sbar_d.zs index 3c6c67365..47ff61d19 100644 --- a/wadsrc/static/zscript/games/duke/ui/sbar_d.zs +++ b/wadsrc/static/zscript/games/duke/ui/sbar_d.zs @@ -325,7 +325,7 @@ class DukeStatusBar : DukeCommonStatusBar /* if (isShareware() && (ind > DukeWpn.HANDBOMB_WEAPON || ind < 0)) { - minitextshade(x + 1, y - 4, "ORDER", 20, 11, 2 + 8 + 16 + ROTATESPRITE_MAX); + minitextshade(x + 1, y - 4, "ORDER", 20, 11, 2 + 8 + 16); return; } */