Skip to content

Commit

Permalink
Fix markup flags for Underworld
Browse files Browse the repository at this point in the history
  • Loading branch information
TheIndra55 committed Aug 19, 2024
1 parent d57e15e commit 265f3e6
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 14 deletions.
27 changes: 23 additions & 4 deletions src/level/Markup.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ enum MUD_FLAGS : unsigned int
MUD_FLAG_NONE,
MUD_FLAG_DISABLED = 0x80000000,

#ifndef TR8
MUD_FLAG_LEDGEGRAB = 1 << 30,
MUD_FLAG_JUMPLANDING = 1 << 29,
MUD_FLAG_ENEMYDROPDOWN = 1 << 28,
Expand All @@ -55,12 +56,30 @@ enum MUD_FLAGS : unsigned int
MUD_FLAG_ENEMY_JUMP_DOWN = 1 << 15,
MUD_FLAG_ENEMY_JUMP_ACROSS = 1 << 14,
MUD_FLAG_PATTERN_INTERACT = 1 << 13,
#else
MUD_FLAG_LEDGEGRAB = 1 << 30,
MUD_FLAG_JUMPLANDING = 1 << 29,
MUD_FLAG_ENEMYDROPDOWN = 1 << 28,
MUD_FLAG_POLE = 1 << 27,
MUD_FLAG_VERTPOLE = 1 << 26,
MUD_FLAG_HORIZPOLE = 1 << 25,
MUD_FLAG_ZIPLINE = 1 << 24,
MUD_FLAG_RAILSLIDE = 1 << 23,
MUD_FLAG_LADDER = 1 << 22,
MUD_FLAG_CLOSEJUMPTARGET = 1 << 21,
MUD_FLAG_WATER = 1 << 20,
MUD_FLAG_ROPE = 1 << 19,
MUD_FLAG_COVER = 1 << 18,
MUD_FLAG_PERCH = 1 << 17,
MUD_FLAG_BALANCEBEAM = 1 << 16,
MUD_FLAG_CONSTRAINEDGROUND = 1 << 15,
MUD_FLAG_PILLAR = 1 << 4,
#endif

MUD_FLAG_WRAPS = 1 << 2,
MUD_FLAG_INSTANCE = 1 << 1,
MUD_FLAG_POLYLINE = 1 << 0,
MUD_FLAG_WRAPS = 1 << 2,
MUD_FLAG_INSTANCE = 1 << 1,
MUD_FLAG_POLYLINE = 1 << 0,

MUD_FLAG_ALL_TYPES = MUD_FLAG_ENEMY_JUMP_ACROSS | MUD_FLAG_ENEMY_JUMP_DOWN | MUD_FLAG_ENEMY_JUMP_UP | MUD_FLAG_PERCH | MUD_FLAG_ROPE | MUD_FLAG_WATER | MUD_FLAG_CLOSEJUMPTARGET | MUD_FLAG_LADDER | MUD_FLAG_MANTLEDOWN | MUD_FLAG_ZIPLINE | MUD_FLAG_HORIZPOLE | MUD_FLAG_VERTPOLE | MUD_FLAG_WALLVERTPOLE | MUD_FLAG_ENEMYDROPDOWN | MUD_FLAG_JUMPLANDING | MUD_FLAG_LEDGEGRAB | MUD_FLAG_DISABLED,
MUD_FLAG_ALL = 0xFFFFFFFF,
};

Expand Down
29 changes: 19 additions & 10 deletions src/modules/Draw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,27 +32,36 @@ static inline cdc::Vector3 GetVertice(unsigned int vertice, Mesh* mesh, cdc::Vec

static std::pair<unsigned int, const char*> s_mudFlags[]
{
{ MUD_FLAG_INSTANCE, "INSTANCE | " },
{ MUD_FLAG_WRAPS, "WRAPS | " },
{ MUD_FLAG_PATTERN_INTERACT, "PATTERN_INTERACT | " },
{ MUD_FLAG_ENEMY_JUMP_ACROSS, "ENEMY_JUMP_ACROSS | " },
{ MUD_FLAG_ENEMY_JUMP_DOWN, "ENEMY_JUMP_DOWN | " },
{ MUD_FLAG_ENEMY_JUMP_UP, "ENEMY_JUMP_UP | " },
{ MUD_FLAG_ATTACHPOINTS, "ATTACHPOINTS | " },
{ MUD_FLAG_PERCH, "PERCH | " },
{ MUD_FLAG_ROPE, "ROPE | " },
{ MUD_FLAG_WATER, "WATER | " },
{ MUD_FLAG_CLOSEJUMPTARGET, "CLOSEJUMPTARGET | " },
{ MUD_FLAG_LADDER, "LADDER | " },
{ MUD_FLAG_MANTLEDOWN, "MANTLEDOWN | " },
{ MUD_FLAG_ZIPLINE, "ZIPLINE | " },
{ MUD_FLAG_HORIZPOLE, "HORIZPOLE | " },
{ MUD_FLAG_VERTPOLE, "VERTPOLE | " },
{ MUD_FLAG_WALLVERTPOLE, "WALLVERTPOLE | " },
{ MUD_FLAG_ENEMYDROPDOWN, "ENEMYDROPDOWN | " },
{ MUD_FLAG_JUMPLANDING, "JUMPLANDING | " },
{ MUD_FLAG_LEDGEGRAB, "LEDGEGRAB | " },
{ MUD_FLAG_DISABLED, "DISABLED | " }
#ifndef TR8
{ MUD_FLAG_PATTERN_INTERACT, "PATTERN_INTERACT | " },
{ MUD_FLAG_ENEMY_JUMP_ACROSS, "ENEMY_JUMP_ACROSS | " },
{ MUD_FLAG_ENEMY_JUMP_DOWN, "ENEMY_JUMP_DOWN | " },
{ MUD_FLAG_ENEMY_JUMP_UP, "ENEMY_JUMP_UP | " },
{ MUD_FLAG_ATTACHPOINTS, "ATTACHPOINTS | " },
{ MUD_FLAG_MANTLEDOWN, "MANTLEDOWN | " },
{ MUD_FLAG_WALLVERTPOLE, "WALLVERTPOLE | " },
#else
{ MUD_FLAG_POLE, "POLE | " },
{ MUD_FLAG_RAILSLIDE, "RAILSLIDE | " },
{ MUD_FLAG_COVER, "COVER | " },
{ MUD_FLAG_BALANCEBEAM, "BALANCEBEAM | " },
{ MUD_FLAG_CONSTRAINEDGROUND, "CONSTRAINEDGROUND | " },
{ MUD_FLAG_PILLAR, "PILLAR | " },
#endif
{ MUD_FLAG_DISABLED, "DISABLED | " },
{ MUD_FLAG_INSTANCE, "INSTANCE | " },
{ MUD_FLAG_WRAPS, "WRAPS | " }
};

void Draw::OnMenu()
Expand Down

0 comments on commit 265f3e6

Please sign in to comment.