Don't return 1200 in splitRatingFromNick if the player has no rating
yet, so that it can be reused for playername construction.
Refs https://code.wildfiregames.com/D670
Reviewed By: Imarok
This was SVN commit r19827.
Use OsPath instead of CStr and CStrW where possible,
wstring_from_utf8(OsPath.string8()) to pass printable strings to the
JSAPI,
OsString when opening a filestream and
off_t instead of int for filesizes.
Fixes#4320
Differential Revision: https://code.wildfiregames.com/D518
Reviewed By: Imarok
Tested By: Imarok on Windows, wraitii on OSX
Special thanks to Philip for advice and the lib/path.h fix in
47cc447322.
This was SVN commit r19824.
thus allow proper printing of such paths.
Fixes#4647
Refs #4320 D518
Patch By: Philip
Tested By: Imarok on Windows, wraitii on OSX
This was SVN commit r19823.
Only reset it if any of the original allies changes the diplomatic
relation to one of the other original allies.
Differential Revision: https://code.wildfiregames.com/D305Fixes#4529
Patch By: Sandarac
This was SVN commit r19818.
As civil centre and colony are civil centre, the current distance test
of colonies should be versus civil centre
Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D661
This was SVN commit r19809.
Use Date.now() to get the current timestamp instead of doing arithmetic
with Date objects and avoid needless object instantiation.
Differential Revision: https://code.wildfiregames.com/D554
Eyeballed By: causative
This was SVN commit r19802.
Only historic messages were timestamped in C++ prior.
Other messages showed the timestamp when they were displayed in JS,
which is wrong in case of returning to the lobby from a game.
Differential Revision: https://code.wildfiregames.com/D514Fixes#3832.
Reverts the revert of 1f34a004e5 in 572847ddd4.
Patch By: Josh
Tested By: Itms
This was SVN commit r19801.
Let the JS GUI take care of hiding the GUI and silhouettes and remove
the according hardcoding in the engine following 89aef0b6eb.
Thereby fix some bugs (like not having hid the GUI if there was a
message box or different page shown while playing a path) and
fix these two hotkeys broken by 5d49e6c456.
Differential Revision: https://code.wildfiregames.com/D631Fixes#4633
Reviewed By: Vladislav
This was SVN commit r19797.
6aeb5c64de forgot to add a LosIsOffWorld check in ExploreTerritories
(aka UpdateTerritoriesLos) and thus marked tiles outside of the world as
explored.
f5e60157bf transformed the bug into a non-simulation desynchronization,
causing rejoined players to see a different score,
as they excluded off-world tiles when filling the cache in
ResetDerivedData upon rejoin.
4a0673e44e transformed the bug into an actual simulation OOS by
serializing that map exploration percentage based on that cache.
Also tiles at the map border in square maps are not rendered as
expected, so this commit hides refs #4267.
Differential Revision: https://code.wildfiregames.com/D630Fixes#4598
Proofread by: Itms
Tested By: Imarok
This was SVN commit r19790.
Always spawn that cavalry that can be trained at the civic center, not
the other one from the barracks.
Spawn 2 melee and 2 ranged infantry units for Seleucids just as for any
other civ.
Differential Revision: https://code.wildfiregames.com/D647
Reviewed By: Grugnas, fatherbushido
Refs D649
This was SVN commit r19788.
Should use a special filter once the AI supports it (#4611), so that
decorative rubble can be placed by maps too.
Differential Revision: https://code.wildfiregames.com/D635
Reviewed By: fatherbushido
Refs #3601#3910#3179
This was SVN commit r19782.
It held resource strings when introduced by 0f21151c4b, but those were
moved to json files in 52f311da2b. 9b041467a2 moved two trivial
functions of this file to tooltips.js.
Remove a wrong comma from the JSdoc comment.
Alwas return a string.
Differential Revision: https://code.wildfiregames.com/D618
Confirmed by Itms in a forum PM that this doesn't break string freeze.
This was SVN commit r19779.
Throw a reference error instead of silently using an untranslated string
if someone would have passed a non-existing translation context.
Throw a property undefined warning if someone passed a non-existing
resource when trying to translate it.
Both warnings had been introduced in 0f21151c4b, were removed by
52f311da2b but now occur without adding code explicitly.
Differential Revision: https://code.wildfiregames.com/D625
Reviewed By: s0600204
This was SVN commit r19771.
It was a leftover from s0600204's proposal from 52f311da2b (refs #3934)
to disable resources with a boolean property.
Differential__Revision: https://code.wildfiregames.com/D625
Reviewed By: s0600204
This was SVN commit r19770.
Still throw that error if the function exists but could not be called
with JS_CallFunction.
Differential Revision: https://code.wildfiregames.com/D620
This was SVN commit r19769.