File tree Expand file tree Collapse file tree 3 files changed +1
-26
lines changed Expand file tree Collapse file tree 3 files changed +1
-26
lines changed Original file line number Diff line number Diff line change @@ -155,10 +155,6 @@ bool InputManager::process(const QEvent &ev) {
155155 return false ;
156156}
157157
158- void InputManager::set_id_texture (const std::shared_ptr<renderer::Texture2d> &id_texture) {
159- this ->game_controller ->set_id_texture (id_texture);
160- }
161-
162158void InputManager::process_action (const input::Event &ev,
163159 const input_action &action,
164160 const std::shared_ptr<InputContext> &ctx) {
Original file line number Diff line number Diff line change @@ -18,10 +18,6 @@ class GuiInput;
1818
1919namespace openage {
2020
21- namespace renderer {
22- class Texture2d ;
23- } // namespace renderer
24-
2521namespace input {
2622
2723namespace camera {
@@ -155,16 +151,6 @@ class InputManager {
155151 */
156152 bool process (const QEvent &ev);
157153
158- /* *
159- * Set the texture that maps pixels to entity IDs.
160- *
161- * Each pixel value in the texture corresponds to an entity ID. This
162- * mapping may be used for interacting with entities in the game world.
163- *
164- * @param id_texture ID texture.
165- */
166- void set_id_texture (const std::shared_ptr<renderer::Texture2d> &id_texture);
167-
168154private:
169155 /* *
170156 * Process the (default) action for an input event.
Original file line number Diff line number Diff line change @@ -255,14 +255,7 @@ void Presenter::init_input() {
255255 input_ctx->set_game_bindings (engine_context);
256256
257257 auto id_texture = this ->world_renderer ->get_id_texture ();
258- this ->input_manager ->set_id_texture (id_texture);
259-
260- window->add_resize_callback ([&](size_t /* width */ , size_t /* height */ , double /* scale*/ ) {
261- // TODO: We must guarantee that this happens AFTER the world renderer
262- // has resized its textures.
263- auto id_texture = this ->world_renderer ->get_id_texture ();
264- this ->input_manager ->set_id_texture (id_texture);
265- });
258+ game_controller->set_id_texture (id_texture);
266259 }
267260
268261 // attach GUI if it's initialized
You can’t perform that action at this time.
0 commit comments