Fix NPC visibility and stabilize world transport/taxi updates

This commit is contained in:
Kelsi 2026-02-11 18:25:04 -08:00
parent 5dae994830
commit f752a4f517
16 changed files with 452 additions and 173 deletions

View file

@ -323,6 +323,9 @@ private:
float mountHeightOffset_ = 0.0f;
float mountPitch_ = 0.0f; // Up/down tilt (radians)
float mountRoll_ = 0.0f; // Left/right banking (radians)
int mountSeatAttachmentId_ = -1; // -1 unknown, -2 unavailable
glm::vec3 smoothedMountSeatPos_ = glm::vec3(0.0f);
bool mountSeatSmoothingInit_ = false;
float prevMountYaw_ = 0.0f; // Previous yaw for turn rate calculation (procedural lean)
float lastDeltaTime_ = 0.0f; // Cached for use in updateCharacterAnimation()
MountAction mountAction_ = MountAction::None; // Current mount action (jump/rear-up)

View file

@ -20,6 +20,7 @@ struct WorldMapZone {
float locLeft = 0, locRight = 0, locTop = 0, locBottom = 0;
uint32_t displayMapID = 0;
uint32_t parentWorldMapID = 0;
uint32_t exploreFlag = 0;
// Per-zone cached textures
GLuint tileTextures[12] = {};
@ -34,6 +35,7 @@ public:
void initialize(pipeline::AssetManager* assetManager);
void render(const glm::vec3& playerRenderPos, int screenWidth, int screenHeight);
void setMapName(const std::string& name);
void setServerExplorationMask(const std::vector<uint32_t>& masks, bool hasData);
bool isOpen() const { return open; }
void close() { open = false; }
@ -87,6 +89,8 @@ private:
GLuint tileQuadVBO = 0;
// Exploration / fog of war
std::vector<uint32_t> serverExplorationMask;
bool hasServerExplorationMask = false;
std::unordered_set<int> exploredZones; // zone indices the player has visited
};