SummerOfCodeProposal AI Improvement Crab AI Configuration

From The Battle for Wesnoth Wiki
Revision as of 20:58, 2 April 2009 by Crab (talk | contribs) (AI Configuration)

AI Configuration

First version of this class is already written and committed to Wesnoth.

The purpose of this class is to encapsulate all AI configuration options and deserialize them from a single config or from a file.

Current AI configuration options in team.cpp are a bit messy and inefficient (for example, set_time_of_day iterates through all parameters at the start of each turn and copies those parameters which are active to a new vector. Also, there is some duplication with some of the ai parameters. Also, current ai_memory implementation uses standard config class so it is inefficient to use it to work/modify a large amout of data). So, encapsulating all those details in a single class will allow to rework its internal details without changing all those pieces of code that depend on ai parameters.


--

return back to Summer Of Code Proposal of Crab