Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 9840 for code/branches/wiimote


Ignore:
Timestamp:
Dec 2, 2013, 2:38:52 PM (11 years ago)
Author:
georgr
Message:

made two things static to fix everything

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/wiimote/src/libraries/core/input/InputManager.cc

    r9838 r9840  
    228228    {
    229229
    230         CWii wii; // Defaults to 4 remotes
     230
     231
     232        static CWii wii; // Defaults to 4 remotes; static because else it will get deleted during InternalReload
    231233        std::vector< ::CWiimote>::iterator i;
    232234        int reloadWiimotes = 0;
     
    234236
    235237        // Find and connect to the wiimotes
    236         std::vector<CWiimote>& wiimotes = wii.FindAndConnect(10);
     238        static std::vector<CWiimote>& wiimotes = wii.FindAndConnect(10); //CWiimotes are kept in here in case of InternalReload calls
    237239        if (!wiimotes.size())
    238240        {
Note: See TracChangeset for help on using the changeset viewer.