载入中...
搜索中...
未找到
PlacementMutation.cpp
浏览该文件的文档.
20void PlacementSystem::writeOccupancy(PlacementWorld &world, const BuildingDefinition &def, const PlacedBuilding &placed,
23 foreachFootprintCell(def, placed.originCellX, placed.originCellY, placed.rotationDeg, [&](int cx, int cy) {
69int PlacementSystem::placeAt(PlacementWorld *world, const std::string &buildingId, int cellX, int cellY,
117int PlacementSystem::placeAtWorld(PlacementWorld *world, const std::string &buildingId, float worldX, float worldY,
133int PlacementSystem::placeAtWorld3D(PlacementWorld *world, const std::string &buildingId, float worldX, float worldY,
186 auto result = placeFreeSurfaceResult(world, ghost->getBuildingId(), patch, ghost->rotationDeg_);
189 return placeFree(world, ghost->getBuildingId(), ghost->worldX_, ghost->worldY_, ghost->elevation_,
Stable, structured diagnostics shared by engine modules.
Pure cell/world projection helpers for GridConfig.
static bool foreachFootprintCell(const BuildingDefinition &def, int originCellX, int originCellY, float rotationDeg, const std::function< bool(int cx, int cy)> &fn)
枚举占地格子(旋转后局部 → 世界格子)。返回 false 若定义未知。
Definition PlacementSystem.cpp:487
建筑放置模块入口:定义 / 放置世界 / 鬼影 / 变更事件的脚本绑定点。 设计文档:docs/dev/建筑放置系统设计.md
Definition Building.cpp:10
std::string placementKind
Placement domain: cell (default), edge, corner, or free.
Definition BuildingTypes.h:111
std::vector< std::string > tags
Definition BuildingTypes.h:146
int level
Authoritative discrete floor coordinate used by occupancy and topology.
Definition BuildingTypes.h:211
std::vector< int > supportInstanceIds
Derived support links rebuilt from authoritative level/address data.
Definition BuildingTypes.h:236
uint64_t surfaceRevision
Definition PlacementSystem.h:55
std::string surfaceId
Definition PlacementSystem.h:54
Surface samples and continuity metrics for one rotated building footprint.
Definition PlacementSystem.h:66
float maxSlopeDegrees
Definition PlacementSystem.h:69
PlacementHit anchor
Definition PlacementSystem.h:67
float heightDelta
Definition PlacementSystem.h:70
std::vector< SurfacePatchSample > samples
Definition PlacementSystem.h:68