From 3b127cfa0e76bd26e64c6ce3c0517328ae424e3b Mon Sep 17 00:00:00 2001 From: Aaron Kimbrell Date: Tue, 29 Sep 2026 04:18:04 -0500 Subject: [PATCH] feat(property): zone position and build height come from PropertyTemplate DownloadPropertyData sent the same zonePosition (548, 406, 178) and a maxBuildHeight of 128 for every property. Both now come from the property's PropertyTemplate row (zoneX/zoneY/zoneZ, maxBuildHeight), the same row the template ID, vendor map and spawn name already come from. A map with no row still sends the old values. Live rows: Avant Gardens small (1150) keeps 548/406/178 and 128; Avant Gardens medium (1151) is 428/413/82 with a build height of 256; the Nimbus Station (1250, 1251), Gnarled Forest (1350) and Forbidden Valley (1450) properties get their own positions with 128. Check in game: on the medium Avant Gardens property (1151) models can be placed higher than before (up to 256), and on the small one (1150) the limit is unchanged; on the other worlds' properties the property screens (plaque, news/claim UI) still show and building works as before. Co-Authored-By: Claude Opus 5.5 --- .../CDClientTables/CDPropertyTemplateTable.cpp | 6 +++++- .../CDClientTables/CDPropertyTemplateTable.h | 6 ++++++ dGame/dComponents/PropertyManagementComponent.cpp | 4 ++-- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.cpp b/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.cpp index 4046b6faa..6e2c19271 100644 --- a/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.cpp +++ b/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.cpp @@ -25,7 +25,11 @@ void CDPropertyTemplateTable::LoadValuesFromDatabase() { static_cast(tableData.getIntField("id", -1)), static_cast(tableData.getIntField("mapID", -1)), static_cast(tableData.getIntField("vendorMapID", -1)), - tableData.getStringField("spawnName", "") + tableData.getStringField("spawnName", ""), + tableData.getFloatField("zoneX", 548.0f), + tableData.getFloatField("zoneY", 406.0f), + tableData.getFloatField("zoneZ", 178.0f), + tableData.getFloatField("maxBuildHeight", 128.0f) }; entries.push_back(entry); diff --git a/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.h b/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.h index e2f20ec06..75a80eef9 100644 --- a/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.h +++ b/dDatabase/CDClientDatabase/CDClientTables/CDPropertyTemplateTable.h @@ -6,6 +6,12 @@ struct CDPropertyTemplate { uint32_t mapID; uint32_t vendorMapID; std::string spawnName; + // Sent to the client in DownloadPropertyData; the defaults are what was sent + // for every property before these columns were read + float zoneX = 548.0f; + float zoneY = 406.0f; + float zoneZ = 178.0f; + float maxBuildHeight = 128.0f; }; class CDPropertyTemplateTable : public CDTable> { diff --git a/dGame/dComponents/PropertyManagementComponent.cpp b/dGame/dComponents/PropertyManagementComponent.cpp index 8088eb9fc..3c86f2aaf 100644 --- a/dGame/dComponents/PropertyManagementComponent.cpp +++ b/dGame/dComponents/PropertyManagementComponent.cpp @@ -946,8 +946,8 @@ void PropertyManagementComponent::OnQueryPropertyData(Entity* originator, const message.lastLogoutTime = 0; message.dayOfMonthPlaqueWasBought = 1; message.repAchievementReq = 1; - message.zonePosition = { 548.0f, 406.0f, 178.0f }; - message.maxBuildHeight = 128.0f; + message.zonePosition = { propertyTemplate.zoneX, propertyTemplate.zoneY, propertyTemplate.zoneZ }; + message.maxBuildHeight = propertyTemplate.maxBuildHeight; message.rentalDate = claimed; message.accessType = static_cast(privacy); message.pathPositions = GetPaths();