Page 1 of 1

I get lots of Lua errors and

Posted: 22 Apr 2017, 01:49
by tankcommander
Hello.

When trying to play Spring 1944 with the recommended AI "C.R.A.I.G.", the AI never captures any flag. I get lots of Lua errors when running the game displayed in the game screen and in the local, which I believe that may be related. My question is: how can I fix these errors?

I downloaded Spring and Springlobby. I compliled Spring following the instructions of https://springrts.com/wiki/Building_Spring_on_Linux . I used "cmake -DCMAKE_INSTALL_PREFIX=~/spring . -DAI_TYPES=NATIVE". and then "make -j2 && make install" because I do not want to install more dependencies than necessary (In this case, the JDK for non-native AIs).

Note that Spring gets installed to a local directory. I configured SpringLobby with the correct path to the "spring" executable and "libunitsync.so" shared library. Moreover, I set "PATH" and "LD_LIBRARY_PATH" so as to include the [etc]/bin and [etc]/lib directories found in the install path of the Spring engine.

I have attached the infolog.txt file in case it helps.

Thanks.

Re: I get lots of Lua errors and

Posted: 22 Apr 2017, 06:33
by gajop
You haven't attached infolog.txt . And you also shouldn't try creating multiple duplicate topics (as they won't get approved).

Re: I get lots of Lua errors and

Posted: 22 Apr 2017, 08:45
by yuritch
Which versions of engine and S44 are you using?

Re: I get lots of Lua errors and

Posted: 22 Apr 2017, 17:02
by tankcommander
I am using Spring engine 103.0 and Spring 1944 2.0. I attached the infolog.txt now.

I accidentally sent the same post twice because I pressed "back" to see my message and then "submit" a second time.

Re: I get lots of Lua errors and

Posted: 22 Apr 2017, 17:47
by yuritch
Spring1944 2.0 is not compatible with engine versions greater than 100.0.

Please use a dev build of Spring:1944. You can join any of S44 dev autohosts to auto-download it.

Re: I get lots of Lua errors and

Posted: 23 Apr 2017, 03:08
by tankcommander
Thanks for your reply.

I tried with the version "test-4909-d25e4ff" I get Lua errors again, and now the "C.R.A.I.G" AI does nothing but shooting at enemy units that become within range, which I assume, is due to the Unit AI. Moreover, the bot does not take the faction that I designate for it. Please see the attached infolog.txt.

I also tried downloading the latest version from the repository directly (d25e4ff) and placing the files in "~/.spring/games" and I get the same error.

Code: Select all

[f=-000001]Loading Skirmish AIs
[f=-000001] [Texture] Warning: [LoadAndCacheTexture] could not load texture "" from model "objects3d/jpnteke_build.s3o"
[f=-000001] [widgets.lua] Error: false
[f=-000001] [widgets.lua] Error: Error in DrawWorld(): [string "LuaUI/Widgets/gui_faction_change.lua"]:188: attempt to concatenate local 'side' (a nil value)
[f=-000001] [widgets.lua] Error: Removed widget: Faction Change
[f=-000001] Reloading GUI config from file: panel.txt

Re: I get lots of Lua errors and

Posted: 24 Apr 2017, 12:10
by yuritch
Your Intel gfx card isn't capable of handling some of the engine gfx needs, which caused those errors:

Code: Select all

Error: [CreateProgramObject] Tried to create "treeNearDefShaderARB" a ARB shader program on hardware w/o support for it!
If it still runs then they can be ignored.

This one error:

Code: Select all

[widgets.lua] Error: Error in DrawWorld(): [string "LuaUI/Widgets/gui_faction_change.lua"]:188: attempt to concatenate local 'side' (a nil value)
is most likely caused by running spring binary directly. You should use springlobby single player mode because that creates all the needed initialization scripts.

The AI is sadly broken at the moment.

Otherwise the log looks rather good.

Re: I get lots of Lua errors and

Posted: 25 Apr 2017, 03:53
by tankcommander
yuritch wrote:Your Intel gfx card isn't capable of handling some of the engine gfx needs, which caused those errors:... If it still runs then they can be ignored.
Ok.
yuritch wrote:This one error:

Code: Select all

[widgets.lua] Error: Error in DrawWorld(): [string "LuaUI/Widgets/gui_faction_change.lua"]:188: attempt to concatenate local 'side' (a nil value)
is most likely caused by running spring binary directly. You should use springlobby single player mode because that creates all the needed initialization scripts.
I run it through SpringLobby. Not only is the AI broken, it also uses a faction other than the one I selected from it. Apparently, it is selected at random. What can I do about it?

Thanks.

Re: I get lots of Lua errors and

Posted: 01 May 2017, 22:29
by yuritch
Thanks to FLOZi, CRAIG is now fixed. I tested on map 1944_Road_To_Rome_v3 (this has a flag profile so the AI plays a little better) and it works.