437 Commits

Author SHA1 Message Date
Guillaume Melquiond
0f74f8c791 Detected invalid locations before they are passed to the pathfinder.
(Fix for bug #17448.)
2011-01-15 09:52:26 +00:00
Mark de Wever
ecbabea838 New year copyright update. 2011-01-01 15:57:50 +00:00
Guillaume Melquiond
18dbb93dbf Removed wesnoth.register_theme_item and replaced...
...it by metamethods of wesnoth.theme_items.
2011-01-01 06:17:38 +00:00
Guillaume Melquiond
3ec734ba75 Removed separation between unit reports and game status reports,
since testing shows that game status is invalidated almost each time
unit is.
2011-01-01 06:17:31 +00:00
Guillaume Melquiond
5dd12a5595 Changed theme item handling to a wesnoth.theme_items table,
so that it is similar to wesnoth.wml_actions.  The
wesnoth.register_theme_item function is still used to cause report
generators to show up in the table.
2010-12-31 16:01:03 +00:00
Guillaume Melquiond
7489173eaa Added Lua accessor for the unit displayed in the sidebar. 2010-12-31 16:00:56 +00:00
Guillaume Melquiond
63331eace3 Removed class reports::report_data. 2010-12-31 16:00:53 +00:00
Guillaume Melquiond
0188250ece Fixed game configuration not being reset when starting a new game. 2010-12-28 19:49:07 +00:00
Guillaume Melquiond
8fd96c119c Changed __shallow_literal field so that it returns unaltered...
...[insert_tag] children.
2010-12-28 15:09:35 +00:00
Mark de Wever
f1f1fae70b Fix a compiler warning. 2010-12-27 20:37:48 +00:00
Anonymissimus
b6f48db20e adds wesnoth.clear_messages
(useful after outputting big tables in the chat window)
2010-12-27 20:17:10 +00:00
Guillaume Melquiond
db4ff78b99 Passed viewing side and displayed unit to theme functions,
...since these data cannot be recovered easily.
2010-12-26 20:01:16 +00:00
Guillaume Melquiond
6726504fa3 Added wesnoth.get_mouseover_tile function. 2010-12-26 20:01:13 +00:00
Guillaume Melquiond
02d1772101 Added wesnoth.register_theme_item...
...for setting custom drawing functions for theme widgets (e.g., turn
number, countdown, unit status, and so on).
2010-12-26 20:01:07 +00:00
Guillaume Melquiond
634d6fe885 Improved wesnoth.synchronize_choice so that AI handling comes for free. 2010-12-26 11:35:10 +00:00
Guillaume Melquiond
669d1dd8b0 Added a wesnoth.transform_unit function. 2010-12-26 11:35:04 +00:00
Guillaume Melquiond
6c9c16f730 Added missing comment. 2010-12-26 11:35:00 +00:00
Guillaume Melquiond
fdd00009ea Added a get_image_size function for querying the...
...width and height of an image. (Fix for bug #17387.)
2010-12-24 08:07:18 +00:00
Guillaume Melquiond
a7f8fed3a5 Fixed comments. 2010-12-24 08:07:14 +00:00
Guillaume Melquiond
070691747d Readded math.random, since there is no similar function...
...for use in AIs and synchronized code.
2010-12-18 10:24:48 +00:00
Ignacio R. Morelle
2dc0f300f8 Make [select_unit] highlight= (def. yes) work as intended...
...for displaying the selected unit's reach (bug #16819)
2010-12-08 02:04:06 +00:00
Guillaume Melquiond
460ce60bc3 Fixed valid field not properly detecting removed units. 2010-11-27 09:09:09 +00:00
Ignacio R. Morelle
0304b32166 Fix strict compilation due to 2010-11-08T03:02:01Z!anonymissimus@arcor.de
Fixes the following compiler error:

src/scripting/lua.cpp:1565: error: suggest parentheses around ‘&&’ within ‘||’

I hope to have got the logic right here. Anonymissimus should confirm.
2010-11-08 04:57:23 +00:00
Anonymissimus
49dd63414b Fixed [capture_village] being able to set village ownership...
...to a side without a leader.
2010-11-08 03:02:01 +00:00
Guillaume Melquiond
54aa4ad654 Fixed array underflow introduced by 2010-11-06T23:43:53Z!terraninfo@terraninfo.net. 2010-11-07 08:22:50 +00:00
Iurii Chernyi
c30997182e standard side filter 2010-11-06 23:43:53 +00:00
Guillaume Melquiond
ae289c17fa Added a Lua on_event callback. 2010-11-01 18:32:48 +00:00
Steven Panek
ea3c006195 'hilight' -> 'highlight' in [select_unit]-related code. 2010-11-01 03:36:10 +00:00
Guillaume Melquiond
181494eb43 Removed usage of two separate numeric types for attribute values.
(Fix for bug #16950.)
2010-10-25 19:48:27 +00:00
Ignacio R. Morelle
31c3fc7ddc Expose .hilight_hex and .select_hex methods in Lua
These correspond to their display/game_display equivalent member
methods, highlight_hex() and select_hex().
2010-10-18 03:16:57 +00:00
Guillaume Melquiond
c68ee23836 Avoided integer check since there is an automatic demotion...
...of floating-point values.
2010-10-10 12:31:19 +00:00
Guillaume Melquiond
c7cdd9a65b Added Lua accessor for unit [variables] toplevel fields. 2010-10-10 12:31:17 +00:00
Guillaume Melquiond
c3f2f750bb Added a delay Lua function. 2010-10-02 06:28:53 +00:00
Guillaume Melquiond
c76f453a07 Fixed inverted placement values. 2010-09-25 16:45:24 +00:00
Guillaume Melquiond
c4318c56fe Added a 'valid' field to units. 2010-09-24 18:34:59 +00:00
Anonymissimus
9d239c4ea6 Epanded wesnoth.set_terrain to accept optional 4th (layer) and 5th (replace_if_failed) arguments. Allows for moving [terrain] to lua. 2010-09-24 18:26:28 +00:00
Guillaume Melquiond
910ed59223 Added Lua accessors for side controllers. 2010-09-24 18:17:16 +00:00
Guillaume Melquiond
f42210242d Reverted 2010-09-23T21:31:40Z!anonymissimus@arcor.de as it allows buffer underflow.
Properly fixed the original issue.
2010-09-24 17:49:58 +00:00
Anonymissimus
ecf812f22d Fixed wesnoth.is_enemy returning wrong results. (patch #1981 by FAAB) 2010-09-23 21:31:40 +00:00
Mark de Wever
4446686e0c Fix compilation with GUI2_EXPERIMENTAL_LISTBOX. 2010-09-05 12:24:21 +00:00
Guillaume Melquiond
eeb047de55 Fixed file headers so that they match the content of the COPYING file. 2010-09-01 21:12:38 +00:00
Guillaume Melquiond
dffc37a57f Marked [illuminated_time] and [terrain_graphics] as handled at scenario level. 2010-09-01 19:24:43 +00:00
Guillaume Melquiond
bac01f08aa Marked [era] as a known scenario tag. 2010-08-31 20:38:15 +00:00
Guillaume Melquiond
f95ea39cf3 Reverted 2010-08-29T13:24:06Z!guillaume.melquiond@gmail.com,
...since the animation cache is no longer meant to be filled from WML.
2010-08-29 20:50:51 +00:00
Mark de Wever
b21f23db09 Remove duplicate definitions of string_map.
Issue spotted by cppcheck.
2010-08-29 20:13:31 +00:00
Guillaume Melquiond
12df7c16f1 Avoided redundant test and cleaned the stack. 2010-08-29 13:24:08 +00:00
Guillaume Melquiond
4d0c03eac2 Added game_events.on_missing_anim callback...
...for querying unit animation modifications.
2010-08-29 13:24:06 +00:00
Guillaume Melquiond
1d92772fff Unmarked [teleport] as handled. 2010-08-28 19:49:31 +00:00
Guillaume Melquiond
b8cbcf0ca9 Improved error handling a bit. 2010-08-28 19:39:01 +00:00
Guillaume Melquiond
0ee9bf51e1 Marked [story] tag as handled. 2010-08-28 19:01:29 +00:00