1
0
forked from 0ad/0ad
Commit Graph

6712 Commits

Author SHA1 Message Date
a5c60619e2 Input GUI object cleanup.
Remove redundant if-statement following 5593f573f4 as reported by
Vladislav.
Use switch-statement in ManuallyHandleEvent.

This was SVN commit r20078.
2017-08-30 12:01:17 +00:00
ee38f0db37 Implement readonly Input GUI objects and use it in the file location indicator in the replay menu,
so that the user can copy the file path.

Fixes #4225
Refs D763
Patch By: Vladislav
This was SVN commit r20075.
2017-08-29 23:53:23 +00:00
23118ba847 Split the Input GUI object key processing into two methods (methods changing the text and methods not changing it).
Patch By: Vladislav
Refs #4225, D763

Also use SDL_Keycode instead of int, remove an outdated history lookup
comment and some other unneeded comments.

This was SVN commit r20074.
2017-08-29 23:29:29 +00:00
e8dfde9ba6 Display previously received lobby chat messages when returning from the gamesetup.
Differential Revision: https://code.wildfiregames.com/D819
Fixes #3306
Patch By: fpre / ffffffff
This was SVN commit r20070.
2017-08-29 16:04:45 +00:00
0ceeaf921b Fix typo in 0940db3fc0 / D835 reported by gameboy.
Reviewed By: Vladislav
This was SVN commit r20069.
2017-08-29 12:22:31 +00:00
27d99765bb Add an icon to pyrogenesis' application window
Tested By: Imarok (Windows, Ubuntu w. Gnome), s0600204 (Arch w. Xfce),
ffffffff (Kubuntu w. KDE)
Reviewed By: ffffffff, s0600204
Differential Revision: https://code.wildfiregames.com/D768
Trac Tickets: #4363

This was SVN commit r20067.
2017-08-28 21:56:54 +00:00
0940db3fc0 XmppClient cleanup.
Allow XmppClient to use arbitrary property names in GUIMessages.
Remove duplication by calling CreateGUIMessage when receiving chat
messages.
Inline PushGUINotification.
Use std::string in the GUIMessage because every data source is of that
type.
Apply the wstring_from_utf8 conversion to ensure correct display of less
common UTF characters instead in the GuiPollMessage method.
Add room subject change chat message.

Differential Revision: https://code.wildfiregames.com/D835
Refs #4482
Comments by fpre, Vladislav and leper

This was SVN commit r20064.
2017-08-28 17:47:43 +00:00
1b44946078 Replace deprecated jsval with JS::Value.
Remove unused SGUIBaseSettings and GUI comment.
Fix indentation of a macro, refs D794.

Differential Revision: https://code.wildfiregames.com/D838
Review by: leper.
Itms came up with the same patch for the SpiderMonkey 45 update
independently.

This was SVN commit r20062.
2017-08-28 10:27:36 +00:00
bb
565abd5f1b Fix directory for Atlas help from a93d260643
When launching Atlas from a higher directory the help.json isn't found.
Fixed by finding the absolute path.

Patch By: vladislavbelov
This was SVN commit r20059.
2017-08-27 19:32:54 +00:00
bb
62c9c6d7fc Add scrollbars to all tabs in Atlas.
Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D793
This was SVN commit r20058.
2017-08-27 18:47:39 +00:00
eb70d83b67 Fix rallypoint color after deserialization following 505a10cef6.
Differential Revision: https://code.wildfiregames.com/D826
Refs #4618, D623

This was SVN commit r20049.
2017-08-27 16:05:20 +00:00
16b976fc35 Remove unneeded GetMucMessageCount from the XmppClient.
The affected function was imprecise, because it called a playerlist
update whenever a "chat" level message was received instead
of only updating the playerlist if it's actually influencing the
displayed playerlist.
When there is a chat message, lobby subject change or user-role change,
there is no need to update the list.

Differential Revision: https://code.wildfiregames.com/D671
Refs #3386, 8b437a0b1c
Reviewed By: fpre / ffffffff
This was SVN commit r20040.
2017-08-25 18:51:26 +00:00
ce580f0de0 Always delete CMapReader. Patch by Sandarac. Fixes #4154.
This fixes an assertion failure in ScriptEngine that can occur when
closing
the game while in the loading screen.

Reviewed By: vladislavbelov, leper
Differential Revision: https://code.wildfiregames.com/D684
This was SVN commit r20035.
2017-08-25 00:37:48 +00:00
f27efac053 Enhance lobby / XMPP timestamp parsing documentation.
Refs #3832, 9a5e1ddedb / D760, 6141c5c4fa / D514
Reviewed By: leper
This was SVN commit r20032.
2017-08-24 20:57:21 +00:00
9defd11440 Pass ScriptInterface as a const ref where possible.
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D739
This was SVN commit r20028.
2017-08-24 00:32:42 +00:00
7970c3dc54 Pass a const reference, if someone wants to modify it they should use the global directly.
Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D738
This was SVN commit r20027.
2017-08-23 23:52:32 +00:00
a93d260643 Add help button to Atlas with a link to the Manual and bugtracker.
Differential Revision: https://code.wildfiregames.com/D794
Patch By: Vladislav
This was SVN commit r20021.
2017-08-21 23:32:29 +00:00
1ddd24bb8c Remove unused Renderer function from 12e2428495.
Refs #2137
Reviewed By: Vladislav
This was SVN commit r20019.
2017-08-21 17:05:45 +00:00
6f9bf55ac5 Change the shadow map quality without restarting the match.
Differential Revision: https://code.wildfiregames.com/D804
Refs #4351
Patch By: Vladislav
This was SVN commit r20011.
2017-08-21 01:10:56 +00:00
04f2209b50 Rename WaterUgly setting to WaterEffects in order to remove the invertedboolean workaround of the options page.
Differential Revision: https://code.wildfiregames.com/D815
Refs #3737
Tested By: Stan
This was SVN commit r20010.
2017-08-21 00:09:25 +00:00
8df36bace4 Shadow map quality option.
Differential Revision: https://code.wildfiregames.com/D745
Fixes #4351
Refs #743
Patch By: Vladislav
This was SVN commit r20001.
2017-08-19 12:46:05 +00:00
cb18830a81 Remove CinemaManager input handler to allow user interaction on other GUI pages like message boxes and possibly few selected hotkeys.
Disable gameview/camera hotkeys while cinematic paths are playing.

Differential Revision: https://code.wildfiregames.com/D697
Refs #3301, #3814, 89aef0b6eb
Reviewed By: Vladislav
This was SVN commit r19980.
2017-08-12 10:32:07 +00:00
316a8848a0 Ignore few Ownership changes in the Selectable and RallyPointRenderer component.
Properly support capturing in the RallyPointRenderer component, even
though RallyPoints are typically deleted upon capturing.

Differential Revision: https://code.wildfiregames.com/D776
Refs D687
Reviewed By: Stan
This was SVN commit r19976.
2017-08-11 20:05:03 +00:00
00e7d49368 Profile Footprint calls that can easily consume 90% of the simtime on a turn ("sunken ship lag").
Differential Revision: https://code.wildfiregames.com/D778
Refs #4713
Reviewed By: Vladislav
This was SVN commit r19973.
2017-08-11 18:08:30 +00:00
343ec21e75 Update the color of the selection ring, rallypoints and territory outline when the playercolor is changed in atlas.
Merge duplicate Selectable component playercolor code.

Differential Revision: https://code.wildfiregames.com/D687
Fixes #4643
Refs D623
Patch in cooperation with: Stan

This was SVN commit r19965.
2017-08-09 11:19:14 +00:00
3d0bfc7e1b Forgotten years replacement in 3a3bcca0c5.
This was SVN commit r19962.
2017-08-09 07:11:53 +00:00
3a3bcca0c5 Refactor the code for cutting a circle into chords for textured line overlay in Selectable component. Don't compute useless arccos and avoid compound rounding errors. Reviewed by Itms.
Differential Revision: https://code.wildfiregames.com/D673
This was SVN commit r19959.
2017-08-08 17:48:44 +00:00
505a10cef6 Display rallypoints in the playercolor instead of plain blue.
Differential Revision: https://code.wildfiregames.com/D623
Fixes #4618
Patch By: Stan
This was SVN commit r19957.
2017-08-08 12:48:57 +00:00
37c2f18b9e Add AI engine function for template loading
Partial commit of https://code.wildfiregames.com/D639, taken from
Sandarac patch

Reviewed by mimo

This was SVN commit r19951.
2017-08-07 19:35:43 +00:00
9a5e1ddedb Fix BSD and OSX build that don't provide the AT&T version of timezone used by 6141c5c4fa. Refs #3832, D514.
Mostly reviewed by: leper
Tested on Windows by: Stan
This was SVN commit r19947.
2017-08-07 09:56:31 +00:00
9641d0cdb0 Fix typo in 39fcd1d031 reported by Imarok.
This was SVN commit r19941.
2017-07-31 16:33:14 +00:00
00fafda955 Stop copying the territory grid when recomputing the texture.
Before inlining territories it was changed to be a const reference, thus
avoiding the copy.

Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D741
This was SVN commit r19936.
2017-07-30 23:37:05 +00:00
98d7763765 Remove code that doesn't do anything.
Reviewed By: Imarok
Differential Revision: https://code.wildfiregames.com/D743
This was SVN commit r19933.
2017-07-29 23:27:28 +00:00
5ab426d621 Remove commented out code.
Reviewed By: Sandarac
Differential Revision: https://code.wildfiregames.com/D742
This was SVN commit r19932.
2017-07-29 23:27:14 +00:00
781cec163e Remove CTerritoryManager pointer from CWorld, a relic from before simulation2.
Patch By: Sandarac
Differential Revision: https://code.wildfiregames.com/D731
This was SVN commit r19931.
2017-07-29 23:27:02 +00:00
27e5c5b25a Mark a few functions const.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D499
This was SVN commit r19930.
2017-07-29 23:26:44 +00:00
3fca871fd6 Take gui.scale into account when repositioning tooltips
Patch by: joskar
Differential Revision: https://code.wildfiregames.com/D749
This was SVN commit r19928.
2017-07-29 18:30:59 +00:00
99b0362edf Bump version number to Alpha 23.
Differential Revision: https://code.wildfiregames.com/D758
Reviewed By: fatherbushido
This was SVN commit r19923.
2017-07-29 16:36:55 +00:00
d56692d9e1 Rewrite the pathfinder dirtiness information system.
Remove all hacks while keeping most optimizations in memory management.
This fixes incomplete grid updates that could cause OOS on rejoin, fixes
#4596.

Tested by: elexis, ffffffff
Reviewers: leper, wraitii
Differential Revision: https://code.wildfiregames.com/D675
This was SVN commit r19916.
2017-07-14 10:09:32 +00:00
918a693f0f Update the list of bundled languages for A22.
This was SVN commit r19913.
2017-07-12 13:56:28 +00:00
53eaef0746 Don't change the copyright headers of other software groups, as reported by leper.
Refs 43137fef3f / D716

This was SVN commit r19907.
2017-07-10 21:53:47 +00:00
43137fef3f Make all Wildfire Games copyright headers consistent by always ending with a period and using (C) instead of (c).
Differential Revision: https://code.wildfiregames.com/D716
Refs 09e974e1cb
Reviewed By: bb
Change in agreement with leper.

This was SVN commit r19899.
2017-07-10 14:26:24 +00:00
d49bf8b1bf Ensure the camera position being above the water level (without smoothing the water level with the terrain).
Differential Revision: https://code.wildfiregames.com/D700
Fixes #3892, D229, D638

This was SVN commit r19896.
2017-07-10 02:16:57 +00:00
a5e253162b Fix undefined macro usage in cppformat.
This is quite noisy with -Wexpansion-to-defined in both clang 3.9 and
gcc 7.
(Refs #3190 and #4148. Upstream might have fixed this, but somewhat
clean build logs seem worth it.)

Reviewed By: echotangoecho
Differential Revision: https://code.wildfiregames.com/D680
This was SVN commit r19884.
2017-07-08 00:15:03 +00:00
9aad0137ba Stop using WMI for detecting the sound card, and use OpenAL instead. Delete WMI code altogether now it is unused.
This fixes #4561 and makes sound card detection work on non-Windows
platforms.

Reviewed By: echotangoecho
Tested By: Imarok, elexis
Differential Revision: https://code.wildfiregames.com/D636
This was SVN commit r19877.
2017-07-06 17:29:49 +00:00
5c6f3505e8 Fix replay cache performance (broken by ea250b3d25). Also remove a TODO fixed by fca844eef6.
Reviewed by elexis.

This was SVN commit r19875.
2017-07-06 16:20:18 +00:00
14e1b79a0f Insert cinematic path nodes after the currently selected node instead of before (so paths are not created in the opposite of the expected order).
Differential Revision: https://code.wildfiregames.com/D656
Refs #3871
Patch By: Vladislav
This was SVN commit r19864.
2017-07-01 15:49:59 +00:00
c67d79d9f3 Recompute water graphics when changing the water level and upon deserialization to fix a graphical (non-simulation) OOS on rejoin.
Differential Revision: https://code.wildfiregames.com/D638
Refs #4596
Contains a fix mentioned by leper.

This was SVN commit r19862.
2017-07-01 04:15:49 +00:00
6f7a5fb773 Allow the JS GUI to subscribe to the window resized event and use it to conditionally update the observer panel (refs D689).
Differential Revision: https://code.wildfiregames.com/D694
Tested By: temple
Proofread By: Vladislav
This was SVN commit r19846.
2017-06-30 00:04:29 +00:00
5e6b502eab Fix dropdown list height after resizing the window (in case there is an item that used wordwrapping before but not after the resize or vice versa).
Differential Revision: https://code.wildfiregames.com/D692
Tested By: temple
Proofread by: Vladislav
Refs #3571

This was SVN commit r19845.
2017-06-29 23:39:12 +00:00
ca2390d70e JS lobby cleanup, fixes and lobby bot performance improvements:
Do not send a wasteful rating request if the same player is selected
again when someone joined the lobby, when changing the sorting order or
when clicking on the same user again
by moving the player-selection change test from updatePlayerList to
onPlayerListSelection.

That test should have been done here in 8f4daa9dd0 already and fixes
#3840 well enough.

This change also fixes an unintentional behavior of the code, where the
game the currently selected player is playing in would be selected if
someone else joined the lobby, even if a different game was selected
manually.
Furthermore it allows simplification of the code of 655ce95468 by
removing selectGameFromPlayername which did almost the same as
selectGameFromPlayername.

To still select the game the current player is playing in if the
selected player didn't change, subscribe to the (new) event that is
called when clicking on an item.

Differential Revision: https://code.wildfiregames.com/D688
Reviewed By: ffffffff (fpre)
This was SVN commit r19841.
2017-06-29 02:58:04 +00:00
be2b2faa77 Properly apply texture to the last quad of an overlay textured line. Reviewed by vladislavbelov.
Fix #4617.
Differential Revision: https://code.wildfiregames.com/D663
This was SVN commit r19833.
2017-06-26 13:04:21 +00:00
e7ab22286e Fix the replay menu for people with non-latin characters in their username.
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.
2017-06-25 14:54:00 +00:00
47cc447322 Fix OsPath string8 function on Unix to account for characters that aren't covered by ISO-8859-1,
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.
2017-06-25 14:30:26 +00:00
e1b43137fe Fix incompatible value for WaterUgly warning on opening the options screen.
Reviewed by: vladislavbelov, Imarok. Patch by echotangoecho. Fixes:
#4230.
Differential Revision: https://code.wildfiregames.com/D89
This was SVN commit r19822.
2017-06-25 11:13:17 +00:00
abe5d9205a Remove useless file entry in replays list
Reviewed by: elexis
Differential Revision: https://code.wildfiregames.com/D668
This was SVN commit r19814.
2017-06-21 15:43:57 +00:00
ea250b3d25 Don't crash if there is a replay subdirectory without commands.txt following 80635665f7 / D39.
Differential Revision: https://code.wildfiregames.com/D667
Reviewed By: Imarok
This was SVN commit r19813.
2017-06-21 14:44:26 +00:00
6141c5c4fa Correct lobby chat timestamps.
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/D514
Fixes #3832.
Reverts the revert of 1f34a004e5 in 572847ddd4.
Patch By: Josh
Tested By: Itms
This was SVN commit r19801.
2017-06-18 18:48:18 +00:00
d5caf97185 Fix Valgrind complaints in CRenderer by properly intializing some members values introduced in ab30e0d4fb. Refs #3922, #4492. Patch by Sandarac. Reviewed by vladislavbelov.
Differential Revision: https://code.wildfiregames.com/D536
This was SVN commit r19800.
2017-06-18 14:52:54 +00:00
cfd08bbf28 Cinema Path GUI hiding and silhouettes fixes.
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/D631
Fixes #4633
Reviewed By: Vladislav
This was SVN commit r19797.
2017-06-17 14:17:30 +00:00
e6dafe9efc Fix a map exploration OOS on rejoin when starting with territory at the map boundaries.
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/D630
Fixes #4598
Proofread by: Itms
Tested By: Imarok
This was SVN commit r19790.
2017-06-16 19:39:30 +00:00
bedb13ea28 Delete gui/common/functions_utility_error.js.
Move the one function in it that is globally called from the engine to
the other function that is called equally.

This was SVN commit r19781.
2017-06-15 22:44:24 +00:00
860b5bbfce Revert an unfortunate early break introduced in 2527aabd5d, patch by Sandarac.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D641
This was SVN commit r19777.
2017-06-15 17:45:16 +00:00
b94a54b18a Use direct gui.scale instead of reciprocal gui.scale
Patch by Dariost.

Differential Revision: https://code.wildfiregames.com/D328
This was SVN commit r19774.
2017-06-14 17:13:44 +00:00
74512ef01c Remove emptyinit.xml workaround file for atlas introduced in abaea508ac that silenced an engine warning stating that the GUI page doesn't provide a JS init function.
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.
2017-06-13 02:50:41 +00:00
bb3638a9b5 Always set the Seed property from autostarted games, because it is required and used to initialize the RNG of the simulation following 6eaf76d653.
Differential Revision: https://code.wildfiregames.com/D592
Refs #4127, #3965

This was SVN commit r19749.
2017-06-08 14:47:55 +00:00
b19612c31a Fix whitespace and three refs instead of copies in the glooxwrapper/StunClient code identified by leper in 61261d14fc.
This was SVN commit r19741.
2017-06-05 20:44:00 +00:00
2527aabd5d Fix hero selection rings becoming unsaturated when moving. Patch by Sandarac, refs 0a53c5e06a, #2627.
Differential Revision: https://code.wildfiregames.com/D563
This was SVN commit r19732.
2017-06-04 13:04:04 +00:00
51f62818f7 Fix all broken checks for the absent (random-mapgen+simulation) Seed property in the engine, refs #3965.
Hence display the originally intended useful warnings (instead of the
characterless JS "Script value conversion check failed" warning and
skipping the intended warnings).

This was SVN commit r19718.
2017-06-02 15:07:58 +00:00
61261d14fc STUN + XMPP ICE implementation.
Allows lobby players to host games without having to configure their
router.

Differential Revision: https://code.wildfiregames.com/D364
Fixes #2305
Patch By: fcxSanya.
StunClient based on code by SuperTuxKart, relicensed with approval of
the according authors hilnius, hiker, Auria, deveee, Flakebi, leper,
konstin and KroArtem.
Added rfc5245 (ejabberd) support, a GUI option, refactoring and segfault
fixes by myself.

Tested By: user1, Sandarac, Sestroretsk1714, Vladislav, Grugnas,
javiergodas
Partially Reviewed By: leper, Philip, echotangoecho
This was SVN commit r19703.
2017-06-01 06:33:52 +00:00
77c4e649af Replace hardcoded copies of a C++ simulation constant in JS used to compute the mapsize with a call to a new getter in the C++ interface.
Differential Revision: https://code.wildfiregames.com/D577
Patch By: Sandarac
This was SVN commit r19699.
2017-05-31 16:43:57 +00:00
a7c09a500d That what leper said. Refs 9ff7ec3465, 31d1536e52.
This was SVN commit r19688.
2017-05-29 02:56:34 +00:00
31d1536e52 Optionally allow late observers for buddies only.
Differential Revision: https://code.wildfiregames.com/D549
Fixes #4528
Reviewed By: fpre
This was SVN commit r19685.
2017-05-28 18:05:08 +00:00
d44a407fc4 That what mimo said.
This was SVN commit r19684.
2017-05-28 17:45:17 +00:00
80635665f7 Fix replay menu loading time by using a cache file
Reviewed by: elexis
Fixes #3433
Differential Revision: https://code.wildfiregames.com/D39
This was SVN commit r19674.
2017-05-27 20:17:57 +00:00
3d53614bce Add a script to lint the translations with Dennis.
Two of our printf calls are not compatible with python-format and will
be ignored until Dennis supports the corresponding formats. Also removed
meaningless enclosing characters that were wrongly considered HTML.

Reviewed By: leper
Differential Revision: https://code.wildfiregames.com/D214
This was SVN commit r19669.
2017-05-27 12:26:26 +00:00
9ff7ec3465 Scale the cursor according to the GUI scale (HiDPI support).
Differential Revision: https://code.wildfiregames.com/D320
Fixes #3875
Patch By: Dariost
Reviewed By: domdomegg
This was SVN commit r19667.
2017-05-27 09:24:04 +00:00
a789b5555d Update the xml validator tool to handle mods. Reviewed by leper.
Differential Revision: https://code.wildfiregames.com/D425
This was SVN commit r19660.
2017-05-26 12:43:58 +00:00
8680f79d48 Display the filename of the selected replay in the replay menu to ease sharing of replays.
Differential Revision: https://code.wildfiregames.com/D495
Reviewed By: Sandarac
This was SVN commit r19650.
2017-05-24 13:53:00 +00:00
a533fff883 Add a -autostart-nonvisual option. Patch by sacha_vrand. Fixes #4577.
This allows automated testing of AIs without any GUI or sound (similar
to non-visual replays).

Differential Revision: https://code.wildfiregames.com/D379
This was SVN commit r19645.
2017-05-23 19:26:33 +00:00
f0a008c821 Refactor NONCOPYABLE to remove unneeded semicolons. Remove visibility keywords that were hidden in the macro. Patch by echotangoecho.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D481
This was SVN commit r19626.
2017-05-21 13:11:07 +00:00
3d7784d2af Try to recognise unknown hotkey mappings using SDL2.
This improves our international keyboard until we completely rework the
hotkey system which seems to be quite legacy at this point.

Reviewed by Itms.
Differential Revision: https://code.wildfiregames.com/D303
This was SVN commit r19624.
2017-05-21 08:05:52 +00:00
aa025b514b Fix out of bounds access in Hotkey.cpp. Patch by echotangoecho.
Differential Revision: https://code.wildfiregames.com/D211
This was SVN commit r19613.
2017-05-19 18:01:22 +00:00
7c88529b45 Call std::terminate() instead of throwing in a destructor.
We don't catch this specific exception, so no behavioural change, but we
do no longer violate the implicit noexcept for destructors in C++11.
(Fixes a GCC6 and VS2015 warning.)

Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D416
This was SVN commit r19612.
2017-05-19 17:48:43 +00:00
7a91d330d3 Add GetMicroseconds function to allow microsecond precise timing in the JS GUI.
Differential Revision: https://code.wildfiregames.com/D190
Reviewed By: Vladislav, echotangoecho
This was SVN commit r19603.
2017-05-17 22:10:09 +00:00
15e2b42525 New economic tutorial based on triggers, accessible from the "learn to play" button
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D194
This was SVN commit r19599.
2017-05-17 17:33:36 +00:00
90beda96f8 Fix atlas clicking following 8f36ca47a1 / D326 by adding the missing clicks property to the wxWidgets SDL event construction.
Differential Revision: https://code.wildfiregames.com/D452
Fixes #4557
Patch By: causative
This was SVN commit r19589.
2017-05-16 00:09:16 +00:00
2599d0374e Get the index of the hovered element in GUI lists and use it to display item-specific tooltips in the gamesetup for the victory condition, maptype and starting resources.
Differential Revision: https://code.wildfiregames.com/D316
Fixes #3699
Patch By: Vladislav
This was SVN commit r19588.
2017-05-15 21:49:10 +00:00
62195c28f2 Fix out of range access in CInput, patch by vladislavbelov. Fixes #4570.
Some invalid cursor positions were not checked, resulting in a crash in
Debug mode. This was revealed by e1e4ef0370, refs #4401.

Reviewed By: echotangoecho, Itms
Differential Revision: https://code.wildfiregames.com/D484
This was SVN commit r19579.
2017-05-14 19:02:03 +00:00
d5c9725dc3 Revert the wrong "insufficient permissions to remove an account" error message from 9281aaf25e to the previous "Registration forbidden" which is shown when lobby registrations are disabled or restricted to some IP range.
Differential Revision: https://code.wildfiregames.com/D319
Refs #3047
Reviewed By: scythetwirler, leper
This was SVN commit r19575.
2017-05-14 03:18:21 +00:00
08b23d0164 Sooner network timeout warnings.
Reviewed By: echotangoecho
This was SVN commit r19574.
2017-05-13 22:52:11 +00:00
00c4adfae8 Add missing Hexify call to the OOS dialog in D105 that became required with the hash comparison in JS. Reported by causative.
Differential Revision: https://code.wildfiregames.com/D476
Reviewed By: leper
This was SVN commit r19562.
2017-05-12 08:50:20 +00:00
51f7502bb1 Don't move temporaries, so possibly allowing for copy elision.
Pointed out by clang's -Wpessimizing-move.

Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D421
This was SVN commit r19559.
2017-05-11 23:24:54 +00:00
c288278229 Enable cheats in autostarted games because the JS gamesetup enables them in singleplayer and because the autostarted multiplayer mode relies on the change-perspective feature to control players.
Differential Revision: https://code.wildfiregames.com/D453
Refs #2676
Reviewed By: echotangoecho
This was SVN commit r19557.
2017-05-11 22:32:41 +00:00
8bf732453e Ignore color and font tags when typing something in a Dropdown gui element to select an item.
Differential Revision: https://code.wildfiregames.com/D462
Refs D435
Reviewed By: Vladislav
This was SVN commit r19545.
2017-05-09 13:29:19 +00:00
36a16a4576 Remove debug breakpoint that is triggered whenever an unsupported UTF32 character is encountered,
for example when someone would send a lobby chat message containing such
a character, it effectively ended the game of the recipients.

Differential Revision: https://code.wildfiregames.com/D456
Fixes #4433
Reviewed By: leper
Reported and tested by: Hannibal_Barca
This was SVN commit r19540.
2017-05-08 22:29:00 +00:00
25b1837603 Pass CVector3D as const reference in a few places.
Reviewed By: Sandarac
Differential Revision: https://code.wildfiregames.com/D424
This was SVN commit r19534.
2017-05-08 04:04:45 +00:00
bdfe500f98 Draw paths only when cinematics isn't playing. Patch by Vladislav.
Also show the GUI after the cinematics stopped playing in Atlas.

Differential Revision: https://code.wildfiregames.com/D411
This was SVN commit r19533.
2017-05-08 04:02:33 +00:00
c5ab9925d4 Fix possible null dereferences.
Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D420
This was SVN commit r19532.
2017-05-08 02:41:23 +00:00
631fa4b376 Remove unused old code for triggers in atlas.
Actually implementing atlas support for triggers will most likely
require a different interface, so no use keeping it.

Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D418
This was SVN commit r19531.
2017-05-08 02:40:22 +00:00
7d00501a90 Make 81c57e8a28 compatible with wxWidgets 2.8, patch by vladislavbelov.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D427
This was SVN commit r19525.
2017-05-07 15:49:55 +00:00
a857ee441e Enable other languages than English in the Windows installer, patch by vladislavbelov.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D314
This was SVN commit r19524.
2017-05-07 14:38:29 +00:00
ee5bb1fd61 RangeVisualization component and use it to visualize Aura ranges.
Differential Revision: https://code.wildfiregames.com/D238
Fixes #4349
Patch By: Sandarac
This was SVN commit r19519.
2017-05-06 00:47:21 +00:00
76bc9b579a Clientside Lobby support for muted players (visitor role).
Displays a chat message and a notification in the player details to
everyone if someone was muted and
hides the chat input to visitors.

Differential Revision: https://code.wildfiregames.com/D339
Reviewed By: user1
This was SVN commit r19514.
2017-05-05 01:13:12 +00:00
329f9e0957 Remove broken atlas error reporting code.
This has been disabled for nearly 10 years (44f5288a1d), so remove it.

Reviewed By: fatherbushido, vladislavbelov
Differential Revision: https://code.wildfiregames.com/D423
This was SVN commit r19511.
2017-05-04 09:29:24 +00:00
f794a14610 Declare variable when actually initialized.
Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D417
This was SVN commit r19508.
2017-05-04 06:53:21 +00:00
4a5f302ce1 Optional FPS Limiter for running games too, use the Slider GUI object in the config to specify custom limits.
Make it way more accurate by excluding the SDL_Wait time and microsecond
precision.

Differential Revision: https://code.wildfiregames.com/D109
Refs #2882
Reviewed By: Vladislav
This was SVN commit r19507.
2017-05-03 23:44:13 +00:00
09e974e1cb Bump year number of files changed this year in the license headers.
This was SVN commit r19503.
2017-05-01 14:28:22 +00:00
6ee830068a Print the name of OpenGL errors when they occur.
Patch by vladislavbelov
Differential Revision: https://code.wildfiregames.com/D313
This was SVN commit r19496.
2017-05-01 07:19:39 +00:00
37da3b008a Translate the Out-Of-Sync error message and send it to the JS GUI for convenience and future extension.
Add a hint that multiplayer games with AI are currently not supported.

Differential Revision: https://code.wildfiregames.com/D105
Reviewed By: leper
Refs #3858

This was SVN commit r19491.
2017-05-01 04:55:56 +00:00
7d6bfe27ab Clean up FromJSProperty a little. Patch by Vladislav.
Differential Revision: https://code.wildfiregames.com/D399
This was SVN commit r19489.
2017-05-01 00:58:35 +00:00
234aa36b25 Update the documentation on how to write simulation components.
Mention how to handle const methods (be1a205f91, D75).
Note that parameters are passed as const references (1a66f510d0).
Also remove mention of jsval (which is deprecated).

Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D374
This was SVN commit r19484.
2017-04-30 23:48:54 +00:00
ecaa8434b1 Cinematic path node moving tool for Atlas. Patch by Vladislav.
Differential Revision: https://code.wildfiregames.com/D369
This was SVN commit r19483.
2017-04-30 23:47:16 +00:00
c016a74309 Add sliders to the GUI. Use them for the sound/music volume controls.
Patch by vladislavbelov, based on a patch by dpiquet.

Fixes #4039.
Differential Revision: https://code.wildfiregames.com/D325
This was SVN commit r19479.
2017-04-30 16:51:18 +00:00
5a4cbc9261 Move CinemaManager includes forgotton in 5d49e6c456 to the right place, thus fixing the build without precompiled headers.
Refs https://code.wildfiregames.com/D385
Reported by: leper
Fix proposed by: Vladislav
This was SVN commit r19473.
2017-04-29 18:08:06 +00:00
41d4649c6d Remove unused, deprecated SendGetGameList from the lobby.
Differential Revision: https://code.wildfiregames.com/D389
Reviewed By: scythetwirler
Refs D207

This was SVN commit r19467.
2017-04-28 23:22:41 +00:00
e6a0c7ae77 Remove SendGetRatingList lobby function which is deprecated and ignored serverside since 1a15131d2d because it caused performance issues and therefore shouldn't be used anymore.
Fixes #4151
Patch by: sbirmi
This was SVN commit r19463.
2017-04-27 11:42:51 +00:00
f399e68654 Fix the lobby bot following the entity class rename in ad17e320be
Differential Revision: https://code.wildfiregames.com/D383
Patch By: user1
Refs #4536 D244

This was SVN commit r19457.
2017-04-25 16:53:42 +00:00
8f36ca47a1 Replace input.js doubleclick hack and ease doubleclicking on moving units.
Differential Revision: https://code.wildfiregames.com/D326
Patch By: causative
Refs #4414

This was SVN commit r19444.
2017-04-22 01:24:03 +00:00
234513ae51 Use per 100 meters spread values. Fix a bit the related help. Change and use simpler template values. Units will be a bit more accurate. Reviewed by wraitii.
Differential Revision: https://code.wildfiregames.com/D361
This was SVN commit r19438.
2017-04-20 17:01:47 +00:00
81c57e8a28 List, add and delete cinematic paths in Atlas.
Doesn't provide a way to add/delete nodes of paths yet.

Differential Revision: https://code.wildfiregames.com/D348
Patch By: Vladislav
This was SVN commit r19427.
2017-04-18 03:30:16 +00:00
1db8562d05 Revert and fix 4523c50850: fix water disappearing in Atlas when clicking on the object tab.
Reviewed by wraitii.
Differential Revision: https://code.wildfiregames.com/D329
This was SVN commit r19425.
2017-04-17 08:59:12 +00:00
1ec41f6dd0 Fix crash in dynamic subscriptions when components unsubscribe during deletion.
Discussed with Philip.
Reviewed by fatherbushido
Differential Revision: https://code.wildfiregames.com/D264
This was SVN commit r19424.
2017-04-17 08:00:41 +00:00
de9e76cbf1 Add a test to the component manager to show a crash in dynamic subscriptions when components unsubscribe during deletion. Reviewed by wraitii.
Differential Revision: https://code.wildfiregames.com/D346
This was SVN commit r19423.
2017-04-17 07:55:44 +00:00
adf60c7c49 Support cinematic path creation from trigger scripts.
Differential Revision: https://code.wildfiregames.com/D317
Patch By: Vladislav
Refs #3814

This was SVN commit r19422.
2017-04-17 01:42:11 +00:00
ce5c10c7bb Add FromJSProperty helper function that gets the property of a JS object, thus reducing duplicate checks when getting many properties.
Differential Revision: https://code.wildfiregames.com/D338
Patch By: Vladislav
Refs: https://code.wildfiregames.com/D317

This was SVN commit r19421.
2017-04-16 23:59:20 +00:00
b856ec5ea4 Update the Minimap texture if the waterheight has changed.
Differential Revision: https://code.wildfiregames.com/D344
Patch By: Sandarac
Reviewed By: Vladislav
Refs https://code.wildfiregames.com/D229

This was SVN commit r19420.
2017-04-16 22:13:32 +00:00
5462f26aba Move CinemaPath class to the simulation helper directory, because it contains predominantly simulation data that is already serialized.
The remaining graphics code should be moved or removed.

Differential Revision: https://code.wildfiregames.com/D324
Patch By: Vladislav
This was SVN commit r19414.
2017-04-14 23:20:49 +00:00
16afbf32c8 Fix CChart scaling edgecases (constant value and infinity)
Reviewed by: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D167
This was SVN commit r19408.
2017-04-11 12:27:21 +00:00
2e37e6a8d9 Remove redundant path name argument from the CinemaManager AddPath function.
Differential Revision: https://code.wildfiregames.com/D310
Patch By: Vladislav
This was SVN commit r19406.
2017-04-11 01:37:00 +00:00
65cbf12b7e Don't throw NetServer FSM errors if a client presses not-ready just before the host launches the game.
Differential Revision: https://code.wildfiregames.com/D290
Reviewed By: Imarok
Refs #3199

This was SVN commit r19404.
2017-04-10 16:52:52 +00:00
ee987d3b0d Add some consts to ShaderProgram functions
Reviewed by: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D315
This was SVN commit r19403.
2017-04-10 15:44:33 +00:00
e4b4126293 Fix Units demo map following the addition of the special filter templates in D215 / d093f714d7.
Expose the FindAllPlaceableTemplates function to the simulation to
remove the hardcoded directory checks as suggested by fatherbushido.
Add the new special template directory from D176 / cd6c31e76e.
Move the code from XML to JS.

Differential Revision: https://code.wildfiregames.com/D277
Reviewed By: Vladislav
This was SVN commit r19399.
2017-04-09 23:46:31 +00:00
af4466bc99 Update ready state immediately when receiving the message.
Differential Revision: https://code.wildfiregames.com/D304
Reviewed By: Vladislav
Refs #2447

This was SVN commit r19396.
2017-04-09 22:59:04 +00:00
2f02fb4535 Move OpenGL CinemaPath rendering code to the CinemaManager, so that the remaining simulation data can be moved to the simulation directory.
Add height indicator so that we can actually estimate the location of
the paths in atlas.

Differential Revision: https://code.wildfiregames.com/D306
Patch By: Vladislav
This was SVN commit r19394.
2017-04-09 17:21:01 +00:00
290e67dc32 Add cinematic page to the atlas editor with one option to enable rendering of existing paths.
Differential Revision: https://code.wildfiregames.com/D301
Patch By: Vladislav
This was SVN commit r19391.
2017-04-09 02:12:20 +00:00
32c0dc773e Fix memory leak in CCmpPathfinder, patch by Sandarac.
The terrain grid can be renewed without proper deallocation, which
happens at least at the start of a game when MT_TerrainChanged is sent.

Reviewers: wraitii, Itms

Differential Revision: https://code.wildfiregames.com/D247
This was SVN commit r19388.
2017-04-08 15:58:10 +00:00
7f07237bba Serialize the queue of cinematic paths playing and resume upon deserialization. Thereby fix an OOS on rejoin when a cinematic path is playing.
Move path de/serialization to private helper functions.

Differential Revision: https://code.wildfiregames.com/D299
Patch By: Vladislav
Refs #3814

This was SVN commit r19382.
2017-04-08 00:10:02 +00:00
ffea346abb Atlas camera controls should be disabled too if a cinematic path is paused.
Reviewed By: Vladislav
This was SVN commit r19376.
2017-04-05 04:00:19 +00:00
5d49e6c456 Move most cinematic path simulation data and control from the graphics class to the simulation component and solve the hash mimatch in non-visual replay.
Move graphics code to smaller helper functions UpdateSessionVisibility,
UpdateSilhouettesVisibility and DrawPaths.
Remove the hotkey TODO code which should be implemented differently.
Mark voids as const.

Differential Revision: https://code.wildfiregames.com/D271
Patch By: Vladislav
This was SVN commit r19375.
2017-04-05 03:59:20 +00:00
c0708da215 Fix the Mustang template. Add tests for the UnitMotionFlying component.
Patch by bb.
Reviewers: Itms

Differential Revision: https://code.wildfiregames.com/D139
This was SVN commit r19373.
2017-04-03 09:58:01 +00:00
1e07787e76 Revert 64bit number conversions added in c0ca70efd2, don't add the previous long and unsigned long conversions back and use double in the Replay menu.
64bit conversions (including the long ones) are not safe, because not
every number can be converted to the 2^53 JS numbers and pretending to
do so is asking for bugs.
Explicitly use the double type in the Replay menu, because std::time_t
is unspecified and some platforms like Ubuntu yakkety:i386 fail to
build, looking for long.
Double should work for the next 285 million years, becomes consistent
with SavedGame.cpp, is tested by test_ScriptConversions.cpp and doesn't
pretend to cover all 64bit numbers.

Patch By: echotangoecho
Differential Revision: https://code.wildfiregames.com/D205
Refs #3848 D84 D112

This was SVN commit r19367.
2017-04-01 21:06:55 +00:00
dbd56403b9 Allow hiding of list columns via XML or JS.
Differential Revision: https://code.wildfiregames.com/D228
Reviewed By: Vladislav
This was SVN commit r19353.
2017-03-28 00:25:17 +00:00
4523c50850 Fix a vertex shader data pielup in the actor editor. It was reloading the shaders far too often.
Patch by Echotangoecho.
Differential Revision: https://code.wildfiregames.com/D93
This was SVN commit r19346.
2017-03-25 07:44:31 +00:00
35377c51a7 Capture The Relic gamemode.
Patch By: Sandarac
Differential Revision: https://code.wildfiregames.com/D152
This was SVN commit r19345.
2017-03-25 07:01:07 +00:00
27f37ccd21 Cleanup the rest of the mess introduced with the NonGaiaEntities functions in 8c7b6dceaa.
Add a test for the GetNonGaiaEntities function of the RangeManager
broken by that commit that was fixed by f3e4e619bc.
Don't call one script function from another, but directly call into the
Selection helper like the others.
Don't make a loop around that RangeManager function for all players but
call the function once for all players.
The pointless virtual keywords were removed by 8827db201a.

Differential Revision: https://code.wildfiregames.com/D166
Reviewed By: leper
This was SVN commit r19344.
2017-03-25 02:42:51 +00:00
b9441a6a8d Ensure m_Territory in cmpTerriotryManager.IsTerritoryBlinking. Fixes #4466.
Patch By: Sandarac
Differential Revision: https://code.wildfiregames.com/D261
This was SVN commit r19343.
2017-03-25 01:43:14 +00:00
e69e10ef5f Small RangeManager cleanup.
Use std::set's logarithmic find instead of a linear loop.
Early return and some whitespace for getParabolicRangeForm.

Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D260
This was SVN commit r19342.
2017-03-25 00:11:08 +00:00
9e6571c461 Some cinema path cleanup.
Could possibly fix a compilation failure with some compilers in
36330732fa.

Patch By: Vladislav
Differential Revision: https://code.wildfiregames.com/D250
This was SVN commit r19341.
2017-03-24 22:49:06 +00:00
9f50bf3f1e Only dereference cmpWaterManager if it is non-null.
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D259
This was SVN commit r19340.
2017-03-24 21:32:49 +00:00
3648ba448d Some const for scriptinterface.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D155
This was SVN commit r19339.
2017-03-24 18:47:03 +00:00
9cf84c6800 Fix documentation of non system component.
Summary: -

Test Plan: -

Reviewers: Itms, leper

Reviewed By: leper
Subscribers: Vulcan, O1 C++ Simulation

Differential Revision: https://code.wildfiregames.com/D221
This was SVN commit r19337.
2017-03-24 07:09:28 +00:00
ff452de1f7 Mark GetAnimationName as const
Differential Revision: https://code.wildfiregames.com/D248
Reviewed By: leper
This was SVN commit r19325.
2017-03-22 23:07:01 +00:00
fdda57565b Display which clients are still in the loading screen
Reviewed by: elexis
Differential Revision: https://code.wildfiregames.com/D120
Fixes #4375

This was SVN commit r19320.
2017-03-21 18:50:29 +00:00
36330732fa Allow Cinematic Path nodes that only specify a camera position or direction and group them by deltatime.
Remove the support of saving the rotation of camera position nodes,
because that should be rewritten to use a custom spline.

Patch By: Vladislav
Differential Revision: https://code.wildfiregames.com/D124
Refs #3814

This was SVN commit r19317.
2017-03-20 15:26:34 +00:00
208b5b6dd8 Use a minimum height of at least one space character of the current font size when drawing list rows.
Use the maximum height of all cells of the current row.
Lobby games with empty servernames are not rendered weirdly anymore.

Patch By: Vladislav
Fixes #4402

This was SVN commit r19306.
2017-03-17 01:10:49 +00:00
d093f714d7 Use XML files instead of hardcoded C++ code in the template manager to universally change template properties at load time.
Patch By: leper
Differential Revision: https://code.wildfiregames.com/D215
Fixes #2951

This was SVN commit r19302.
2017-03-16 19:56:12 +00:00
c288a91c6d Add a GetAnimationName getter function for the VisualActor component, so that the simulation can not only set an animation but also find out which one is currently being played.
Differential Revision: https://code.wildfiregames.com/D219
Reviewed By: bb
This was SVN commit r19299.
2017-03-15 14:27:51 +00:00
17068bbf82 Update Lobby Bot README.
Reviewers: Itms

Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D79
This was SVN commit r19264.
2017-03-02 19:19:45 +00:00
39fcd1d031 Implement clientside kick/ban support for the lobby.
Displays a chat notification for all lobby clients if a client is kicked
or banned, pop up a message box for the affected one, including the kick
reason.
Clean the player- and gamelist upon disconnect and disable the control
elements.

Reviewed By: Imarok
Differential Revision: https://code.wildfiregames.com/D116
This was SVN commit r19250.
2017-02-28 11:16:46 +00:00
f3e4e619bc RangeManager returns Gaia entities in GetNonGaiaEntities
refs #4495
Reviewed By: leper, elexis
Differential Revision: https://code.wildfiregames.com/D164
This was SVN commit r19245.
2017-02-26 10:26:35 +00:00
360ba27865 Cleanup of CCmprangeManager
Summary: Following discussions in https://code.wildfiregames.com/D60 the
use of u8 to store each boolean has been cleanup up. Now only one u8 is
used, thus reducing the size of the struct.

Reviewed By: leper
Differential Revision: https://code.wildfiregames.com/D101
refs #3834

This was SVN commit r19242.
2017-02-24 19:15:54 +00:00
a0a0895a12 Pass some strings and a vector as const refs.
Reviewed By: Imarok
Differential Revision: https://code.wildfiregames.com/D160
This was SVN commit r19240.
2017-02-24 17:02:10 +00:00
5e5b5be656 Improve component cache lookup performance slightly.
We do not need iteration order, and this makes this explicit.

Reviewed By: echotangoecho
Differential Revision: https://code.wildfiregames.com/D82
This was SVN commit r19235.
2017-02-22 19:27:58 +00:00
e1e4ef0370 Add UpdateAutoScroll calls to some events where they were missing. For example when deleting, cutting, pasting, autocompleting or doubleclicking text. Patch by Vladislav, fixes #4401.
This was SVN commit r19234.
2017-02-22 15:28:09 +00:00
e0f7578fbe Ensure unique client GUIDs. Patch by sbirmi, fixes #3949.
Two clients chosing the same GUID is highly unlikely, yet possible.
A malicious client chosing an existing GUID would have resulted in
unassigning the player with that GUID.

This was SVN commit r19225.
2017-02-14 16:54:34 +00:00
5f8f7bae20 Stay ready button
Reviewed by: elexis
Differential Revision: https://code.wildfiregames.com/D49
Fixes #4369.

This was SVN commit r19216.
2017-02-10 16:09:10 +00:00
0e2d2610c9 Display a nice error message when trying to register too many lobby accounts
(This is a workaround that will be removed when gloox has fixed the
issue.)

Reviewed by: elexis
Refs #3771
Differential Revision: https://code.wildfiregames.com/D87
This was SVN commit r19205.
2017-02-07 15:05:26 +00:00
5130bb69d3 Use std::time_t in the replay menu (as 64bit integer conversion are implemented now) and remove the unused filemoddate fallback.
Differential Revision: https://code.wildfiregames.com/D112
Reviewed By: echotangoecho
This was SVN commit r19200.
2017-02-05 02:18:33 +00:00
c0ca70efd2 Fix 64-bit integer script conversions by removing the discrepancy between Windows and Linux.
Patch by echotangoecho, fixes #3848.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D84
This was SVN commit r19189.
2017-01-30 10:21:08 +00:00
584ccd690e Remove lib/pointer_typedefs.h. Patch by echotangoecho.
Reviewed By: Itms, leper
Differential Revision: https://code.wildfiregames.com/D83
This was SVN commit r19184.
2017-01-29 00:06:28 +00:00
6ae2db53db Employ some variadic macros to make some of the C++ -> JS function calling code nicer.
Template-ize CallFunctionVoid.
Changes CallFunction parameter order to make template parameter
deduction with
variadic parameters work nicely.

Reviewed By: Itms, wraitii, Yves
Differential Revision: https://code.wildfiregames.com/D77
This was SVN commit r19183.
2017-01-28 23:37:15 +00:00
fd5bd8e301 Fix 9964bee5bb.
Differential Revision: https://code.wildfiregames.com/D100
Reviewed By: Imarok
This was SVN commit r19182.
2017-01-28 20:47:26 +00:00
a74fcdcb35 Durations over 1 hour aren't displayed correctly
Reviewed by: elexis
Differential Revision: https://code.wildfiregames.com/D44
refs #4418, #3350

This was SVN commit r19180.
2017-01-28 10:59:53 +00:00
c2d0327af9 Implement shared vision at the entity level
Summary:
To fix tickets like #3335, having a shared vision at the entity level is
needed. This patch implements that in CCmpRangeManager, interfaced with
a new JS component VisionSharing to manage the shared entities visions.
As an example of use case (in addition to garrisoning in allied
structure without the sharedLos tech), we can think of bribing enemy
units: there is a part about it in the patch, but this one is very wip
and not intended to be committed but rather for test purposes of the
feature.
So when garrisoning a unit in another player's building, the vision of
the garrisonHolder is shared (part intended for review). In addition,
for tests of the feature, when clicking on the new bribe icon in the
diplomacy window, a random unit of the chosen player is bribed and share
its vision during 15 s.

Test Plan: Garrison a unit in an allied structure without the sharedLos
tech, or test the wip bribe feature from the diplomacy window.

Reviewers: Itms

Reviewed By: Itms
Subscribers: Stan, leper, O11 Templates, wraitii, elexis, fatherbushido,
Itms, Vulcan, O1 C++ Simulation

Differential Revision: https://code.wildfiregames.com/D60
This was SVN commit r19175.
2017-01-26 21:10:46 +00:00
9964bee5bb Change the NetServer Broadcast function to send the given message to clients that are in one of the states specified by the caller.
Thus remove the peculiarity to broadcast to clients that are in the
gamesetup, loading screen or ingame, but not rejoining ones.

Fix "unknown player" errors in the GUI by broadcasting player
assignments to rejoining players too. Fixes #4036.

Differential Revision: D17
Reviewed By: Imarok
This was SVN commit r19171.
2017-01-25 19:04:17 +00:00
4f01db4831 Split TurnManager classes into individual files per class. Patch by echotangoecho, fixes #4095.
Remove the "Net" prefix from the non-networked classes.
Use variadic macros and mark the client turnmanager as NONCOPYABLE.

Differential Revision: D16
Reviewed By: leper
This was SVN commit r19165.
2017-01-24 02:04:50 +00:00
8fec942e8a Fix Atlas under macOS Sierra.
We were polling SDL messages from two different threads (by mistake),
and Sierra now refuses to do that.
Tested by Stan, Itms, Fatherbushido, and discussed with Philip for the
code change itself.
Fixes #4408.
Differential Revision: https://code.wildfiregames.com/D42
This was SVN commit r19160.
2017-01-21 09:54:08 +00:00
be1a205f91 Add support for const methods in components and make those that can be const const.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D75
This was SVN commit r19156.
2017-01-20 02:25:19 +00:00
678e082230 Remove the "quit" simulation command and restrict the "set-shading-color" simulation command to AIs,
since they are only useful for AI debugging and counterproductive in
multiplayer mode, refs #3551.

Instead, enable AI developers to exit the game from a new AI API
command,
allowing to batch simulate matches. Refs #2755.

Differential Revision: D65
Reviewed By: leper
Consulted: mimo

This was SVN commit r19155.
2017-01-19 14:45:32 +00:00
b3b47c1718 Avoid recreating the dirtiness grid every turn by swapping. Significantly reduces the number of allocations, and slight speedup (particularly on larger maps). Reviewed by Leper.
Differential Revision: https://code.wildfiregames.com/D70
This was SVN commit r19149.
2017-01-17 07:24:41 +00:00
0a6a42321d Improve cache efficiency of CcmpPathfinder::UpdateGrid substantially. On very large maps, this can be a very substantial improvement (I have measured up to 30ms)
This was SVN commit r19146.
2017-01-16 10:41:35 +00:00
ad76352cef Prevent the AI manager from copying the pathfindinder dirtiness grid every turn.
Review by Itms

Differential Revision: https://code.wildfiregames.com/D25
This was SVN commit r19145.
2017-01-16 08:38:31 +00:00
3a85d0b3fa Remove unused parameter from template loading code
Templates should be the same for all players, techs can be used to
provide
different lists of templates if that is needed.

Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D25
This was SVN commit r19142.
2017-01-15 18:41:53 +00:00
103a59ec1e Fix a space tab inconsistency detected by python3.
This was SVN commit r19139.
2017-01-13 08:40:54 +00:00
b5991e188b TemplateLoader cleanup.
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D26
This was SVN commit r19119.
2017-01-07 17:52:32 +00:00
2bae30c454 Fix [19027] by using generic code for conversions and fixing a few other issues. Refs #3403. Reviewed by leper.
Also fix some of the warnings that jenkins showed.

Differential Revision: https://code.wildfiregames.com/D24
This was SVN commit r19115.
2017-01-06 11:14:03 +00:00
3c8fc4f263 Return "local" from GetPlayerGUID to avoid duplicate checks and allow AIs to send private messages to the single player. Refs #4431.
Reviewed By: mimo
Differential Revision: https://code.wildfiregames.com/D38
This was SVN commit r19112.
2017-01-05 10:22:39 +00:00
4068f2e14a Fix warning with GCC in our lowlevel PNG texture code.
Ensure a variable is not clobbered by libpng's use of longjmp. Make code
more consistent.

Differential Revision: https://code.wildfiregames.com/D35
This was SVN commit r19111.
2017-01-04 21:05:08 +00:00
81eb74163e Happy New Year *cough*(Years)*cough*!
Also fix some whitespace.

This was SVN commit r19110.
2017-01-04 21:00:16 +00:00
11ce52f8c5 Fix a few mistakes in the lobby readme.
Differential Revision: https://code.wildfiregames.com/D27
This was SVN commit r19087.
2016-12-31 00:11:30 +00:00
fd8df9143b Remove some semicolons at end of line in a python script.
This was SVN commit r19073.
2016-12-27 09:42:02 +00:00
55e9fee616 Add ptol civ and hero class to template analyzer tool.
This was SVN commit r19067.
2016-12-26 20:31:01 +00:00
490a3a27f6 Fix the cache directory appearing during tests.
Summary: Refs #4419.

Test Plan: When running tests, make sure nothing is created.

Reviewers: leper

Reviewed By: leper
Subscribers: leper, Vulcan

Differential Revision: https://code.wildfiregames.com/D1
This was SVN commit r19062.
2016-12-25 22:03:30 +00:00
40fd373c83 Revert [19043]
This was SVN commit r19054.
2016-12-21 12:36:41 +00:00
a4c68b664b Add the executable flag to the translation maintenance script
This was SVN commit r19047.
2016-12-18 17:36:40 +00:00
8e8da9aee4 Fix a bug introduced by a fix of a bug introduced by a fix of a bug (x100) in the vertex pathfinder. Revealed by automated tests on another branch of mine. Revert back to pre-new pathfinder behavior of not returning paths in some cases, since that is most likely less broken than now - but probably still a little broken.
This was SVN commit r19043.
2016-12-18 10:02:36 +00:00
9288837472 Fix misleading indentation warning on gcc, introduced by [19024]. Reported by elexis. Fixes #3785
This was SVN commit r19041.
2016-12-13 13:34:31 +00:00
e7eeb6927d Remove deprecated water parameters. Patch by paulobezerr. Partial review by FeXoR. Fixes #4292.
This was SVN commit r19040.
2016-12-12 23:46:46 +00:00
507ecff2ed Scroll to the top when switching between tabs in the credits. Patch by vladislavbelov
This was SVN commit r19036.
2016-12-11 21:15:50 +00:00