Guillaume Melquiond
6487a3d046
Fixed segfault in the animation code caused by a triggered level end...
...
...required just before moving a unit with WML code after having
changed the objectives.
Objective display has been moved out of the animation code and into a
randomly-chosen function. The target function is probably not the most
sensible choice, but the upside is that it should be called at all the
important times.
2010-08-11 16:05:51 +00:00
Guillaume Melquiond
35bb8015c5
Moved preprocessing logic from the automaton to the token stack handler.
...
Fixed missing metadata for macro arguments that are neither quoted nor
parenthesized. Avoided outputting metadata for inlined quoted
strings.
2010-08-11 16:05:38 +00:00
Guillaume Melquiond
f85f0d66f9
Fixed unquoted string tokens not spanning embedded comments.
2010-08-11 09:04:50 +00:00
Jody Northup
c7f7f7fdf7
Allowed [get_global_variable] in start events for single player mode,
...
...but not for MP. As silene did with [message] in 2010-08-10T17:16:22Z!guillaume.melquiond@gmail.com.
2010-08-11 04:59:21 +00:00
Gabriel Morin
756c7b6099
Whiteboard/highlight_visitor: hide "real" unit on mouseover...
...
...when there's a destination ghost on the same hex.
2010-08-11 01:47:36 +00:00
Gabriel Morin
aa9c46b179
Whiteboard: each scoped unit map affector now completely restores...
...
...the previous none/normal/pathfind future unit map status on destruction.
2010-08-11 01:47:30 +00:00
Gabriel Morin
c41e31d15d
Whiteboard: tentatively hide units on mouseover...
...
...when you can plan a move to their current position because they
have a planned move.
2010-08-11 01:47:23 +00:00
Guillaume Melquiond
db47ced634
Allowed [message] in start events for single player mode.
...
To avoid replay issues, it forcefully quits the game in multiplayer
instead of displaying a WML error and continuing.
2010-08-10 17:16:22 +00:00
Guillaume Melquiond
c465da9277
Fixed name button overwriting the side list.
2010-08-10 16:05:54 +00:00
Guillaume Melquiond
42835b54d8
Delayed commit of the new unit config until...
...
...all the attributes of the old one have been handled, as the old
config may alias the current one, hence causing attribute values to be
loaded from the committed config.
2010-08-10 15:50:48 +00:00
Guillaume Melquiond
046e8b57d3
Prevented [facing] filters from returning the own unit.
...
(Fix for bug #16397.)
2010-08-10 15:24:50 +00:00
Guillaume Melquiond
49c0dbb3d2
Made progress for unit type building a bit more regular.
2010-08-10 12:40:08 +00:00
Jody Northup
361fc19909
used boost std types in the function prototypes,
...
(I thought I had committed this several weeks ago.)
2010-08-10 12:24:52 +00:00
Guillaume Melquiond
b8d6286dbd
Factorized and generalized the loadscreen progress counter.
...
The bar should now accurately reflect the loading time, and therefore
regularly progress.
The magic values are automatically generated in the 'loadscreen' log
domain and can be copy-pasted in the code if the current ones become
off.
2010-08-10 12:08:24 +00:00
Guillaume Melquiond
e4ca82489c
Replaced usage of get_union_rect by intersect_rects,
...
...as the function was actually computing the intersection of two
rectangles. Added a proper function for computing unions.
2010-08-10 12:08:19 +00:00
Guillaume Melquiond
46ab9253dd
Fixed compilation warning.
2010-08-10 12:08:15 +00:00
Jody Northup
4985f1cbe9
Persistent variables can now be retrieved from remote players...
...
...even when it is not their turn.
2010-08-10 10:48:40 +00:00
Gabriel Morin
c6f278cdb5
Whiteboard/validate_visitor: iterator reuse.
2010-08-10 05:15:58 +00:00
Gabriel Morin
b488a236e2
Whiteboard/validate_visitor: fix bad logic...
...
...that caused some invalid actions not to be deleted.
2010-08-10 05:15:52 +00:00
Gabriel Morin
9900254853
Whiteboard/validate_visitor: logging and a few extra asserts.
2010-08-10 05:15:46 +00:00
Gabriel Morin
1234196f01
Whiteboard: add offset to numbers when several actions happen on the same hex.
2010-08-10 05:15:41 +00:00
Gabriel Morin
01cd890e99
Whiteboard/manager: logging.
2010-08-10 05:15:35 +00:00
Gabriel Morin
21babbd501
Whiteboard/move: check that the planned action still targets...
...
...the same unit as before. Also, avoid a useless boolean evaluation.
2010-08-10 05:15:29 +00:00
Gabriel Morin
fc6ead3807
Whiteboard: restore my little hack to ensure the whiteboard...
...
...deactivates once the tab key is released.
2010-08-10 05:15:23 +00:00
Iurii Chernyi
871442bdc7
use units from resources::
2010-08-09 22:11:27 +00:00
Gabriel Morin
3863896e80
Whiteboard: allow out-of-turn recruit/recall planning.
...
Take future position of leader into account when determining
recruit/recall possibilities.
2010-08-09 22:04:44 +00:00
Iurii Chernyi
fb918b2e76
new type of AI goal : target_location
2010-08-09 21:39:59 +00:00
Guillaume Melquiond
d41e8cfeec
Erased target location before moving a unit. (Fix for bug #16391.)
2010-08-09 20:41:33 +00:00
Gabriel Morin
1179fbbca3
Whiteboard: add more conditions to block whiteboard activation...
...
...at critical moments.
2010-08-09 20:40:33 +00:00
Guillaume Melquiond
6a6b4ec39d
Optimized unit type creation by:
...
- delaying male and female creation until they are actually needed,
- removing their private config object.
As a side effect, it considerably reduces the memory usage of unit types.
2010-08-09 19:57:41 +00:00
Guillaume Melquiond
c36ced6467
Reduced amount of copying needed for handling unit types with a base.
2010-08-09 19:57:38 +00:00
Guillaume Melquiond
8373a90e87
Optimized config handling by comparing pointers...
...
...instead of strings when visiting the ordered children.
2010-08-09 19:57:31 +00:00
Guillaume Melquiond
0a996b70d5
Added function for splicing children between config objects.
...
This speeds up configuration loading by 50%.
2010-08-09 15:57:32 +00:00
Guillaume Melquiond
7ff1703a54
Fixed server chocking on unquoted attributes.
2010-08-09 12:33:21 +00:00
Guillaume Melquiond
f472a7d67a
Fixed segfault when using up and down keys.
...
Fixed keys not making it possible to go to the tip buttons.
Fixed useless and missing translatable strings.
2010-08-09 10:43:04 +00:00
Guillaume Melquiond
26b393eaed
Changed meaning of spaces in WML.
...
They are no longer significant, unless they are quoted or between two words.
2010-08-09 09:54:53 +00:00
Guillaume Melquiond
4ecf20cf9d
Avoided creation of temporary animations.
2010-08-09 09:03:03 +00:00
Guillaume Melquiond
abe279f034
Merged precedence into building rules,
...
...so as to avoid a useless copy/destruction at insertion time.
2010-08-09 06:39:49 +00:00
Ali El Gariani
dac5b09e14
Rename image::TYPE to something less misleading.
...
SCALED_TO_HEX is now just that, use TOD_COLORED to get ToD coloring.
2010-08-09 04:05:43 +00:00
Ali El Gariani
938cd8db3a
small readability improvements
2010-08-09 04:05:37 +00:00
Guillaume Melquiond
5049fdf19a
Performed all the substitution of rotation tokens (@R0-5) in one single pass.
...
This patch speeds up the creation of terrain rules by 40%.
2010-08-08 21:05:23 +00:00
Guillaume Melquiond
8d40b87f89
Avoided conversion of attribute values to translatable strings.
...
Optimized string escaping.
Fixed strange indentation of embedded textdomain changes.
Reduced amount of useless quotes and spaces.
This patch brings the time needed for outputting the cache for the
test scenario from 17% of the total time down to negligible.
2010-08-08 20:03:36 +00:00
Ali El Gariani
30c52fc7c5
Safer window-icon handling.
...
Kill set_wm_icon function, since SDL_WM_SetIcon can be called safely
only at one place. Clearly hardcode the image's url instead of
pretending that we use game_config. Rename the image to
"game-icon.png" (since you are forced to use it).
2010-08-08 18:33:48 +00:00
Ali El Gariani
8bc5a68a70
Fix an include path
2010-08-08 18:33:40 +00:00
Ali El Gariani
112ecf8dde
Temporarily revert 2010-08-04T03:22:04Z!alinkmaze@gmail.com...
...
...and only use the hardcoded application icon
(SDL_WM_SetIcon weirdly segfault)
2010-08-08 17:59:01 +00:00
Guillaume Melquiond
697ea7252c
Removed unused header.
2010-08-08 17:22:54 +00:00
Guillaume Melquiond
efbd8cc702
Fixed header dependencies.
2010-08-08 17:22:50 +00:00
Guillaume Melquiond
ea5b2445e6
Fixed t_string delegating to the improper copy constructor,
...
...the really slow one.
2010-08-08 16:46:56 +00:00
Guillaume Melquiond
4be292c05e
Added rule for generating assembly files.
2010-08-08 16:46:52 +00:00
Guillaume Melquiond
dc4b3bb2ef
Sped up child lookup by converting the value argument only once.
...
Avoided using a translatable string argument since it was stored as
plain string anyway.
2010-08-08 15:33:27 +00:00