mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-21 12:15:45 +00:00
shared_ptr for the GC adapter class, constexpr constants
This commit is contained in:
parent
4a54dc6bbf
commit
92a812d815
5 changed files with 55 additions and 69 deletions
|
@ -25,13 +25,15 @@ static std::shared_ptr<MotionEmu> motion_emu;
|
|||
static std::unique_ptr<SDL::State> sdl;
|
||||
#endif
|
||||
static std::unique_ptr<CemuhookUDP::State> udp;
|
||||
static std::shared_ptr<GCAdapter::Adapter> gcadapter;
|
||||
static std::shared_ptr<GCButtonFactory> gcbuttons;
|
||||
static std::shared_ptr<GCAnalogFactory> gcanalog;
|
||||
|
||||
void Init() {
|
||||
gcbuttons = std::make_shared<GCButtonFactory>();
|
||||
gcadapter = std::make_shared<GCAdapter::Adapter>();
|
||||
gcbuttons = std::make_shared<GCButtonFactory>(gcadapter);
|
||||
Input::RegisterFactory<Input::ButtonDevice>("gcpad", gcbuttons);
|
||||
gcanalog = std::make_shared<GCAnalogFactory>();
|
||||
gcanalog = std::make_shared<GCAnalogFactory>(gcadapter);
|
||||
Input::RegisterFactory<Input::AnalogDevice>("gcpad", gcanalog);
|
||||
|
||||
keyboard = std::make_shared<Keyboard>();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue