#include "components/ProbeStateComponent.hpp" #include "Entity.hpp" #include "components/TransformComponent.hpp" #include "raylib.h" void ProbeStateComponent::Setup() {} void ProbeStateComponent::Update(float) { if (!context || !context->probeEntity || entity != context->probeEntity) { return; } auto transform = entity->GetComponent(); if (!transform) { return; } if (transform->get().y < -20.0f || transform->get().y > static_cast(GetScreenHeight() + 20) || transform->get().x < -20.0f) { if (context->onPlayerDeath) { context->onPlayerDeath(); } } } void ProbeStateComponent::Cleanup() {}