Heightmap editor + saving
This commit is contained in:
@@ -145,7 +145,6 @@ PhysicsModule::PhysicsModule(flecs::world &ecs)
|
||||
PhysicsShape &s = e.ensure<PhysicsShape>();
|
||||
s.shape = shape;
|
||||
e.modified<PhysicsShape>();
|
||||
delete hfd.samples;
|
||||
e.remove<PhysicsHeightfieldData>();
|
||||
});
|
||||
#if 1
|
||||
@@ -341,6 +340,16 @@ PhysicsModule::PhysicsModule(flecs::world &ecs)
|
||||
.each([this](const EngineData &eng) {
|
||||
ECS::get().set<WaterBody>({});
|
||||
});
|
||||
#if 0
|
||||
ecs.system<const EngineData>("DebugData")
|
||||
.kind(PhysicsPostUpdate)
|
||||
.each([this](const EngineData &eng) {
|
||||
std::cout << "TerrainReady: "
|
||||
<< ECS::get().has<TerrainReady>();
|
||||
std::cout << " WaterReady: "
|
||||
<< ECS::get().has<WaterReady>() << std::endl;
|
||||
});
|
||||
#endif
|
||||
ecs.system<const EngineData, WaterBody>("update_water")
|
||||
.kind(PhysicsPostUpdate)
|
||||
.with<TerrainReady>()
|
||||
|
||||
Reference in New Issue
Block a user