Commit graph

138 commits

Author SHA1 Message Date
mattsc
a96487a837 AI: move default algorithm definition from C++ to WML
Among other things this now allows defining cores that have a different default AI.
2018-12-18 06:55:16 -08:00
Celtic Minstrel
23aac4f72f Cleanup of fef953a48e
- Fix the rabbit AI
- Enable invoke_synced_command to also call (some) built-in commands
  and give an error message in the case of an unknown command
- Remove some unnecessary implementation details
2018-03-17 16:48:00 -04:00
gfgtdf
fef953a48e remove ai.synced_command
fixes #1649 . ai.synced_command could easily be used to implement all types of
undeteced cheats so it was removed. As a replacement this commit adds a
[custom_command] synced command that just calls
wesnoth.game_events.on_synced_command which calls a lua handler that
must first be set.
2018-03-16 13:43:05 +01:00
Alexander van Gessel
39c3f21b9b Add testcase for tiled story backgrounds 2018-02-07 18:53:31 +01:00
Charles Dang
659e482e01 Moved eras files back to multiplayer/ since its movement caused errors in replays pre-move 2016-09-11 10:23:53 +11:00
Charles Dang
3cb8878b9a Fix duplicate loading of eras in mp
This fixes warnings about the era macros being redefined without being #undef-ed when
loading MP.
2016-08-30 19:39:00 +11:00
Celtic Minstrel
b295aab4ba Deprecate {MAGENTA_IS_THE_TEAM_COLOR}
The magenta colour is now the default flag_rgb colour if one is not specified.
2016-08-05 00:49:39 -04:00
Celtic Minstrel
ba5eb7bc91 Move some AI test scenarios from data/ to data/ai/scenarios/
(And update them to modern syntax)
2016-03-27 15:13:23 -04:00
mattsc
dd2d193cbd Remove move_to_targets test scenario
This was useful when the composite AI was introduced (in Wesnoth 1.7),
but does not serve a purpose any more now.
2016-03-24 10:56:45 -07:00
mattsc
be505342bf Lua AI test scenarios: rename files 2016-03-24 08:16:03 -07:00
gfgtdf
c2e1d71fc2 less config reloads
This removes a config reload when opening multiplayer or singleplayer
campaign selection screen after playign a campaign.

To do this we must make sure the default era for sp and for mp have the
same id becasue otherwise we might get an id not found error.
2015-06-18 16:21:28 +02:00
Charles Dang
f222744f4e Moved Tutorial textdomain and ifdef into its _main.cfg to avoid it being included twice 2014-12-31 05:49:50 +11:00
Charles Dang
799ac9d250 Don't include the tutorial's _main.cfg explicitly 2014-12-30 00:15:34 +11:00
Charles Dang
124d264f0e Gave the tutorial it's own _main.cfg 2014-12-30 00:05:30 +11:00
Chris Beck
489074b0a4 add --mp-tests option and preproc defines, and mp unit tests folder
These tests are meant to be run in a networked context to check for
OOS and similar.
2014-12-19 19:47:27 -05:00
Nathan Walker
0b3499cc66 Create a blank era for sp
Also, moved the "Custom" mp side to be loaded outside of the MULTIPLAYER define.
2014-07-13 15:25:20 -05:00
Nathan Walker
5a9da1aeaf Integrate create_engine into sp campaign selection
After campaign selection, the mp codepath is followed starting with
enter_configure_mode().
Code for sorting and marking completed campaigns, as well as for difficulty selection, has been moved to create_engine.
Also, [scenario] tags are now converted to [multiplayer] for sp as in mp.

Conflicts:
	src/game_controller.cpp
	src/multiplayer.cpp
2014-07-13 15:25:20 -05:00
Ignacio R. Morelle
cc6766d12b wmlindent pass on data/
data/test/ excluded for now.
2014-07-02 21:43:02 -04:00
Chris Beck
91d545c7d7 fixup test directory
C++ tests load from /data/test/ again, and the _main includes in
data/ and data/test/ are fixed up to accomodate this.

This fixes up cc138a4ed9
2014-05-12 11:43:55 -04:00
Chris Beck
0797abd9ea add WML unit test examples, and include the test directory
add some trivial tests, and the _main.cfg files to ensure they are included
2014-04-08 18:09:32 -04:00
Espreon
3f20785d02 Split all of the AI-related strings (except for the AI controller's) into a new 'wesnoth-ai' textdomain. Includes a pot-update for 'wesnoth' as a side effect. 2013-05-22 22:19:43 -04:00
Matthias Schoeck
b138e47184 Introduce 18 different Micro AIs.
This includes the [micro_ai] tag, the code for the Micro AI engines
and 14 test scenarios.  Full documentation at
http://wiki.wesnoth.org/Micro_AIs
2012-12-29 20:05:55 +00:00
Simon Forsyth
3d205a4b57 Move test/set for NO_TERRAIN_GRAPHICS...
...before loading core since core/_main.cfg cares if it is set
2012-12-13 03:14:13 +00:00
Dmitry Kovalenko
b207a1b1ca LuaAI: the need to define an engine is now deprecated.
All CAs can be store in external .lua files. If the scenario config
lacks an [engine] tag for the Lua AI engine, but still tries to use CA
with engine=lua, a dummy engine will be automatically generated,
providing the needed functionality
2012-06-12 12:36:06 +00:00
Silas Brill
666946a384 Add enter_hex and exit_hex events
Replaces patch #3186 (movethrough event)
Completes bug #8166 (feature request for moveover event)

Besides adding the new events, this patch changes fog clearing and
sighted events to occur during movement instead of at the start and
end of movement, respectively.
2012-05-01 04:00:58 +00:00
Alexander van Gessel
532ff83ef2 Un-hardwire the [language] block in data/hardwired/english.cfg.
Move the file out of that dir
2010-12-27 11:27:15 +01:00
Nils Kneuper
bc1d7ec1a5 create textdomain wesnoth-help (part3)
load the textdomain ingame

change the textdomain for some relevant files
2010-12-22 11:36:22 +00:00
Steven Panek
ffe86ab2f0 Corrected a grammatical error. 2010-11-22 17:47:58 +00:00
Fabian Müller
22de76b664 Reverted the exclusion of scenarios if multiplayer is loaded.
This had lead to the campaign list being empty when a player loads
multiplayer and enters the campaign menu again.
2010-09-02 10:00:25 +00:00
Fabian Müller
45525de0b4 Excluded the mainline campaigns from the multiplayer wml tree loading. 2010-08-31 23:08:12 +00:00
Ali El Gariani
0c59428b30 Disable terrain-graphics when NO_TERRAIN_GFX is defined.
Activated by TITLE_SCREEN (auto defined when starting title screen)
and now also by NO_GUI.
2010-07-29 20:21:37 +00:00
Ali El Gariani
2727c9d08a Rename MAIN_MENU as TITLE_SCREEN (as in source and also less ambiguous). 2010-07-25 01:34:33 +00:00
Ali El Gariani
3891da6a92 Show the main menu several times faster...
...by skipping terrain rules (useless there)

This also speed up the use of '--load'. Add a new define MAIN_MENU for
this.
2010-07-25 01:24:59 +00:00
Iurii Chernyi
f9b0fdb1f5 Lua AI: redesign, simplified usage, added lua_ai test scenario 2010-02-21 12:24:31 +00:00
Fabian Müller
cadf6854a6 Removed the reference to a deleted test scenario file. 2009-09-05 13:55:02 +00:00
Iurii Chernyi
717eca7428 new test scenario: move_to_targets, for AI improvement 2009-09-02 21:20:55 +00:00
Iurii Chernyi
09223f03cc new AI configuration syntax. Note: boost 1.35 required for compilation 2009-08-01 14:17:15 +00:00
Alexander van Gessel
f1f74fd609 Multiple-leaders fix:
...if the first leader you see isn't on a castle, check for others.
2009-07-20 03:21:44 +01:00
Alexander van Gessel
4ca5e565cf Move advanced_preferences to their own file. 2009-07-15 04:26:35 +01:00
Alexander van Gessel
008449f951 Apply patch #1192, fixing bug #13626.
(no option for save deletion confirmation)
2009-07-15 04:26:17 +01:00
Iurii Chernyi
5652b111c0 optional new-style AI configs...
...and generation of AI lists in multiplayer from files
2009-06-28 13:01:41 +00:00
Fabian Müller
235fb7af16 Added a test scenario for the lua interpreter. 2009-04-22 20:33:36 +00:00
Gunter Labes
7521ea90e3 only load the test scenarios when we're in test mode 2009-04-19 21:07:47 +00:00
Iurii Chernyi
52d15a17aa AI Arena - interactive AI testing framework 2009-03-31 13:49:34 +00:00
Jérémy Rosen
a81013ff9d added a very basic poison handling.
This is a proof of concept to be improved on. Patch by Velory
2009-03-27 15:49:22 +00:00
Nils Kneuper
3e42662bc0 really remove the python ai stuff (the advanded prefs option this time) 2009-02-23 22:35:02 +00:00
Tomasz Śniatowski
b9198d41ec Make the scroll behavior change from 2008-11-21T21:05:43Z!kailoran@gmail.com...
...(that fulfilled fr #12604) optional, changeable in advanced
preferences. Defaults to old behavior, fixing bug #13046.

New string added for the advanced preference.
2009-02-22 13:43:44 +01:00
Nils Kneuper
b3d391398a fix translations for ANL, now they even work ;) 2009-01-14 20:41:24 +00:00
Patrick Parker
c81ae6895b new advanced preference to choose whether middle-click scrolls...
...or warps (default=scrolls)
2009-01-05 04:47:48 +00:00
Tomasz Śniatowski
6652333b53 do not include the userdata campaigns folder in editor,
...seems to be included elsewhere already and causes duplicates. Bug
spotted by shadowmaster.
2008-11-24 20:47:02 +01:00