mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-17 09:33:51 +00:00
Fix WMO spawn presets to avoid terrain snapping
This commit is contained in:
parent
ae37e5592e
commit
28a8e806e1
3 changed files with 28 additions and 18 deletions
|
|
@ -11,17 +11,20 @@ struct SpawnPreset {
|
|||
glm::vec3 spawnCanonical; // Canonical WoW coords: +X=North, +Y=West, +Z=Up
|
||||
float yawDeg;
|
||||
float pitchDeg;
|
||||
bool snapToGround; // true=terrain/WMO floor search, false=preserve explicit Z
|
||||
};
|
||||
|
||||
// Spawn positions in canonical WoW world coordinates (X=north, Y=west, Z=up).
|
||||
// Tile is computed from position via: tileN = floor(32 - wowN / 533.33333)
|
||||
inline const SpawnPreset SPAWN_PRESETS[] = {
|
||||
{"goldshire", "Goldshire", "Azeroth", glm::vec3( 62.0f, -9464.0f, 200.0f), 0.0f, -5.0f},
|
||||
{"stormwind", "Stormwind Gate", "Azeroth", glm::vec3( 425.0f, -9176.0f, 120.0f), 35.0f, -8.0f},
|
||||
{"ironforge", "Ironforge", "Azeroth", glm::vec3( -882.0f, -4981.0f, 510.0f), -20.0f, -8.0f},
|
||||
{"westfall", "Westfall", "Azeroth", glm::vec3( 1215.0f,-10440.0f, 80.0f), 10.0f, -8.0f},
|
||||
{"goldshire", "Goldshire", "Azeroth", glm::vec3( 62.0f, -9464.0f, 200.0f), 0.0f, -5.0f, true},
|
||||
{"stormwind", "Stormwind Gate", "Azeroth", glm::vec3( 425.0f, -9176.0f, 120.0f), 35.0f, -8.0f, true},
|
||||
// Stormwind city center plaza on WMO floor (not terrain intersection).
|
||||
{"sw_plaza", "Stormwind Plaza","Azeroth", glm::vec3( 620.0f, -8830.0f, 95.0f), 180.0f, -8.0f, false},
|
||||
{"ironforge", "Ironforge", "Azeroth", glm::vec3( -882.0f, -4981.0f, 510.0f), -20.0f, -8.0f, true},
|
||||
{"westfall", "Westfall", "Azeroth", glm::vec3( 1215.0f,-10440.0f, 80.0f), 10.0f, -8.0f, true},
|
||||
};
|
||||
|
||||
inline constexpr int SPAWN_PRESET_COUNT = 4;
|
||||
inline constexpr int SPAWN_PRESET_COUNT = static_cast<int>(sizeof(SPAWN_PRESETS) / sizeof(SPAWN_PRESETS[0]));
|
||||
|
||||
} // namespace wowee::core
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue