1717
1818#ifndef __INCLUDED_STEAM_CONTROLLER_H__
1919#define __INCLUDED_STEAM_CONTROLLER_H__
20+ #define GAMEPAD_COUNT 4
2021
2122#include " base.h"
22-
23+ # include " gamepad_provider/gamepad_provider.hpp "
2324
2425struct Controller_Map {
2526 std::map<ControllerDigitalActionHandle_t, std::set<int >> active_digital{};
@@ -30,10 +31,13 @@ struct Controller_Action {
3031 ControllerHandle_t controller_handle{};
3132 struct Controller_Map active_map{};
3233 ControllerDigitalActionHandle_t active_set{};
34+ std::map<ControllerActionSetHandle_t, struct Controller_Map > active_layers{};
3335
3436 Controller_Action (ControllerHandle_t controller_handle);
3537
3638 void activate_action_set (ControllerDigitalActionHandle_t active_set, std::map<ControllerActionSetHandle_t, struct Controller_Map > &controller_maps);
39+ void activate_action_set_layer (ControllerActionSetHandle_t active_layer, std::map<ControllerActionSetHandle_t, struct Controller_Map > &controller_maps);
40+ void deactivate_action_set_layer (ControllerActionSetHandle_t active_layer);
3741 std::set<int > button_id (ControllerDigitalActionHandle_t handle);
3842 std::pair<std::set<int >, enum EInputSourceMode> analog_id (ControllerAnalogActionHandle_t handle);
3943};
@@ -101,14 +105,16 @@ public ISteamInput
101105 std::map<EInputActionOrigin, std::string> steaminput_glyphs{};
102106 std::map<EControllerActionOrigin, std::string> steamcontroller_glyphs{};
103107
108+ std::thread sdl_thread{};
104109 std::thread background_rumble_thread{};
105110 Rumble_Thread_Data *rumble_thread_data{};
106111
107112 bool disabled{};
108113 bool initialized{};
109114 bool explicitly_call_run_frame{};
110115
111- void set_handles (std::map<std::string, std::map<std::string, std::pair<std::set<std::string>, std::string>>> action_sets);
116+ void set_handles (std::map<std::string, std::map<std::string, std::pair<std::set<std::string>, std::string>>> action_sets,
117+ std::map<std::string, std::map<std::string, std::pair<std::set<std::string>, std::string>>> action_set_layers);
112118
113119 void RunCallbacks ();
114120
0 commit comments