Commit graph

72 commits

Author SHA1 Message Date
Martin Hrubý (hrubymar10)
bc4d22dc72 Migrate links to https if available - Fwd c18537edc0 2018-07-16 19:07:08 +11:00
Charles Dang
7241561554 Animated: simplified template stuff
Just... why was T_void_value a thing.
2018-04-21 16:04:16 +11:00
Charles Dang
fc2a58f693 Use std::size_t everywhere instead of plain size_t
Excludes:
* spirit_po/
* xBRZ/
2018-03-19 11:56:04 +11:00
Gregory A Lundberg
b5f76eff79
Bump copyright to 2018 2018-01-19 00:02:20 -06:00
David Mikos
ecb51029d7 Fix for jumpy movements in bug #1565
Add a new max_animation_time_ variable that checks whether the time
for the movement animation exceeds the potential time. This will
restrict the time interval to match the offset 0~1:200,0~1:200,etc.
as the unit is moving.
2017-07-19 20:06:33 +09:30
Charles Dang
69d4b93bef Cleaned up animated.tpp/.hpp formatting 2017-05-11 21:13:36 +11:00
Charles Dang
2101353d36 Convert include guards to the shorter #pragma once
Turns out I mistook @celticminstrel's opinion that we should use include guards over pragma (737916e).
Since all major compilers support `#pragma once`, there's no reason not to use it.

For future mergability reasons, this excludes src/spirit_po and src/xBRZ. It also excludes src/boost-patched.
2017-05-09 19:41:37 +11:00
Rikard Falkeborn
343eb9ab1b Add const to some functions 2017-04-17 16:51:30 +11:00
Celtic Minstrel
b4dc11ce36 Belated 2017 copyright update 2017-03-19 10:05:38 -04:00
Celtic Minstrel
8122039707 Rename .tpp -> .hpp
Several header files used the .tpp extension, which means that they are not correctly detected as C++ (though this can be overridden and has been for one case in the XCode project). The .tpp extension is one of several intended for private template instantiations, but these headers were topleve headers included in many places.
2016-03-19 21:57:03 -04:00
Chris Beck
ba51524f6e update copyright to year 2016
using this shell script:

find src -type f -print0 | xargs -0 sed -i "s|Copyright (C) \([[:digit:]]*\)\([ ]*\)-\([ ]*\)2015|Copyright (C) \1\2-\32016|g"
2016-01-02 23:59:31 -05:00
Ignacio R. Morelle
57ae45387a New Year copyright update 2015-01-01 19:07:35 -03:00
Mark de Wever
a2b8589143 Adds -Wextra-semi to pedantic compilation.
Also fixes all warning messages.
2014-01-26 14:24:12 +01:00
Ignacio R. Morelle
a4f47a63c7 New Year copyright update 2014-01-01 02:08:52 -03:00
Eric S. Raymond
043c4f9fd3 Remove $Id$ cookies. 2013-03-26 21:41:37 -04:00
Mark de Wever
43b71f2ff0 New year copyright update. 2013-01-01 09:22:03 +00:00
Ignacio R. Morelle
6ca69b2df5 New year copyright update 2012-01-07 02:35:17 +00:00
Ali El Gariani
7ca44f7ac6 Big optimization of terrain rendering by removing all empty images.
This make screen update (zooming, ToD changes, etc) several times
faster, gain some fps (esp. for complex map), optimize some animated
terrains (stop refreshing empty parts) and spare some memory
(sometimes, not clear yet)

Also remove the noise in :layers.

Note: This is an improved version of 2010-10-06T16:07:43Z!alinkmaze@gmail.com from the OGL branch
2011-12-17 15:07:07 +00:00
Mark de Wever
ecbabea838 New year copyright update. 2011-01-01 15:57:50 +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
Mark de Wever
a99c78e0d8 Update doxygen comment.
The filename after the @file comment is optional (spotted by alink).
2010-07-26 21:32:18 +00:00
Jérémy Rosen
8c40e72fa2 forgot some commits when merging water animation branch:
...random start for animations
2010-04-02 14:27:36 +00:00
Jérémy Rosen
ea77b152ca fix weird side effect of long first frame in standing animations 2010-02-14 22:18:06 +00:00
Mark de Wever
92f5f92ce5 New year copyright update. 2010-01-01 13:16:49 +00:00
Mark de Wever
973a0a7d5c Remove trailing whitespace. 2009-01-01 10:28:26 +00:00
Mark de Wever
a5d1d2e969 New year copyright update. 2009-01-01 10:27:41 +00:00
Mark de Wever
19b452540b Update doxygen comment style. 2008-06-23 19:48:12 +00:00
Jérémy Rosen
de873197d7 potential fix for the jumpiness when moving units and scrolling...
...at the same time. I had trouble reproducing the bug reliably, so if
you see it again, please report to me
2008-04-05 21:16:10 +00:00
Bruno Wolff III
2e9926074e Silence 6 gcc warnings about using const on a return type.
These were a mix of int and bool. Even though this is different than
the void case, I think removing the const still makes sense.
2008-03-19 15:19:51 +00:00
Mark de Wever
001af46e6e Updated all headers to 2008. 2008-02-16 08:47:16 +00:00
Jérémy Rosen
20bf7fa2e9 various cleanups in animations, and unreported bugfix 2008-02-11 19:44:25 +00:00
Jérémy Rosen
f4ea29865f fix a bad case of animation skipping...
that could cause the whole movement anim to be skipped if we had a lot
to redraw at the very beginning of the movement
2008-02-08 19:35:23 +00:00
Jérémy Rosen
052b3a88b7 default anmiations are now based on standing animations...
...instead of standing frames. Also removed anims in bats and ghost
caused by that bug (fix bug 10898)
2008-02-02 14:53:37 +00:00
Jérémy Rosen
7b101e6b6f fix bug #10836 Standing animations stay accelerated after releasing SHIFT key 2008-01-31 22:51:35 +00:00
Jérémy Rosen
5a54d031f7 port movement anim to the new framework.
* if animations are jumpy, this should be the first suspect

* slowing down on hard to cross tiles has been removed as discussed on
  IRC

* i'm not satisfied with that completely yet, expect some more work
  here...
2007-12-19 23:23:33 +00:00
Jérémy Rosen
5aba45d829 first go at the new animation API, still a WIP.
No regression expected. if anything changes, please tell me.

Note that:

* Fire and forget doesn't work yet, don't try using it

* I will probably change how mvt anims work as discussed in IRC, but
  that's for a future commit
2007-12-17 17:51:36 +00:00
Ali El Gariani
6914277871 Restore cyclic haloes (Fix bug #10393):
Consider a cyclic halo animation as never expired.

(because cyclic animation now finish)
2007-11-26 01:29:06 +00:00
Ali El Gariani
74e31f10bc Remove old unused code 2007-11-03 16:56:27 +00:00
Ali El Gariani
1181a44579 [[Animation fixes]]
- update the anim before rendering it (but continue to avoid skipping
frames) This fix a off-by-one frame bug in few cases where the update
is not automatic (e.g. last frame of idle anim was sometimes missed)

- now a starting anim is considered as a change and so in need_update state

- fix some inconsitencies with the use of update_last_draw_time()
2007-11-03 16:45:29 +00:00
Jérémy Rosen
dd48d3d8db allow multiple sub-animations, in all animations (not just missile in fight) 2007-10-28 10:17:53 +00:00
Jérémy Rosen
ba281e0aa8 more unit animation internal changes 2007-10-13 09:30:11 +00:00
Jérémy Rosen
366f1b9b55 allow animation level progressive parameters.
This should simplify backward compatibilty code greatly...
2007-10-12 17:17:16 +00:00
Gunter Labes
ae9e10f260 codeclean run
set svn:eol-style to native where missing
2007-08-31 19:09:40 +00:00
Hans Joachim Gurt
bd016f3e0a doxygen, comments 2007-08-21 23:34:34 +00:00
Mark de Wever
080eb69f60 Updated the headers to state GPL 2+ and a few changelog cleanups. 2007-08-15 13:41:56 +00:00
Mark de Wever
bb01934b85 A rather large update which updates the copyright info
* Wesnoth is distributed under the terms of the GPL version 2, made
  that more explicit

* updated the copyright range to 2007

* updated Dave's email adress
2007-07-21 07:28:04 +00:00
Ali El Gariani
61ab446359 fix an hidden bug when using non zero start time
add comments about bad support of acceleration for some functions

simplify get_animation_duration

remove my previous tempo function (now unneeded)
2007-04-14 10:55:37 +00:00
Ali El Gariani
40e84a0127 Add 2 utility functions: get the total time and the mean tempo of an animation. 2007-04-13 18:00:37 +00:00
Ali El Gariani
19d49aecd6 Add a function to get next or previous frame (from current) of an animation.
fix some values in constructors.
2007-04-11 14:31:56 +00:00
Jérémy Rosen
decbe85b18 reduce CPU usage by removing calls to SDL_GetTicks 2007-01-02 16:09:37 +00:00