mirror of
https://github.com/wesnoth/wesnoth
synced 2025-04-27 18:01:41 +00:00

Besides them being unnecessary, a warning message is otherwise also displayed when external CAs are used and the game is not in debug mode.
23 lines
546 B
Lua
23 lines
546 B
Lua
--! #textdomain wesnoth
|
|
-- This is the engine used by the Lua AI when no engine is
|
|
-- defined specifically in the [side] tag
|
|
|
|
return {
|
|
get_ai = function(ai)
|
|
local my_ai = {}
|
|
|
|
local ai_stdlib = wesnoth.require('ai/lua/stdlib.lua')
|
|
ai_stdlib.init(ai)
|
|
|
|
-- Make the ai table available to the eval/exec functions
|
|
function my_ai:get_ai()
|
|
return ai
|
|
end
|
|
|
|
-- Make the persistent data table available to the eval/exec functions
|
|
my_ai.data = {}
|
|
|
|
return my_ai
|
|
end
|
|
}
|