73 Commits

Author SHA1 Message Date
Pentarctagon
340023921d
2022 copyright update. 2022-03-06 19:07:13 -06:00
Pentarctagon
57ce449af8
Re-add attribution to copyright notices.
These are mostly useless and outdated/wrong, but apparently it's probably illegal to remove them.
2021-07-27 20:21:38 -05:00
Pentarctagon
ba75e1af50
Copyright update.
This additionally:
* Makes all copyright notices identical aside from the starting year for Wesnoth-specific source files. Files not included: mariadbpp, lua, spirit po, xbrz, and bcrypt (crypt_blowfish).
* Removes all attribution from the files, since the vast majority of them are outdated or seemingly just outright incorrect. For example, I would guess that Dave is no longer the sole author of the majority of Wesnoth's current code.
2021-07-26 11:38:03 -05:00
Charles Dang
2005cfd92e Removed empty doxygen file descriptions (/** @file */) 2021-01-14 09:26:56 +11:00
Pentarctagon
4c2b725ec0 Change all doxygen comments to the same format. 2020-12-31 23:59:28 -06:00
josteph
541956343b Code formatting changes.
https://github.com/wesnoth/wesnoth/pull/4070#discussion_r290087376
https://github.com/wesnoth/wesnoth/pull/4070#discussion_r290087461
2019-06-05 10:31:10 +00:00
josteph
bad65044dc Hit stats: Rename a type to reflect its content rather than its use 2019-06-05 10:31:09 +00:00
josteph
ff5df5141e statistics: Coding style changes suggested by @jyrkive. 2019-06-05 10:31:09 +00:00
josteph
5f34300bf9 Hit stats: Introduce a hitrate_map typedef. 2019-06-05 10:31:09 +00:00
josteph
13cf420adb statistics: Add attacks_taken, defends_taken
They'll be used to reconstruct by_cth_taken, like
attacks_inflicted/defends_inflicted will be used to reconstruct
by_cth_inflicted.
2019-06-05 10:31:09 +00:00
josteph
479be6e61b statistics: Rename a class member
To match the convention. The next commit adds the *_taken member.
2019-06-05 10:31:09 +00:00
josteph
494bdc51f7 Hit stats: Track current turn stats too. 2019-06-05 10:31:09 +00:00
josteph
b52eb32ba2 Hit stats: Save and restore hit stats. 2019-06-05 10:31:09 +00:00
josteph
7eb75539a6 Hit stats: Track both inflicted and taken hits. 2019-06-05 10:31:09 +00:00
josteph
38641d667a Hit stats: Track number of hits/misses by CTH in statistics::stats objects. 2019-06-05 10:31:08 +00:00
josteph
d3c1cc43e7 Fix #2852: Reset statistics when rewinding a replay to the beginning.
Currently, while watching a replay of Scenario N, the statistics dialog
has the following options:

- All scenarios
- S1
- S2
- ...
- SN
- SN

The last option shows the statistics of Scenario N from the beginning
through the current point in the replay.  The other options show
end-of-scenario stats of each scenario and the cumulative stats of all
scenarios through the end of SN.

This patch causes the stats shown by the the second SN option to reset
to zero when the "reset replay" ("stop") button is selected.
2019-03-25 13:37:58 +00:00
Martin Hrubý (hrubymar10)
674fda85b7 Migrate links to https if available - Fwd c18537edc0678f40a209797d72dfaba3e5e88545
(cherry-picked from commit bc4d22dc72e79c3d6a3364ac896e473afd298246)
2018-10-07 03:23:36 +00:00
Charles Dang
e270a7c665 Formatting cleanup: > > to '>>`
Allowed since C++11. Might as well use it everywhere.
2018-02-21 12:11:21 +11:00
Gregory A Lundberg
b5f76eff79
Bump copyright to 2018 2018-01-19 00:02:20 -06: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
Celtic Minstrel
b4dc11ce36 Belated 2017 copyright update 2017-03-19 10:05:38 -04:00
Celtic Minstrel
3ac7f8d970 NULL -> nullptr
A few cases of NULL were missed, since changing them led to errors
(Mainly instances where it was passed to a boost::function)
2016-03-31 00:42:38 -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
Aishiko
c6d11a5f5e Implement unit instance recall costs.
Actually allows for the unit instance recall costs to be used. Proper
taking of the gold and undoing the cost for each unit is implemented
and works.  At advancement if the unit's current recall matches their
unit_type's recall_cost then it takes the new unit_type's recall_cost
otherwise it keeps whatever value it currently has until it fails this
check.  Recall costs are also now persistant and will carry over from
one scenario into the next as well.

If a cost is not set, it will continue to use the team/side/default
costs, these changes should not affect the current workings when
dealing with unaltered scenarios, and unit config files.  I repeat This
will not affect or change the currently way things work UNLESS a user
alters a file or includes the new recall_cost (as in copies and
modifies a unit in the scenario unit files) for a unit instance in
their scenario file(s).
2014-03-17 17:49:15 -04: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
J. Tyne
1f68e0bb48 Add display of per-scenario statistics. 2012-09-08 19:02:29 +00:00
J. Tyne
887b552b1b Simplify the implementation of statistics::calculate_stats(). 2012-09-08 16:17:27 +00:00
J. Tyne
54eef94cf8 Pass some strings by const reference instead of value. 2012-09-08 15:47:52 +00:00
J. Tyne
724618c287 Split actions.cpp into six pieces (into a new "actions" subdirectory).
Most of the project files have also been updated, but I ran into some
difficulties trying to update VC9 and Xcode.
2012-08-25 14:06:46 +00:00
Ignacio R. Morelle
6ca69b2df5 New year copyright update 2012-01-07 02:35:17 +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
Mark de Wever
92f5f92ce5 New year copyright update. 2010-01-01 13:16:49 +00:00
Guillaume Melquiond
e3b2a340c5 Removed unused class statistics::disabler. 2009-08-16 10:08:28 +00:00
Guillaume Melquiond
d10602a789 Added cost of units recruited, recalled, killed, and lost,
...to the statistics window (patch #1190 by lizard).
2009-07-14 17:35:32 +00:00
Guillaume Melquiond
da28488cc7 Removed the old system for stats. 2009-03-10 08:37:02 +00:00
Guillaume Melquiond
c0e48a5692 Fixed display of negative "expected" values. Cleaned code and fixed typos. 2009-03-09 18:17:10 +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
Eric S. Raymond
15ae149c71 Fix bug #12322 (Campaign statistics not carried from scenario to scenario) 2008-09-23 13:24:39 +00:00
Eric S. Raymond
69c4c81fa6 Fix bug #11175 (Strange Statistic Losses).
Statistics are now associated with side ID (team leader description)
rather than team number.
2008-08-21 23:13:07 +00:00
Mark de Wever
19564039ee Update doxygen comment style. 2008-05-25 10:25:23 +00:00
Pauli Nieminen
90930ec599 Made new stats visible same time with old for comparision (need testing) 2008-05-14 14:47:24 +00:00
Pauli Nieminen
859958b006 Added possibility to use per fight EV statistics proposed by maboul
Fixed possible cause for client disconnects when having bad connection

Cleaned up game config reading code

minor code cleanups
2008-05-11 19:34:32 +00:00
Mark de Wever
001af46e6e Updated all headers to 2008. 2008-02-16 08:47:16 +00:00
uso
1a8b179a51 add damage statistics for the current turn...
...and show it in the statistics window
2008-01-11 02:31:03 +00:00