ui,game,pipeline: player nameplates always-on, level-up ring effect, vanilla tile fallback, warden null guard

- Nameplates: player names always rendered regardless of V-key toggle;
  separate cull distance 40u (players/target) vs 20u (NPCs); cyan name
  color for other players; fade alpha scales with cull distance
- Level-up: add expanding golden ring burst (3 staggered waves, 420u
  max radius) + full-screen flash to renderDingEffect(); M2 LevelUp.m2
  is still attempted as a bonus on top
- Vanilla tile loading: add AssetManager::setBaseFallbackPath() so that
  when the primary manifest is an expansion-specific DBC-only subset
  (e.g. Data/expansions/vanilla/), world terrain files fall back to
  the base Data/ extraction; wired in Application::initialize()
- Warden: map a null guard page at address 0x0 in the Unicorn emulator
  so NULL-pointer reads in the module don't crash with UC_ERR_MAP;
  execution continues past the NULL read for better diagnostics
This commit is contained in:
Kelsi 2026-03-10 07:25:04 -07:00
parent 3cdaf78369
commit 0ea8e55ad4
5 changed files with 100 additions and 11 deletions

View file

@ -121,6 +121,15 @@ bool WardenEmulator::initialize(const void* moduleCode, size_t moduleSize, uint3
return false;
}
// Map a null guard page at address 0 (read-only, zeroed) so that NULL-pointer
// dereferences in the module don't crash the emulator with UC_ERR_MAP.
// This allows execution to continue past NULL reads, making diagnostics easier.
err = uc_mem_map(uc_, 0x0, 0x1000, UC_PROT_READ);
if (err != UC_ERR_OK) {
// Non-fatal — just log it; the emulator will still function
std::cerr << "[WardenEmulator] Note: could not map null guard page: " << uc_strerror(err) << '\n';
}
// Add hooks for debugging and invalid memory access
uc_hook hh;
uc_hook_add(uc_, &hh, UC_HOOK_MEM_INVALID, (void*)hookMemInvalid, this, 1, 0);