Someone Posted December 22, 2012 Share Posted December 22, 2012 Error: Undefined variable: v HINT: You should always declare your variables before using them. However this error could be triggered as well if you made a typo in the variable name or you missed to call the global $var_name command. Error in evaluated code: ResultMessage (Translate("You found %d !Currency !",$v),false); Error in "F:/xampp/htdocs/nwe/libs/common.php(1140) : eval()'d code" Line 1 Error in F:\xampp\htdocs\nwe\libs\common.php Line 1140 Error in F:\xampp\htdocs\nwe\modules\explore\content.php Line 108 Error in F:\xampp\htdocs\nwe\libs\common.php Line 554 Error in F:\xampp\htdocs\nwe\index.php Line 316 Please help us to improve the game by providing as much information regards any bugs. ----############################ Error: Undefined variable: v HINT: You should always declare your variables before using them. However this error could be triggered as well if you made a typo in the variable name or you missed to call the global $var_name command. Error in evaluated code: ResultMessage (Translate("You found %d !Currency !",$v),false); Error in "F:/xampp/htdocs/nwe/libs/common.php(1140) : eval()'d code" Line 1 Error in F:\xampp\htdocs\nwe\libs\common.php Line 1140 Error in F:\xampp\htdocs\nwe\modules\explore\content.php Line 108 Error in F:\xampp\htdocs\nwe\libs\common.php Line 554 Error in F:\xampp\htdocs\nwe\index.php Line 316 Please help us to improve the game by providing as much information regards any bugs. -----################################### 1st time I went to explore in the welcome page, went to a bath, clicked choose another path (path 2), and clicked on the big rock on the map. 2nd time I did the same, digging on the map worked 3 times, beofre the error came up. I have not modified the explore module in any way Quote Link to comment Share on other sites More sharing options...
The Phantom Posted December 22, 2012 Share Posted December 22, 2012 Do you mean bath or path? I went to explore in the welcome page, went to a bath, clicked choose another path (path 2), and clicked on the big rock on the map. Quote Link to comment Share on other sites More sharing options...
Someone Posted December 22, 2012 Author Share Posted December 22, 2012 (edited) LOL for sure I meant bath :) Any hows, I'll dig into it a bit and try to see what causes this. It has happened a few more times. The path type seems to have nothing to do with it anyways. EDIT: This is the explorations table record, causing the problem id: 7 type id: 2 description: Translate("You found %d !Currency !",$v) code: $v=rand(2,10)*1;/*rnd*/$userStats["!Currency"]->value+=$v; EDIT 2 The bug is also present in the demo of the game Also noticed an error in the bottom of pages in the engine demo Fatal error: Call to undefined function error_get_last() in /www/new_worlds/demo/libs/common.php on line 1147 Edited December 22, 2012 by Someone Quote Link to comment Share on other sites More sharing options...
Djkanna Posted December 24, 2012 Share Posted December 24, 2012 (edited) LOL for sure I meant bath :) Any hows, I'll dig into it a bit and try to see what causes this. It has happened a few more times. The path type seems to have nothing to do with it anyways. EDIT: This is the explorations table record, causing the problem id: 7 type id: 2 description: Translate("You found %d !Currency !",$v) code: $v=rand(2,10)*1;/*rnd*/$userStats["!Currency"]->value+=$v; EDIT 2 The bug is also present in the demo of the game Also noticed an error in the bottom of pages in the engine demo Fatal error: Call to undefined function error_get_last() in /www/new_worlds/demo/libs/common.php on line 1147 Until a better way is implemented (I imagine A_Bertrand is on holiday now, so I'm guessing January is when he'll be back) In libs/common.php. Line: 1137 Replace global $evalCode, $userStats, $modules, $allModules, $db, $content; with global $evalCode, $userStats, $modules, $allModules, $db, $content, $v; EDIT: - Scratch that. Probably a more appropriate way would be to do the following. modules/explore/content.php Lines:100 to 109 Replace: /** * Evaluate the code to run. */ if ($result->fields[1] != "") NWEval($result->fields[1]); /** * Evaluate the message to give back. */ NWEval("ResultMessage (" . $result->fields[0] . ",false);"); $result->Close(); With: /** * Evaluate the code to run. */ $eval = ''; if ($result->fields[1] != "") $eval .= $result->fields[1]; /** * Evaluate the message to give back. */ $eval .= 'ResultMessage ('.$result->fields[0].', false);'; NWEval($eval); $result->Close(); Edited December 24, 2012 by Djkanna Quote Link to comment Share on other sites More sharing options...
Someone Posted December 24, 2012 Author Share Posted December 24, 2012 Thanks that works fine Quote Link to comment Share on other sites More sharing options...
a_bertrand Posted January 4, 2013 Share Posted January 4, 2013 Will check that on Monday. Thanks for the report. Quote Link to comment Share on other sites More sharing options...
a_bertrand Posted January 7, 2013 Share Posted January 7, 2013 Ok issue fixed. This bug was introduced by the release 1.1.4, but that should now work if you update your modules. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.