wesnoth/data/ai/lua/dummy_engine_lua.lua
Celtic Minstrel 1d7c1c74f6 Improve backwards compatibility for Lua AI
This changes the following:
- Fixes the experimental AI, without changing any of its code except for that in the [engine] tag
- Returns a dummy self from the dummy Lua engine, so that external CAs are more easily switched to using [params]
- Changes the order in which parameters are passed to AI component code. The order is now:
        state/self,    params,    data
2016-03-22 07:22:22 -07:00

12 lines
389 B
Lua

--! #textdomain wesnoth
-- This is the engine used by the Lua AI when no engine is
-- defined specifically in the [side] tag
-- This provides a cache level for the move map functions,
-- making them a bit easier to use
local ai_stdlib = wesnoth.require('ai/lua/stdlib.lua')
ai_stdlib.init(ai)
-- This is only returned for minor backwards compatibility
local p, d = ...
return {data = d}