Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 1455 for code


Ignore:
Timestamp:
May 28, 2008, 7:06:19 PM (16 years ago)
Author:
rgrieder
Message:
  • 'fixed' a bug in CppTcl.cc, but why would map::find pose a problem if the map is empty?
  • 'fixed' InGameConsole destructor: commented everything. We should probably use OverlayManager::destroyOverlay to delete the created overlay elements. Unfortunately that didn't work either. And I changed delete to delete[] for the list.
Location:
code/branches/network/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • code/branches/network/src/core/InputManager.cc

    r1446 r1455  
    662662      ConfigValueContainer* cont = getIdentifier()->getConfigValueContainer("CoeffPos");
    663663      assert(cont);
    664       cont->set(getConvertedValue<int, std::string>(i) + " "
    665         + getConvertedValue<float, std::string>(joySticksCalibration_[0].positiveCoeff[i]));
     664      cont->set(i, joySticksCalibration_[0].positiveCoeff[i]);
    666665
    667666      // negative coefficient
     
    676675      cont = getIdentifier()->getConfigValueContainer("CoeffNeg");
    677676      assert(cont);
    678       cont->set(getConvertedValue<int, std::string>(i) + " "
    679         + getConvertedValue<float, std::string>(joySticksCalibration_[0].negativeCoeff[i]));
     677      cont->set(i, joySticksCalibration_[0].negativeCoeff[i]);
    680678
    681679      // zero states
     
    697695      cont = getIdentifier()->getConfigValueContainer("Zero");
    698696      assert(cont);
    699       cont->set(getConvertedValue<int, std::string>(i) + " "
    700         + getConvertedValue<int, std::string>(joySticksCalibration_[0].zeroStates[i]));
     697      cont->set(i, joySticksCalibration_[0].zeroStates[i]);
    701698    }
    702699  }
  • code/branches/network/src/cpptcl/CppTcl.cc

    r1446 r1455  
    953953
    954954     {
     955          if (callbacks.size() == 0)
     956            return;
    955957          callback_map::iterator it = callbacks.find(interp);
    956958          if (it == callbacks.end())
  • code/branches/network/src/orxonox/console/InGameConsole.cc

    r1446 r1455  
    8686    InGameConsole::~InGameConsole(void)
    8787    {
    88         for (int i = 0; i < LINES; i++)
     88        /*for (int i = 0; i < LINES; i++)
    8989            if (this->consoleOverlayTextAreas_[i])
    90                 delete this->consoleOverlayTextAreas_[i];
     90                om_->destroyOverlayElement(this->consoleOverlayTextAreas_[i]);
    9191
    9292        if (this->consoleOverlayTextAreas_)
    93             delete this->consoleOverlayTextAreas_;
     93            delete[] this->consoleOverlayTextAreas_;*/
    9494    }
    9595
Note: See TracChangeset for help on using the changeset viewer.