MCPcopy Create free account
hub / github.com/doldecomp/mkdd / getPadData

Function getPadData

src/Osako/PadMgr.cpp:63–89  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

61 }
62
63 void getPadData(u8 port, KartPadInput padInput, KartPadData *padData)
64 {
65 if (padInput == Input_Local)
66 {
67 if (port < 4)
68 {
69 s32 siType = JUTGamePad::getSIType(port);
70 switch (siType)
71 {
72 case SI_TYPE_GC:
73 {
74 KartGamePad::compress(JUTGamePad::getLGPosition(port), padData);
75 return;
76 }
77 case SI_GC_CONTROLLER:
78 case SI_GC_WAVEBIRD:
79 KartGamePad::compress(JUTGamePad::getPadStatus(port), padData);
80 return;
81 }
82 }
83 memset(padData, 0, sizeof(KartPadData));
84 }
85 else
86 {
87 NetGameMgr::ptr()->getKartPad(port, padData);
88 }
89 }
90
91 void setKartPadInput(KartPadInput padInput)
92 {

Callers 1

processKartPadFunction · 0.85

Calls 2

memsetFunction · 0.85
getKartPadMethod · 0.80

Tested by

no test coverage detected