[wesnoth-commits] [wesnoth/wesnoth] 59c9be: Schema: Add [candidate_action][filter_own]
Celtic Minstrel
noreply at github.com
Sun Sep 5 02:20:40 UTC 2021
Branch: refs/heads/master
Home: https://github.com/wesnoth/wesnoth
Commit: 59c9be12386abf074bcb472669241548c863259f
https://github.com/wesnoth/wesnoth/commit/59c9be12386abf074bcb472669241548c863259f
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/schema/ai/stage.cfg
Log Message:
-----------
Schema: Add [candidate_action][filter_own]
Commit: 9fdaea5893c6a780b1518c715bd5eff13cb3fa7f
https://github.com/wesnoth/wesnoth/commit/9fdaea5893c6a780b1518c715bd5eff13cb3fa7f
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/ai/micro_ais/cas/ca_stationed_guardian.lua
Log Message:
-----------
AI: Fix error in stationed_guardian
Commit: 477a871c212ff74e624857b57d00c89d5624ed89
https://github.com/wesnoth/wesnoth/commit/477a871c212ff74e624857b57d00c89d5624ed89
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 6bfe2647f5082292262a88d6940b5925b6a88dd2
https://github.com/wesnoth/wesnoth/commit/6bfe2647f5082292262a88d6940b5925b6a88dd2
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: a205e808459255750a25c8175216cfe80849fdf5
https://github.com/wesnoth/wesnoth/commit/a205e808459255750a25c8175216cfe80849fdf5
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M src/ai/lua/engine_lua.cpp
Log Message:
-----------
AI: Fix missing serialization code for sticky candidate actions
Commit: 880ef290759eaba82ab38cfcbea16f5e5e5f081b
https://github.com/wesnoth/wesnoth/commit/880ef290759eaba82ab38cfcbea16f5e5e5f081b
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/schema/units/single.cfg
M src/units/unit.cpp
Log Message:
-----------
AI: Support [unit][ai][micro_ai]
Commit: 9ad983378953afd3113c232ab2495e3e7567ea10
https://github.com/wesnoth/wesnoth/commit/9ad983378953afd3113c232ab2495e3e7567ea10
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 2c040ecaa7ddf8d6e6d1d9752ab690e4787f7407
https://github.com/wesnoth/wesnoth/commit/2c040ecaa7ddf8d6e6d1d9752ab690e4787f7407
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 440dbbd0ad35b24977207aadbed6ff42525cb164
https://github.com/wesnoth/wesnoth/commit/440dbbd0ad35b24977207aadbed6ff42525cb164
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 4837452dd78ae30b99671cdd4062454b3929c393
https://github.com/wesnoth/wesnoth/commit/4837452dd78ae30b99671cdd4062454b3929c393
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 644f5735da0289ea78ef6d9aece0db0d5f2703f0
https://github.com/wesnoth/wesnoth/commit/644f5735da0289ea78ef6d9aece0db0d5f2703f0
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 28d2ffae6ab8c4c9ff09f72130b81efcf65da8eb
https://github.com/wesnoth/wesnoth/commit/28d2ffae6ab8c4c9ff09f72130b81efcf65da8eb
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: fd8d11d42b3ce4b761770cd2e32c0954ba7fcdb4
https://github.com/wesnoth/wesnoth/commit/fd8d11d42b3ce4b761770cd2e32c0954ba7fcdb4
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M src/scripting/game_lua_kernel.cpp
Log Message:
-----------
Lua API: Fix an incorrect error message
Commit: 35fce3fa3b9920c77ee02affa74267b4845f2ed6
https://github.com/wesnoth/wesnoth/commit/35fce3fa3b9920c77ee02affa74267b4845f2ed6
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: bedc25fb56a274567cb8500645e0d27e4470d0d6
https://github.com/wesnoth/wesnoth/commit/bedc25fb56a274567cb8500645e0d27e4470d0d6
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/lua/location_set.lua
Log Message:
-----------
Lua API: location_set:to_pairs now returns named tuples
Commit: b22c3b595c13c8e4996552363fd0fd0b2408724a
https://github.com/wesnoth/wesnoth/commit/b22c3b595c13c8e4996552363fd0fd0b2408724a
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: e9465fa03eab15eece03b79d9762ff8e569d4742
https://github.com/wesnoth/wesnoth/commit/e9465fa03eab15eece03b79d9762ff8e569d4742
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/lua/functional.lua
Log Message:
-----------
Lua API: Add alternative version of map function to be used on arrays
Commit: ff6894cee8314fe14be8110482d84b7080bb3d19
https://github.com/wesnoth/wesnoth/commit/ff6894cee8314fe14be8110482d84b7080bb3d19
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 5d70dd9aca47ce95f412540217f987109388ca44
https://github.com/wesnoth/wesnoth/commit/5d70dd9aca47ce95f412540217f987109388ca44
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: 98b91c9d0f65efcebfca683db48ef42004f33522
https://github.com/wesnoth/wesnoth/commit/98b91c9d0f65efcebfca683db48ef42004f33522
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 2021)
Changed paths:
M data/lua/wml/micro_ai.lua
Log Message:
-----------
AI: [micro_ai]side= can now take a list
Closes #6023
Commit: 2d95c0f7d3f56af932716729cdbba0377bdd8cae
https://github.com/wesnoth/wesnoth/commit/2d95c0f7d3f56af932716729cdbba0377bdd8cae
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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: ce9bea053798f8bb8ad9e96a5d189c92e8acf523
https://github.com/wesnoth/wesnoth/commit/ce9bea053798f8bb8ad9e96a5d189c92e8acf523
Author: Celtic Minstrel <celtic.minstrel.ca at some.place>
Date: 2021-09-04 (Sat, 04 Sep 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/fc36971d6c1c...ce9bea053798
More information about the Commits
mailing list