A simple external AI Lua error
Moderator: Forum Moderators
A simple external AI Lua error
I'm working AI project for school that involves reinforcement learning. I use wesnoth as a test environment. The project interfaces to wesnoth using Lua. I tried the Lua interface from another repository and it all works fine except for the most basic CA that supposed to just pass the turn:
This seems to generate an error
I searched high and low and read through the creating custom AI manual on this site, but I can't seem to find a clue yet. Any help will be greatly appreciated.
Code: Select all
local ca_pass = {}
function ca_pass:evaluation()
return 999980
end
function ca_pass:execution(cfg, data)
end
return ca_pass
Code: Select all
attempt to index a nil value
-
- Posts: 488
- Joined: August 4th, 2019, 5:27 pm
- Contact:
Re: A simple external AI Lua error
It usually says where it's attempted to index a nil value, a trace with line numbers. Could you provide one? It would help finding the causeib2002 wrote: ↑May 24th, 2022, 12:34 am This seems to generate an errorCode: Select all
attempt to index a nil value
Co-founder and current maintainer of IsarFoundation, Afterlife Rated and overall Wesnoth Autohost Project
Developer and maintainer of my fork of World Conquest, Invincibles Conquest II
Developer and maintainer of my fork of World Conquest, Invincibles Conquest II
- Celtic_Minstrel
- Developer
- Posts: 2274
- Joined: August 3rd, 2012, 11:26 pm
- Location: Canada
- Contact:
Re: A simple external AI Lua error
I'm pretty sure the code you posted cannot cause that error. We need more information.