#pragma once #include #include "ZapperObject.h" #include "util/OptionalRef.h" class ZapperPoolSubScene; class ZapperPoolScript : public crepe::Script { public: ZapperPoolScript(std::vector && pool); void init(); void fixed_update(crepe::duration_t); unsigned i = 0; private: std::vector pool; private: crepe::OptionalRef camera_transform; crepe::OptionalRef camera_camera; crepe::OptionalRef get_next_zapper(); private: void spawn_random(); private: static constexpr float OFFSCREEN_MARGIN = 40; };