Error when stopped research

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Error when stopped research

      Hello mate ;)
      I have error when i stoped research

      Message: Undefined offset: 106
      File: /includes/pages/game/ShowResearchPage.class.php
      Line: 61
      PHP-Version: 5.4.45
      PHP-API: cgi-fcgi
      2Moons Version: 1.9.git
      Debug Backtrace:
      #0 /includes/pages/game/ShowResearchPage.class.php(61): errorHandler(8, 'Undefined offse...', 'FILEPATH ...', 61, Array)
      #1 /includes/pages/game/ShowResearchPage.class.php(342): ShowResearchPage->CancelBuildingFromQueue()
      #2 /game.php(57): ShowResearchPage->show()
      #3 {main}


      Source Code

      1. $elementId = $USER['b_tech_id'];
      2. $costResources = BuildFunctions::getElementPrice($USER, $PLANET, $elementId, false, $PLANET[$elementId] + 1);
      3. if($PLANET['id'] == $USER['b_tech_planet'])
      4. {
      5. if(isset($costResources[901])) { $PLANET[$resource[901]] += $costResources[901]; }
      6. if(isset($costResources[902])) { $PLANET[$resource[902]] += $costResources[902]; }
      7. if(isset($costResources[903])) { $PLANET[$resource[903]] += $costResources[903]; }
      8. }