
And then, I tried to restart with ./openttd -d ai=5. Now the console said :
dbg: [ai] ERROR: HasNext() is invalid as Begin() is never called
for me, (maybe other too


So, the suggestion is :
1. the error message is included with the line number
2. the error message displayed in the debug panel
The misstyped code is similiar like this (error on line 5)
Code: Select all
local list = AIList();
for(local i = list.Begin(); list.HasNext(); i = list.Next()){
//do some stuff
local list2 = AIList();
for(local i = list.Begin(); list2.HasNext(); i = list2.Next()){
//do some stuff that make a further decission
// as the looping is not give the actual value of .Next() , the decission is never made
}
}
And.. correct me if that was just because my miss understanding of squirrel/API

