[wesnoth-commits] [wesnoth/wesnoth] d1694c: Schema: Add [candidate_action][filter_own]
Celtic Minstrel
noreply at github.com
Mon Aug 16 12:37:11 UTC 2021
Branch: refs/heads/celmin
Home: https://github.com/wesnoth/wesnoth
Commit: d1694cd68d30be7d5602cc099ca925ea618236f7
https://github.com/wesnoth/wesnoth/commit/d1694cd68d30be7d5602cc099ca925ea618236f7
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/schema/ai/stage.cfg
Log Message:
-----------
Schema: Add [candidate_action][filter_own]
Commit: 013ef5d4b80850cb7586f829bae466abff594657
https://github.com/wesnoth/wesnoth/commit/013ef5d4b80850cb7586f829bae466abff594657
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/ai/micro_ais/cas/ca_stationed_guardian.lua
Log Message:
-----------
AI: Fix error in stationed_guardian
Commit: b7ff1b58913824c0ba77905dc87ce87254754194
https://github.com/wesnoth/wesnoth/commit/b7ff1b58913824c0ba77905dc87ce87254754194
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/schema/ai/_main.cfg
A data/schema/ai/micro.cfg
M data/schema/core/actionwml.cfg
M src/ai/configuration.cpp
M src/ai/lua/core.cpp
M src/ai/lua/core.hpp
M src/ai/lua/engine_lua.cpp
M src/ai/lua/engine_lua.hpp
M src/ai/manager.cpp
M src/ai/manager.hpp
Log Message:
-----------
AI: Support [side][ai][micro_ai]
Closes #5910
Commit: 5ed753a3c76ef932c97784b2ac2ff0a09781d13b
https://github.com/wesnoth/wesnoth/commit/5ed753a3c76ef932c97784b2ac2ff0a09781d13b
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M src/ai/manager.cpp
Log Message:
-----------
AI: Support [modify_side][ai][modify_ai]/[micro_ai]
Although there is little reason to do this in practice, there is merit in supporting all the same syntax in both places.
For example, if AI setup is defined as a macro, it could contain [modify_ai] tags.
This change means that placing that macro in [modify_side][ai] has the same effect as placing it in [side][ai].
Commit: 2bb4b0ee49d7ff46bf9172e68b5f1d15b6480de4
https://github.com/wesnoth/wesnoth/commit/2bb4b0ee49d7ff46bf9172e68b5f1d15b6480de4
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M src/ai/lua/engine_lua.cpp
Log Message:
-----------
AI: Fix missing serialization code for sticky candidate actions
Commit: 059fc51fb05c6d9dfb5c4259fa9fa81f8008f419
https://github.com/wesnoth/wesnoth/commit/059fc51fb05c6d9dfb5c4259fa9fa81f8008f419
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/schema/units/single.cfg
M src/units/unit.cpp
Log Message:
-----------
AI: Support [unit][ai][micro_ai]
Commit: d7459b66f26d401e58ef4e48f66eb38bd1412c35
https://github.com/wesnoth/wesnoth/commit/d7459b66f26d401e58ef4e48f66eb38bd1412c35
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/schema/units/single.cfg
M src/units/unit.cpp
Log Message:
-----------
AI: Support [unit][ai][candidate_action]
This is essentially a syntax sugar for adding a candidate action filtered to only run for that single unit.
Commit: 0687d0cfcc761fe76db464a52b25cc08ccecc2af
https://github.com/wesnoth/wesnoth/commit/0687d0cfcc761fe76db464a52b25cc08ccecc2af
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/ilua.lua
Log Message:
-----------
Lua: Fix console pretty-print output not showing zero or negative keys in tables
Commit: 4eb5d837377bc496b00e6b03ae9c2610529596cf
https://github.com/wesnoth/wesnoth/commit/4eb5d837377bc496b00e6b03ae9c2610529596cf
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/functional.lua
Log Message:
-----------
Lua API: The value function is now optional in functional.choose[_map]
By default, the functions now use the value taken directly from the map or array.
In addition, if a string or other non-functional value is passed, it's used as a key on the value.
Commit: 561a6de24d169cac86d1074a63a75e6f76f92a36
https://github.com/wesnoth/wesnoth/commit/561a6de24d169cac86d1074a63a75e6f76f92a36
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/location_set.lua
Log Message:
-----------
Lua API: Add new location_set function to convert to or from a Lua map
This enables a location set to be passed to map functions in the functional module.
Commit: 27f98aa8ab739201e64568e31ee5f4902458cd38
https://github.com/wesnoth/wesnoth/commit/27f98aa8ab739201e64568e31ee5f4902458cd38
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M src/ai/lua/engine_lua.cpp
Log Message:
-----------
Lua AI: Fix non-integer candidate evaluation scores being treated as 0
Commit: 1c550891b87571335e688e9ef37dca7ecdeb9de3
https://github.com/wesnoth/wesnoth/commit/1c550891b87571335e688e9ef37dca7ecdeb9de3
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M src/ai/actions.cpp
M src/ai/actions.hpp
Log Message:
-----------
AI: Fix assertion when trying to move to an off-map location
This could, for example, be triggered using ai.move().
Commit: 5aff756ae74230d23e1de4753b1f7760c97af3fd
https://github.com/wesnoth/wesnoth/commit/5aff756ae74230d23e1de4753b1f7760c97af3fd
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M src/scripting/game_lua_kernel.cpp
Log Message:
-----------
Lua API: Fix an incorrect error message
Commit: fab577b42df3c0f22aa825a4b6d4848d61c128d9
https://github.com/wesnoth/wesnoth/commit/fab577b42df3c0f22aa825a4b6d4848d61c128d9
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/core/map.lua
Log Message:
-----------
Lua API: Fix an error in the terrain hex API
Attempting to access a non-string key was an error.
Commit: 59a9990435cc61ac051535a0ebb02dfada63e206
https://github.com/wesnoth/wesnoth/commit/59a9990435cc61ac051535a0ebb02dfada63e206
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/location_set.lua
Log Message:
-----------
Lua API: location_set:to_pairs now returns named tuples
Commit: b5a5a3118c9aee17fda299093dfb058ef42b490f
https://github.com/wesnoth/wesnoth/commit/b5a5a3118c9aee17fda299093dfb058ef42b490f
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/functional.lua
Log Message:
-----------
Lua API: Fix functional.map returning the wrong answer if used on a table that contains numeric keys but is not strictly an array
Commit: 38d522dad281e82c7467c08f5475617b4241a366
https://github.com/wesnoth/wesnoth/commit/38d522dad281e82c7467c08f5475617b4241a366
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/functional.lua
Log Message:
-----------
Lua API: Add alternative version of map function to be used on arrays
Commit: e7c9e5ff4233b56da093dd497a893c1f85ca714a
https://github.com/wesnoth/wesnoth/commit/e7c9e5ff4233b56da093dd497a893c1f85ca714a
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/core/_initial.lua
Log Message:
-----------
Lua API: Add a wesnoth.type() function
This checks both the Lua type and the metatable type to return a single unified result.
Commit: f3744fb1597ccfdda7a17442d3933f5d1468ce39
https://github.com/wesnoth/wesnoth/commit/f3744fb1597ccfdda7a17442d3933f5d1468ce39
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/ai/lua/ai_helper.lua
Log Message:
-----------
Lua: Add a new ai_helper debug function to print a simulate_combat HP distribution more succinctly
Commit: 0bd679b11c8a5bf6b2b2c0a38ee2250b9736de77
https://github.com/wesnoth/wesnoth/commit/0bd679b11c8a5bf6b2b2c0a38ee2250b9736de77
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/lua/wml/micro_ai.lua
Log Message:
-----------
AI: [micro_ai]side= can now take a list
Closes #6023
Commit: aec6b52a8773a6646ee6a34cebf3ab182bf47508
https://github.com/wesnoth/wesnoth/commit/aec6b52a8773a6646ee6a34cebf3ab182bf47508
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
A data/ai/lua/ca_level_up_attack.lua
A data/ai/lua/ca_simple_scouting.lua
A data/ai/lua/opening.lua
A data/ai/scenarios/scenario-lua_ai_unit_actions.cfg
Log Message:
-----------
AI: Convert the FormulaAI example scenario to do all the same things using Lua
- Unit formulas are replaced by inline MicroAIs or candidate actions placed in the unit's [ai] tag.
- The stationed_guardian MicroAI was chosen as the closest match to the guardian FormulaAI. It's not a perfect fit, but it's pretty close.
- The goto and patrol MicroAIs are fairly obvious substitutes for the respective unit formulas.
- The priority test in unit formulas is replaced by fairly basic inline non-external CAs with differing scores.
- The side formulas (opening.fai) have been converted to a separate Lua stage using a new opening.lua. However, that's only a partial conversion. The move and attack functionalities of opening.fai are missing from opening.lua; instead the built-in move, move leader to keep, and combat CAs are used.
- The scouting FormulaAI CA has been ported to Lua. It remains a very basic AI, probably not well-suited to genera use.
- The level up attack FormulaAI CA has been ported to Lua. Like the new scouting CA, this is mostly intended to serve as an example.
Commit: 79ab9625630e3d235e11ea5a59b7a4c5c20c9bfa
https://github.com/wesnoth/wesnoth/commit/79ab9625630e3d235e11ea5a59b7a4c5c20c9bfa
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-08-16 (Mon, 16 Aug 2021)
Changed paths:
M data/ai/micro_ais/scenarios/The_Elves_Besieged.cfg
Log Message:
-----------
AI: Add an example of using [micro_ai] in [side][ai]
Compare: https://github.com/wesnoth/wesnoth/compare/fce7a7c64878...79ab9625630e
More information about the Commits
mailing list