void Wave::onStart() {
MaterialAsset paint;
paint.albedo = {0.25f, 0.55f, 1.0f, 1.0f};
// ... a field of cubes
}
void Wave::onUpdate(float dt) {
m_time += dt;
for (const EntityId block : m_cubes) {
Transform& at = scene().get<Transform>(block);
const float x = at.position.x, z = at.position.z;
at.position.y = 0.4f * std::sin(
std::sqrt(x * x + z * z) * 1.5f - m_time * 3.0f);
}
}
Hot reload
Change the C++, rebuild, and Play picks up the new code - the editor never closes.






