You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
658 B
25 lines
658 B
#pragma once
|
|
#include "components.hpp"
|
|
#include "events.hpp"
|
|
#include <guecs/ui.hpp>
|
|
#include "textures.hpp"
|
|
#include "levelmanager.hpp"
|
|
|
|
namespace guecs {
|
|
Clickable make_action(GameLevel& target, Events::GUI event);
|
|
Clickable make_action(GameLevel& target, Events::GUI event, std::any data);
|
|
|
|
struct GrabSource {
|
|
DinkyECS::Entity world_entity;
|
|
std::function<void()> commit;
|
|
std::shared_ptr<sf::Sprite> sprite = nullptr;
|
|
|
|
DinkyECS::Entity grab();
|
|
void setSprite(guecs::UI& gui, guecs::Entity gui_id);
|
|
void move(sf::Vector2f pos);
|
|
};
|
|
|
|
struct DropTarget {
|
|
std::function<bool(DinkyECS::Entity world_entity)> commit;
|
|
};
|
|
}
|
|
|