Commit Graph

12916 Commits

Author SHA1 Message Date
hiker
18f14ae142 Fixed compiler warnings. 2016-11-24 17:48:23 +11:00
hiker
b1afac23a7 Moved creation of the race protocols into lobby, so SynchronizationProtocol
is not involved in the race start anymore.
2016-11-24 08:56:30 +11:00
hiker
617e1c538d Merge remote-tracking branch 'origin/master' into nw 2016-11-23 21:58:00 +11:00
hiker
414b0e0633 Fixed sending 'client ready' twice. 2016-11-23 18:50:44 +11:00
hiker
dd515292ee Fixed deadlock (in case of protocol error). 2016-11-23 18:40:56 +11:00
hiker
62da83317e Fixedc compilation, renamed LobbyRoomProtocol to LobbyProtocol. 2016-11-23 18:39:59 +11:00
Benau
a2bb0487b1 Disable backface culling when set in the material. 2016-11-23 15:16:19 +08:00
hiker
2c7e7d8722 Merge remote-tracking branch 'origin/master' into nw 2016-11-23 17:16:42 +11:00
Benau
eb84de2666 Fix #2491 2016-11-23 10:11:08 +08:00
hiker
026e1623ec Renamed ServerLobbyRoomProtocol to just ServerLobby, ClientLobbyRoomProtocol
to ClientLobby, and LobbyRoomProtocol to Lobbyprotocol.
2016-11-23 09:39:33 +11:00
hiker
09eae7e25f Removed StartGameProtocol, and added the necessary states to the
Lobby rooms. Added documentation of the FSM for the ServerLobby.
2016-11-22 17:57:15 +11:00
Benau
61a00a9068 Fix transparent displacement rendering with advanced pipeline off
Allowing them to render using the same custom alpha uniform used
by ghost karts, fixed #2459.
2016-11-22 12:34:48 +08:00
Benau
690d36271d Try to fix LOD in legacy pipeline 2016-11-22 00:51:10 +08:00
Benau
befa2394a8 Some improvement to #2667 2016-11-21 11:58:46 +08:00
Benau
72ff03c024 Fix light in legacy pipeline 2016-11-21 11:10:40 +08:00
Benau
de95db5c93 Avoid creating new glyph page too many times 2016-11-20 10:08:59 +08:00
Benau
9734c2e890 Fix crash in billboard text when using legacy opengl
Notice: freetype glyph metrics are not supported
2016-11-19 15:59:58 +08:00
Benau
a52c4699a1 Add back normal map renderer for legacy opengl
Fixed transparent issue
2016-11-19 14:21:56 +08:00
Benau
f853255204 Merge branch 'fix_1704' 2016-11-18 09:51:34 +08:00
Benau
9eb6ef5bfe Simplify code 2016-11-18 09:44:30 +08:00
Deve
952bed5672 Few minor fixes for multitouch steering:
- don't update a button that is already not pressed
- use full axis range, which means higher sensitivity in the center
- make sure that we don't divide by 0
2016-11-18 01:22:32 +01:00
hiker
6b1563321f Use singleton for lobby protocols. 2016-11-18 09:08:37 +11:00
Benau
ac74304dd7 Fix #1704 2016-11-18 00:31:48 +08:00
Benau
b6c1a45918 Use a better define 2016-11-16 10:20:40 +08:00
hiker
ba600f40f2 The server waits now for all client to start (which means it will be
behind the clients by the maximum latency, which in turn means that
at server time T all client events at time T have arrived, so less
rollback necessary).
2016-11-16 08:48:04 +11:00
hiker
fbd858a64c Fixed non-server compilation. 2016-11-15 12:52:37 +11:00
hiker
ae36208e29 Merge remote-tracking branch 'origin/master' into new-pi 2016-11-15 12:38:21 +11:00
Benau
2f2940115e Use a smooth dt on camera to determine its position 2016-11-14 15:47:55 +08:00
hiker
621e61c644 Fixed coding style. 2016-11-14 18:32:29 +11:00
hiker
13bcdcade6 Fixed crash in case of standalone server. 2016-11-14 10:15:40 +11:00
hiker
245045f575 Fixed various crashes on server. 2016-11-14 10:09:25 +11:00
hiker
f2b67f75b6 Minor coding style fixes. 2016-11-14 10:02:46 +11:00
hiker
73182863df Fixed linking problems - will probably not run ;) 2016-11-14 09:59:08 +11:00
Benau
5879933a23 Merge remote-tracking branch 'origin/master' into fix_2112 2016-11-13 10:42:47 +08:00
Deve
e707b7a2ea Remove pthread_setcancelstate functions.
This function is not available on android and it is default on other platforms anyway.
It makes easier to port changes from master to android branch.
2016-11-11 14:11:27 +01:00
hiker
61a3d10e10 More Compile SERVER_ONLY, still not fully working. 2016-11-12 00:09:39 +11:00
Deve
6b2bf1c088 Make sure that we are not out of array.
Command line arguments are not available on android.
2016-11-11 14:07:18 +01:00
hiker
ddcddf4a0a Compile SERVER_ONLY (by #ifdef'ing out all graphics related code).
Does not link yet!!
2016-11-11 23:46:22 +11:00
hiker
8d9bb9c30f Cherry picked commits from old pi branch (which was based on dumb client). 2016-11-11 17:21:59 +11:00
hiker
8ecb0ecaeb Merge branch 'master' of github.com:supertuxkart/stk-code 2016-11-11 15:35:30 +11:00
hiker
fd5f60a786 Merge branch 'master' of github.com:supertuxkart/stk-code 2016-11-11 15:27:45 +11:00
hiker
190490e0ce Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-11-11 15:15:02 +11:00
Benau
6b282acae2 Use bullet built-in function 2016-11-11 10:20:15 +08:00
Benau
8b069df97f Merge remote-tracking branch 'origin/renderer_refactoring' 2016-11-11 08:43:42 +08:00
hiker
10b7dac658 Replaced static with dynamic casts, fixed docu. 2016-11-11 09:14:18 +11:00
hiker
10575174fc Fix for disabling LAN detection. 2016-11-11 08:47:10 +11:00
hiker
6065a6ce3e Added debug option to disable automatic LAN connection. 2016-11-10 18:21:27 +11:00
deve
4bb0405a32 Added support for multitouch steering.
It will be used for steering on Android.

There are some limitations:
- currently it works only in single player mode (but I don't see any reason to make it working for multiplayer)
- speedometer is not available in race GUI because there is no place for it

TODO:
- add DPI support (race GUI should have probably different proportions on smaller devices for comfortable playing)
- make nice button images
- make nitro button that changes its look depending on collected nitro (a kind of nitro bar)

Touch input events must be handled in android device to make use of it. It can be simulated for debugging on non-android devices using standard mouse.
2016-11-10 02:42:56 +01:00
hiker
9201a08daf Fix crash exiting a server screen. 2016-11-09 23:24:04 +11:00
hiker
64d2d43f5b Disable console (for #2665). 2016-11-09 23:06:17 +11:00
Benau
8a0d911d10 Allow using input method (for CJK) in linux 2016-11-09 12:28:23 +08:00
Benau
0c0581f97a Merge remote-tracking branch 'lpw/malice' 2016-11-05 11:25:19 +08:00
LoadingPleaseWait
578a3732c0 Add help page with icons for banana penalties 2016-11-04 22:16:06 -05:00
Benau
214ea6801b Merge remote-tracking branch 'origin/master' into renderer_refactoring 2016-11-04 21:06:42 +08:00
Benau
9da38a2755 Fix Mac build 2016-11-04 21:05:07 +08:00
Benau
7da108c8b1 Header clean up
Also move getUnicolorTexture to a better location
2016-11-04 20:30:08 +08:00
Benau
01c7576755 Update prefilled textures if new RTT is used
Required by multiplayer kart selection screen
2016-10-31 14:13:38 +08:00
Benau
253281aaeb Avoid crashes in fixed pipeline RTT if it fails 2016-10-31 11:57:15 +08:00
Benau
1678078aea Fix GLES 2016-10-31 09:15:50 +08:00
Benau
07ebb760ac Try to make RTT creation as close to master as possible 2016-10-31 00:33:06 +08:00
Benau
7998c326fc Prevent using uninitialized values 2016-10-30 14:44:08 +08:00
Benau
df57a73813 Fix start projection of karts 2016-10-30 10:10:09 +08:00
Benau
fc47d6e220 Minor header clean up 2016-10-29 10:37:45 +08:00
Benau
0165469301 Fix build 2016-10-28 23:46:24 +08:00
Benau
2f0252be98 Merge remote-tracking branch 'origin/master' into renderer_refactoring 2016-10-28 21:41:49 +08:00
hiker
9f4c842b6c Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-27 21:36:17 +11:00
hiker
fda3afad93 Fix 2658 by separating networking code from main loop. 2016-10-27 21:33:42 +11:00
Benau
956aa83a0a Remove unused function 2016-10-27 10:15:41 +08:00
Benau
93197d9569 Merge branch 'fix_2445' 2016-10-27 09:41:35 +08:00
Benau
d4e9de1f53 Fix non-animated karts 2016-10-27 09:41:01 +08:00
hiker
94346ae64d Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-27 11:13:19 +11:00
hiker
b3b9d16ba1 Removed unnecessary logging. 2016-10-27 08:48:38 +11:00
hiker
2c56837ee8 Fixed token handling. 2016-10-27 08:41:35 +11:00
hiker
b1f6632e5b Changed countdown from a mixture of ms and seconds to seconds only;
added documentation.
2016-10-27 08:40:45 +11:00
deve
bc7f89d49a Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-26 13:51:40 +02:00
deve
8d270e5ff3 Fixed nitro bar for non-HD textures 2016-10-26 13:51:17 +02:00
Benau
e93e8b7708 Make animated mesh render separately in instanced rendering
Try to introduce mesh + render info hash in vao manager, without
copying the mesh
2016-10-26 14:25:48 +08:00
Benau
9bd4c87b9c Fix leaking createTextBillboard 2016-10-26 09:21:17 +08:00
Benau
cc3ff7cf9f Simplify calculation of transform 2016-10-26 09:08:10 +08:00
Benau
a38c8f0c19 Make billboard text display properly when viewing in any direction 2016-10-26 00:34:13 +08:00
hiker
e31a7ca4a8 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-25 10:05:28 +11:00
hiker
6a578e374f Fix LAN handling when connecting via a WAN server. 2016-10-25 07:53:52 +11:00
Benau
68ea2ed3b2 Fix typo 2016-10-22 12:33:47 +08:00
Benau
cf557f6982 Fix release build 2016-10-22 10:46:30 +08:00
Benau
3e70fa27d9 Add doxygen for Font modules
Plus some coding-style cleanup
2016-10-22 00:01:48 +08:00
hiker
df21ba55b4 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-21 08:31:11 +11:00
Benau
7505630cd4 Add doxygen for Soccer and SpareTire AI 2016-10-21 01:38:30 +08:00
Benau
021509387d Add doxygen for Arena and Battle AI
Plus some coding-style cleanup
2016-10-20 16:40:20 +08:00
Benau
b12f7a1079 Fix shaking u-turn 2016-10-19 00:37:29 +08:00
Benau
24f926b780 Merge remote-tracking branch 'origin/spare_tire_kart' 2016-10-18 14:32:44 +08:00
Benau
8eb8e805eb Fix dropping of normal map wheel in battle mode 2016-10-18 14:18:51 +08:00
Benau
f1caba7932 Make ArenaAI reverse more naturally 2016-10-18 10:33:27 +08:00
Benau
9aa92cfe30 Fix profiling mode framerate regression 2016-10-18 09:55:30 +08:00
auria.mg
8c0fe53ff2 Fix texture mirroring on alpha blend/test shaders. See #2167 2016-10-17 19:46:21 -04:00
auria.mg
9d1b115e59 Don't call OpenAL's position method when audio is disabled 2016-10-17 19:15:28 -04:00
auria.mg
513e32d9ff Fix bug that could cause reversible textures to be mirrorred twice when driving the track in reverse (see #2167) 2016-10-17 19:09:01 -04:00
LoadingPleaseWait
eddf39b8a1 Remove duplicate include statements from kart.cpp 2016-10-17 03:36:29 -05:00
Benau
caf095ed60 Add improvements from auria and devee 2016-10-17 09:13:07 +08:00
Benau
af223ddf24 Try to use sun color to determine custom alpha for ghost karts
This may need more adjustments, also add custom_alpha uniform float
to transparent fragment shader to remove duplicated shader
2016-10-17 01:03:10 +08:00
Benau
23a1b08efe Allow normal map karts to be used in ghost race
Also split ghost karts out of additive shader, so fixed issues like
"drivers are facing backwards", "water in abyss affects ghost karts"

Todo: maybe transparency depend on current track color?
2016-10-16 15:40:40 +08:00
auria.mg
929b9b5c20 Stop world imer when game is paused 2016-10-15 20:28:48 -04:00
auria.mg
020edf1679 Add support for directional (forward-only or backwards-only) driveline segments 2016-10-15 18:56:13 -04:00
Benau
1f8149f138 Merge remote-tracking branch 'origin/skinned_mesh_normal_map' 2016-10-15 15:25:20 +08:00
Benau
604e454f33 Fix normal map in library and track objects if they are animated 2016-10-15 15:21:34 +08:00
Benau
efb6b7431a Try to make skinned mesh work with normal map 2016-10-15 00:17:09 +08:00
hiker
35e382b893 Remove unnecessary request for server address,since it is now included
for each server in the list of all servers.
2016-10-14 18:08:39 +11:00
Benau
f70a64f61a Fix controller and text billboard leaking in kart 2016-10-14 12:01:37 +08:00
Benau
e09fe6ff8a Fix memory leak of mesh tool 2016-10-13 14:08:58 +08:00
hiker
62b9b93d10 Merge branch 'master' of github.com:supertuxkart/stk-code 2016-10-13 14:06:48 +11:00
hiker
85e0fed9b7 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-13 11:14:40 +11:00
hiker
83ffbd96e1 Better error message in case of a failure to creaet a server. 2016-10-12 17:21:15 +11:00
hiker
061827a1ac Ported to use the new server (Issue65 branch). 2016-10-12 17:09:57 +11:00
Benau
965e901796 Fix typo 2016-10-12 14:00:51 +08:00
Benau
48e6128e12 Grab light in the correct place, fixed all leaking of lights 2016-10-12 11:48:50 +08:00
Benau
ddcf6fbb14 Fix memory leaking when changing resolution 2016-10-12 10:28:33 +08:00
Benau
7df560ae63 Fix leaking of scripting engine 2016-10-12 09:30:08 +08:00
Benau
b2cdc8c97e Fix memory leak of unicolor texture
Also try to hold them until the last moment, this may need some
testing.
2016-10-11 16:25:22 +08:00
hiker
b0bb6ce00f Simplified structure. 2016-10-11 18:13:21 +11:00
hiker
3243f81f10 Avoid crash. 2016-10-11 18:02:11 +11:00
hiker
68f5259f4d Removed static variables and properly initialised in setup, which
should allow this protocol to work for more than one race.
Back-ported to master.
2016-10-11 17:58:43 +11:00
Benau
ef7201cf51 Remove an unneeded line 2016-10-11 12:24:36 +08:00
Benau
fb79cf3a6e Let spare tire karts follow bounding box points 2016-10-11 10:52:08 +08:00
Benau
28f1e45f79 Really fix model view widget 2016-10-11 09:09:09 +08:00
hiker
7b3fc04d26 Removed debug output. 2016-10-11 08:46:14 +11:00
hiker
09ce5515b0 Avoid extrapolation by making sure the client starts after receiving
a message from the server, and only updating the previous position
if the new previous position is indeed before the current client time.
Fixed conflicts, removed dumb-client related interpolation code, left
client starting in place.
2016-10-11 08:44:17 +11:00
Deve
850b23db1f Fixed setting viewport in multiplayer games.
It was broken in commit 5cfed1bc1c.

We mix irr_driver->getVideoDriver()->setViewPort() and glViewport(...) functions and thus the first one, which is executed during camera activation, in some cases doesn't work. It compares the viewport to values which has been set last time and thinks that nothing changed.

It only happens on single player (with single camera), so we just restore the viewport to fullscreen after scene rendering to workaround the issue.

Actually the problem was that it was set after camera activation, which overwrote proper values.

I also fixed SSAO, RSM and normals vizualization in multiplayer games.
2016-10-10 22:47:30 +02:00
Benau
6750fb3c94 Fix leaking of script engine 2016-10-11 00:11:45 +08:00
Benau
1a9a4c626e Properly add the model view widget
Use add() will set angle = 0 in ModelViewWidget
2016-10-10 14:38:30 +08:00
Benau
d1c1435b55 Use a better string 2016-10-10 05:16:19 +00:00
Benau
8e2d7c5499 Fix memory leaks and uninitialized values of ShadowMatrices 2016-10-10 13:04:40 +08:00
Benau
d39f5e487b Don't set position and target of camera the same
Otherwise NAN will be calculated in ViewArea of camera
2016-10-10 13:04:40 +08:00
Benau
aaa0e11770 Fix using uninitialized values when init() the first time 2016-10-10 13:04:40 +08:00
Benau
03f9fb35da Fix valgrind warning 2016-10-10 13:04:34 +08:00
Benau
4ed599403e Show a message when a life gained 2016-10-10 08:47:10 +08:00
hiker
91363f820b Disable slow-down of game time in case of very low FPS when networking
is used (this would desynchronise client and server).
2016-10-10 09:54:44 +11:00
hiker
d00f2abb0b Fixed item collection (token must not be tested by protocols anymore). 2016-10-10 09:54:11 +11:00
Benau
fdcb4dac8d Fix assertion when no spare tire karts 2016-10-09 17:41:20 +08:00
Benau
b4907f5519 Tell player that they have max 3 lives only 2016-10-09 13:52:24 +08:00
Benau
fb0f4fca3c Allow BattleAI to collect lives 2016-10-09 13:24:00 +08:00
Benau
6b8156c254 Pre-spawn spare tire karts on random nodes in graph
Don't use the item location, as it can be remembered by players
2016-10-09 11:17:36 +08:00
Benau
357567ae8d Move spare tire num info to race_manager
It allows this info to be get more easily
2016-10-09 09:50:26 +08:00
Deve
8092cfc0a7 Fixed displaying some special characters in keys binding in options.
It most probably needs to be done this way since commit 2096532d0e.
I don't know what about OSX, so I enabled it only for linux.
2016-10-08 21:26:20 +02:00
Benau
71359a087d Add heart billboard with red kart for spare tire karts 2016-10-08 14:29:28 +08:00
Benau
8889654d96 Move STA function out of world 2016-10-08 09:41:02 +08:00
Benau
9096bb05bd Merge remote-tracking branch 'origin/master' into spare_tire_kart 2016-10-08 08:36:05 +08:00
Benau
59edb96489 Fix warning when eliminate a kart in battle mode 2016-10-08 08:35:07 +08:00
Benau
71662df159 Improve spawn formula 2016-10-07 21:49:05 +08:00
Benau
c907442bb4 Fix incorrect target node access 2016-10-07 16:43:54 +08:00
Benau
2147b74fe4 Fix engine sound after re-spawn 2016-10-07 16:03:15 +08:00
Benau
b055fa573d Try to fix hangs when firstly spawn STA 2016-10-07 15:29:36 +08:00
Benau
91af45337f Pre-add spare tire karts probably 2016-10-07 14:39:39 +08:00
Benau
b66e6ef06d Use MaxSpeed to slow down spare tire karts 2016-10-06 00:35:52 +08:00
deve
ce28d46d14 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-05 11:30:22 +02:00
deve
7a82a8d2c6 Fixed compiler warning 2016-10-05 10:56:40 +02:00
deve
bd42f2c2df Fixed rare case that anisotropic filtering feature is not available in graphics drivers. 2016-10-05 10:50:20 +02:00
Benau
a0b02659f7 Don't use num of karts from world, as it includes spare tire karts 2016-10-05 16:42:37 +08:00
Benau
a91af96637 Initial work on spare tire kart in battle mode
Some values are hard-coded for now
2016-10-05 16:18:39 +08:00
Benau
43d9db4db0 Fix acceleration and braking of ArenaAI 2016-10-05 11:53:45 +08:00
hiker
5767f2294e Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-10-05 13:32:13 +11:00
hiker
ceb961ae87 Fixed reverse camera (smooth speed was positive even when
going backwards).
2016-10-05 13:31:31 +11:00
hiker
3506b7da2f Merge pull request #2615 from nado/warning-fix
Fixes warnings
2016-10-05 12:59:22 +11:00
hiker
8949e89809 Merge remote-tracking branch 'origin/master' into rewind
Fixed conflicts.
2016-10-05 08:21:10 +11:00
Nado
d21630c815 This simplifies the reading of bool isEasterMode() 2016-10-04 08:55:07 +02:00
Nado
25a4aa565a Reduce variables scope when possible, based on the warnings reported by
cppcheck.
2016-10-04 08:55:01 +02:00
Nado
afbea19d34 Fix -Wunused-variable 2016-10-04 08:44:50 +02:00
Nado
4c0b4d8078 Fixes -Wsign-compare
See #2613
2016-10-04 08:43:38 +02:00
hiker
9595a76d36 Removed unnecessary flag to keep track if speed icnrease is defined. 2016-10-04 08:28:01 +11:00
hiker
84a3f5d8b2 Fixed compiler warnings. 2016-10-04 08:16:35 +11:00
hiker
9cf88ef874 Merge remote-tracking branch 'origin/master' into rewind.
Fixed conflicts.
2016-10-04 08:15:40 +11:00
hiker
50b1a8cdfb Added some (commented out) code to investigate camera shaking - if it
should happen again.
2016-10-03 18:13:03 +11:00
Benau
21a04213d5 Fix typo 2016-10-03 10:30:06 +08:00
Benau
78e6cfc8db Merge remote-tracking branch 'origin/master' into walldriving 2016-10-03 10:03:12 +08:00
Benau
13eaf82af1 Patch TestAI with changes to SkiddingAI 2016-10-03 10:02:27 +08:00
Benau
e2030dabbc Disable AI debug 2016-10-03 09:54:02 +08:00
Benau
c64c8717a5 Use 16bit integer to save some space in ArenaGraph 2016-10-03 09:28:12 +08:00
auria.mg
6e37c5375a Fix end camera crash 2016-10-02 20:18:40 -04:00
Benau
3f71745d92 Only rescue AI if it's on the ground 2016-10-02 15:04:08 +08:00
Benau
fc94c5e4c4 Change the whole path to avoid bad items 2016-10-02 15:03:09 +08:00
Benau
d3301ff006 Allow battle ai profiling with different track 2016-10-01 12:35:57 +08:00
Benau
c434cb80f4 Significantly improve turning and bad items avoidance for ArenaAI 2016-10-01 07:58:14 +08:00
Benau
62dfef1fb9 Improve performance for findOutOfRoadSector on ArenaGraph 2016-09-30 09:27:44 +08:00
Benau
3c24c73faa Fix unknown sector in arena after rescue 2016-09-30 08:15:36 +08:00
Benau
c22714951c Missed reset before update TrackSector 2016-09-30 00:42:04 +08:00
Benau
d386c76e2d Fix explosion animation on upside down area 2016-09-29 14:37:39 +08:00
Benau
43c40c062e Make m_bb_max and m_bb_min private in Graph again
Avoid setting them in ArenaGraph, let createQuad handle them all
2016-09-29 13:36:50 +08:00
hiker
18b1218312 Oops - made boundary box protected again, it is accessed in the ArenaGraph. 2016-09-29 15:21:59 +10:00
hiker
2e38154bd6 Merge branch 'walldriving' of github.com:supertuxkart/stk-code into walldriving 2016-09-29 15:12:11 +10:00
hiker
0b76a576a3 Exit loop as soon as kart is found to be on one GraphNode. 2016-09-29 15:11:08 +10:00
hiker
fb7b42a625 Fixed compiler warning. 2016-09-29 15:10:51 +10:00
hiker
7f6d800fe7 Made the boundary box private to Graph. 2016-09-29 15:10:26 +10:00
Benau
32f87fa8a9 Fix wrong doxygen comments 2016-09-29 10:19:18 +08:00
Benau
df52922d08 Clean up unused function and wrong comment 2016-09-29 09:57:38 +08:00
Benau
100c23b3c0 Move TrackSector to WorldWithRank 2016-09-28 13:48:32 +08:00
Benau
3d89d5adc6 Make OverWorld be derived from World 2016-09-28 11:24:04 +08:00
Benau
7867a30276 Allow auto-rescue for ArenaAI if off road for some times 2016-09-28 09:59:33 +08:00
Benau
ff52d91372 Improve SoccerAi front point handling 2016-09-27 16:24:38 +08:00
Benau
e26920e479 Improved skidding when closing to item or kart as target 2016-09-27 15:30:31 +08:00
Benau
3030b679df Clean up ArenaAI 2016-09-27 12:38:36 +08:00
hiker
a58cef4701 Smoothing the speed of a kart (necessary to reduce camera stutter)
results in difficult to reproduce physics. So maintain two speed
values: smoothed (for camera), and 'normal' (for everything else).
2016-09-27 08:42:05 +10:00
Benau
6f67fd6507 Make swatter be able to swat in any direction 2016-09-26 12:46:44 +08:00
Benau
1260f23db0 Try to fix animation
Don't create a new one after the previous one just got deleted
2016-09-26 11:32:19 +08:00
Benau
9be31ba57b Fix build 2016-09-26 10:25:38 +08:00
Benau
2701af315b Try to make checkCrashes work in any direction 2016-09-26 10:09:53 +08:00
hiker
81004adb90 Moved all m_speed handling into a seperate function. 2016-09-26 09:28:28 +10:00
hiker
a6568e01ea Propperly handle instand speed increases in the physics when rewinding. 2016-09-26 09:01:18 +10:00
Benau
3659ad9068 Try to make determineTurnRadius works with any plane 2016-09-26 00:11:49 +08:00
Benau
bff7154e03 Simplify code and fix typo
Because AI always aims quad center now even for 3d quads
2016-09-25 11:22:15 +08:00
Benau
123e667ab4 Simplify code 2016-09-24 10:05:15 +08:00
deve
1a3daafbff Fixed exit on startup when force legacy device is set in graphics restrictions.
It was working on Linux, but on Windows we need to clear system messages when closing irrlicht device.
2016-09-23 10:22:56 +02:00
hiker
74f521980a Fixed time handling to be in synch between history and rewind. 2016-09-23 07:56:21 +10:00
Benau
111fc297d5 Fix overworld crash 2016-09-23 00:15:04 +08:00
hiker
25a457f88f Moved m_speed computation, so that the correct speed was computed
when the engine force (which is speed dependent) is used.
2016-09-22 08:57:37 +10:00
hiker
f0b5f41fc7 Added info message in case of rewinding. 2016-09-21 17:33:37 +10:00
hiker
1651d28a4c In case of history replay update dt earlier so that World is updated
with the replay dt value.
2016-09-21 17:31:24 +10:00
hiker
15660f2d7a Bugfixes: update MaxSpeed(dt=0) (which updates additional engine power
and slowdowns correctly). Call proceedToTransform after updating
the velocities (which are read).
2016-09-21 17:28:26 +10:00
hiker
f09ed569cc Bugfix: kart rewinder stored incorrect bullet zipper speed. 2016-09-21 17:27:08 +10:00
hiker
3ccbeff180 Removed exec permission. 2016-09-21 09:07:06 +10:00
Benau
54bf37c09b Make camera works better in upside down area 2016-09-20 10:51:51 +08:00
Suici Doga
1d75987fe6 Fix typo in main_loop.cpp 2016-09-19 13:54:42 +05:30
Benau
36eca8bc55 Avoid setting gravity in btKart 2016-09-19 11:18:16 +08:00
Benau
8a0a9b2617 Allow showing 3D quad in track debug better 2016-09-19 08:49:59 +08:00
Benau
3187c7e0f9 Allow referee showing on upside down starting position 2016-09-18 13:54:00 +08:00
Benau
ffd497276b Fix kart flying 2016-09-18 12:38:36 +08:00
Benau
b137dbb71c Set gravity inside btKart, allowing starting upside down in arena 2016-09-18 10:53:58 +08:00
Benau
eeac5668d9 Rename QuadGraph to DriveGraph, make it use the new Graph interface 2016-09-17 14:30:28 +08:00
Deve
f2d354d759 Fixed graphics restrictions on android 2016-09-17 03:55:50 +02:00
Deve
852cc068d3 Restore SSAO on linux with GLES renderer. 2016-09-17 03:55:50 +02:00
Deve
21d62ed405 Check availability of color buffer float extension in GLES renderer 2016-09-17 03:55:50 +02:00
Deve
d05cff09c8 Add a graphics restriction for BGRA format on android.
It causes issues with particles transparency.
2016-09-17 03:55:50 +02:00
Benau
606a5401d3 Allow starting position on an upside down surface in arena
Todo: referee and make btKart cast ray at correct normal
2016-09-17 09:53:44 +08:00
Benau
a0005d57e9 Bugfix and better error handling in ArenaGraph 2016-09-16 12:21:38 +08:00
Benau
20e85aa781 Port all function from battle graph to new graph interface 2016-09-16 11:08:19 +08:00
Benau
fff0bab42a Merge remote-tracking branch 'origin/master' into walldriving 2016-09-16 09:23:18 +08:00
Benau
05d2d05f2a Make ArenaAI use only new graph interface 2016-09-16 09:22:57 +08:00
auria.mg
7c2642d427 Workaround crash 2016-09-15 21:12:01 -04:00
Benau
1491236e84 Allow TrackSector to use with new graph class 2016-09-15 15:47:17 +08:00
Benau
05ad91c701 Port all function from battle graph to arena graph
Todo: AI and worlds
2016-09-15 13:29:26 +08:00
Benau
483dca3754 Make EndController to use length() 2016-09-15 12:40:58 +08:00
Benau
8c830bdabf Inital work on one graph interface 2016-09-15 11:46:31 +08:00
Benau
061f187142 Make slipstream work in upside down track 2016-09-13 15:07:07 +08:00
Benau
4574686c1d Make angle computation work in 3D 2016-09-13 12:49:30 +08:00
Benau
3f86722181 Fix skid mark on wall surface 2016-09-13 11:48:36 +08:00
Benau
382905716f Simplify code 2016-09-13 09:26:05 +08:00
hiker
457cb700d2 Make rewind work with history replay (when replaying kart controls),
which allows to have reproducible test cases.
2016-09-13 09:58:42 +10:00
hiker
f8b48a0313 Added zipper speed to state of kart. 2016-09-13 09:55:51 +10:00
Benau
f5d43aaa2e Use btAsin in setHPR
The following quaternion calculated by shortestArcQuat in
rescue animation leads to nan in asinf:

0.710828841, -0.00974362344, -0.703500867, 0.00481829932
-2.0f * (X * Z - Y * W) equals 1.00004351 with above figures

With btAsin it will:
if (x<btScalar(-1)) x=btScalar(-1);
if (x>btScalar(1)) x=btScalar(1);
return asin(x);
2016-09-13 07:43:19 +08:00
Benau
b699018879 Only do custom direction of raycast if item is on quad graph 2016-09-12 13:04:05 +08:00
Benau
7544dc3315 Fix uninitialized value 2016-09-12 11:35:34 +08:00
Benau
cc54c44ec0 Fix rotation of items on upside down surface 2016-09-12 10:43:49 +08:00
Benau
f4861a6279 Fix bubblegum on upside down track 2016-09-12 09:33:05 +08:00
Deve
b0c0af8c46 Check if drivers support BGRA texture format and fallback to RGBA 2016-09-11 22:35:54 +02:00
Benau
f687454313 Fix item positioning on Node3D 2016-09-11 16:31:57 +08:00
Benau
ba047a4f99 Keep flying karts parallel to the ground in the physics, not outside
Like 44da1fb4f2, but takes terrain
into account
2016-09-11 15:35:42 +08:00
Benau
2415340cae Try to fix too bouncy bowling ball 2016-09-11 10:07:43 +08:00
Benau
c37f75bf90 Improve item projection on upside down surface 2016-09-10 16:09:21 +08:00
Benau
b3d5e58dd1 Revert enable sliding for upside down tracks.
Actually !getMaterial()->highTireAdhesion() is always false for
upside down texture, so the below code was useless to test with
normal
2016-09-10 14:32:55 +08:00
Benau
7cfd9752d0 Fix restarting the race when karts are up-side-down 2016-09-10 11:11:52 +08:00
Benau
fde9ccd53e Move updateTerrainInfo to a better location 2016-09-10 11:09:52 +08:00
Deve
fb1c049906 Fixed skybox in GLES renderer 2016-09-10 00:17:47 +02:00
Deve
37f3a8e19e Fixed RTTs formats in GLES renderer.
The problem is that textures with float internal formats can be used in framebuffers only when some extensions are available. This is a basic functionality and we need something that is supported on all drivers. As far as I tested, the basic integer GL_RGBA8 format works fine.

Another problem is with GL_BGRA format. The extension with GL_BGRA support is available for almost every device and irrlicht is able to load all textures from files (it has a fallback mode anyway), but when it's used as a texture for framebuffer, it produces a black screen. Again it works fine with GL_RGBA format.

The only issue that is not fixed is SSAO rendering. It uses linear depth rtt, which has GL_R32F type and which can't be easily changed to something other. I disabled SSAO for now, because it is too slow for embedded devices anyway.

I didn't change anything in original OpenGL 3.x rendering, so everything should work as before.
2016-09-09 23:56:22 +02:00
Deve
278d985632 Disable rtt that is not used in GLES renderer anyway 2016-09-09 22:23:01 +02:00
Benau
ceb92f9b4a Try to completely fix rescue issue 2016-09-10 01:20:11 +08:00
Benau
4f67567834 Fix the up vector 2016-09-09 19:48:11 +08:00
Benau
ca4640716a Fix findOutOfRoadSector with Node3D 2016-09-09 16:30:35 +08:00
Benau
505b50da0c Make getNode return pointer. (easier with dynamic_cast later) 2016-09-09 16:14:28 +08:00
Benau
9d65e2047c Fix heading (which got overwriten by merge) 2016-09-09 12:46:42 +08:00
hiker
876ba33876 Added state saving for skidding. 2016-09-09 13:38:39 +10:00
hiker
e1af0cc353 Fixed various bugs in max speed state saving. 2016-09-09 13:36:49 +10:00
Deve
f2d1eb7117 Use high precision floating point variables if possible.
On desktop medium and high precision is generally the same, at least for mesa drivers. But on some Android devices medium precision is much worse, which causes artifacts. We need high precision float variables in vertex shaders for proper scene rendering. Setting different precision for fragment and vertex shaders seems to be not possible, so we just set it to high for both shader types when it's available.
2016-09-07 22:43:11 +02:00
hiker
3a367ce989 For debugging: instead of specifying the time to go back, specify the
time to go back to.
2016-09-07 08:46:46 +10:00
hiker
6245cea609 Added MaxSpeed to saved state of each kart. 2016-09-07 08:15:09 +10:00
hiker
7d7b98564f Fixed speed smoothing factor (which hopefully fixes the shaking camera). 2016-09-05 17:54:45 +10:00
hiker
77ae30a0c5 Avoid compiler warning. 2016-09-05 09:59:29 +10:00
hiker
1860edca4e Save startup-boost information in state. 2016-09-05 08:14:51 +10:00
hiker
a563266988 Made the KartRewinder to be a kart (which gives it easier access to
some of the kart attributes that need to be saved).
2016-09-05 08:00:21 +10:00
Benau
262eb40dfe Allow showing yellow (2d) / green (3d) quads in track debug 2016-09-04 14:33:23 +08:00
Benau
9d41f4b429 Add assert check for graph.xml 2016-09-04 13:15:51 +08:00
Benau
23a49d5245 Merge remote-tracking branch 'origin/master' into walldriving 2016-09-04 11:56:28 +08:00
Benau
21dc569f70 Start to clean up quad and graph node 2016-09-04 11:56:03 +08:00
Benau
78baaff23e Fix crash in profile mode 2016-09-03 23:03:14 +00:00
hiker
b91ecc9754 Use exponential smoothing for speed, to further reduce stuttering
in speed (and therefore camera).
2016-09-01 15:52:26 +10:00
hiker
f89aaa67f5 Reduce (admittedly very minor) camera jitter by computing the speed
of a kart after it was capped by max speed.
2016-09-01 09:54:09 +10:00
LoadingPleaseWait
3dc13eb071 Fix CPU marker typo 2016-08-31 15:36:15 -05:00
hiker
2a06036fb7 Changed order in which rendering and various updates are done, which
results in the physics reacting one frame earlier to user input.
2016-08-31 16:31:59 +10:00
hiker
ce91d6c2b4 Bugfix (saved incorrect variable). 2016-08-31 16:27:05 +10:00
deve
6c9050f47a Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-08-26 10:36:09 +02:00
deve
5abc047b0c Declare precision also in vertex shaders in GLES renderer.
Some drivers complain that it was declared only in fragment shaders.
2016-08-26 10:35:48 +02:00
Benau
35ce9a39ce Merge branch 'master' into walldriving 2016-08-26 15:36:57 +08:00
auria.mg
061323ffb0 Add information for translators 2016-08-23 20:01:06 -04:00
hiker
e6b2c0f1a0 Fised neniry leak. 2016-08-22 18:08:51 +10:00
hiker
75e1f1c82b Bugfix, wrong variable type. 2016-08-22 18:06:26 +10:00
hiker
8f068c4ff0 Somewhat reduced debug output. 2016-08-22 18:05:14 +10:00
hiker
e62948499f Fixed compiler warning. 2016-08-22 18:04:06 +10:00
Deve
ed5a957a64 Fixed typo in config.xml 2016-08-20 23:39:31 +02:00
Deve
790634a914 Use proper size for RSM framebuffer when scale rtts parameter is set.
It looks that only RSM visualization was affected.
2016-08-20 23:34:12 +02:00
Deve
a4dfbc552f Fixed also minimap in overworld with scale rtts parameter 2016-08-20 22:47:53 +02:00
Deve
150e40e4e8 Break the loop with glClientWaitSync also when GL_CONDITION_SATISFIED is returned.
The GL_CONDITION_SATISFIED says that the sync was signaled before the timeout expired. In this case there is no reason to make another glClientWaitSync execution.
2016-08-20 09:31:29 +02:00
Deve
c7d970b745 Allow to set ForceLegacyDevice in graphics restrictions 2016-08-20 08:13:17 +02:00
Benau
91e11a8d88 Don't crash in overworld 2016-08-20 09:01:52 +08:00
Alpt
67e94e73ce In the addons screen, show a tip to remember that the Internet connection is disabled. (Issue #1763). (#2605) 2016-08-19 18:28:59 -04:00
hiker
e7803fe1ab Don't use intermediate states when replaying (only the original state),
since the states after the original are potentially incorrect (due to
the (later) insertion of an event that triggers the rewind).
Rewinds are now much more different than previously ... wip.
2016-08-19 16:38:49 +10:00
Elderme
41cd1e0364 merged with master 2016-08-18 22:36:19 +02:00
Benau
a1c09c4adb Fix potential crash 2016-08-18 15:34:58 +08:00
Benau
6b0fe9dd89 Clean up:
Try to use forward enum declaration for KartRenderType

NoCopy for RenderInfo
2016-08-18 11:15:05 +08:00
hiker
3d5de1c24c Fixed saving kart control events (they stored the previous value, not
the new value).
2016-08-17 17:54:26 +10:00
Benau
fa39de691e Fix Release build 2016-08-17 12:08:20 +08:00
Benau
f07452842d Add support for colorizing library objects using material.xml only 2016-08-17 11:57:18 +08:00
Michael Murphey
d213bef9db Place buttons in confirm dialog horizontally (#2573)
* Place buttons in confirm dialog horizontally closes #2548

* Use RibbonWidget for MessageDialog

* Use buttonbar for confirm dialog
2016-08-16 19:08:45 -04:00
hiker
adba5c48c8 Fix commented out code to use setter/getter in KartControl. 2016-08-17 08:32:11 +10:00
hiker
e56d324738 Moved the kart control events from the kart control class instead
of the kart rewinder.
2016-08-17 08:08:42 +10:00
Deve
489c34edbf Fixed minimap with scale_rtts_factor parameter 2016-08-16 23:59:36 +02:00
auria.mg
084fa04012 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-08-15 20:33:11 -04:00
auria.mg
63a82c915c Bugfix: prevent activating disabled ribbon items 2016-08-15 20:33:06 -04:00
hiker
7c899c943c Refactored KartControl to use setters/getters instead of
just public variables.
2016-08-15 17:26:07 +10:00
Deve
bd6ad544cc Fixed bloom with scale_rtts_factor parameter. 2016-08-15 08:46:02 +02:00
Deve
d320df749f Allow to set max texture size in config file.
It gives much lower memory usage when it's set for example to 128.
2016-08-12 23:30:10 +02:00
Benau
c5446c4cf1 Remove unused header 2016-08-12 10:41:07 +08:00
Benau
c71b24f98f Correct fixes to #2599 2016-08-12 09:41:08 +08:00
Benau
aa15b0070e Determine the texture size of bold face smartly 2016-08-12 08:31:52 +08:00
hiker
239881ef5e Refactored event handling, so that now not only Rewinder objects
can store events. This allows e.g. a 'new attachment' event to
be handled entirely in the attachment class, not in the kart
rewinder anymore.
2016-08-11 17:16:54 +10:00
Deve
5cfed1bc1c Allow to set lower RTTs resolution.
It allows to increase performance on devices that have only one available resolution.

It also allows to draw GUI elements in full resolution while rendering the scene with slightly lower resolution, which gives you few additional FPS.

Note that particles don't work as expected yet with this feature.
2016-08-11 02:04:35 +02:00
hiker
e621e93f4c Updated comments. 2016-08-10 08:35:23 +10:00
hiker
eaf21fe2f8 Replaced #include in kart.hpp to reduce dependencies; some coding style fixes. 2016-08-10 08:21:37 +10:00
hiker
7c598df8d1 Save powerup state in kart status. 2016-08-09 17:46:06 +10:00
hiker
f4f2f11943 Fix crash in case the same event is replayed more than once. 2016-08-09 17:39:20 +10:00
hiker
a5ce27caa5 Added events for new attachments. 2016-08-09 17:16:45 +10:00
hiker
5f6c954c5a Added documentation. 2016-08-08 18:10:30 +10:00
hiker
5da96cf9d0 Fixed documentation and usage of ATTACHMENT_NOLOKS_SWATTER (which is
never an actual attachment value, even nolok has 'ATTACHMENT_SWATTER'
set).
2016-08-08 17:57:15 +10:00
hiker
f341cd1440 Optimised rewind of attachments (avoid creating new attachments
when the attachment was not changed).
2016-08-08 17:46:52 +10:00
hiker
c01f838b0f Merge remote-tracking branch 'origin/master' into rewind 2016-08-08 14:34:24 +10:00
hiker
b3f932a0e3 Renamed getState to saveState, and added support for saving a kart's
attachmend in a state.
2016-08-08 10:33:12 +10:00
hiker
40697ab5f7 Bugfix for rewind: previously for a floating point value f add(f)
would actually call add(Vec3(f)), which adds a vector (f,f,f).
2016-08-05 17:22:04 +10:00
hiker
e039eb59c9 Added more fields to debug output. 2016-08-05 17:21:17 +10:00
hiker
05db7c1481 Use BareNetworkString for storing states and events. 2016-08-04 23:17:16 +10:00
Elderme
6f78f5b9b9 Fixed GLES 2016-08-04 14:36:35 +02:00
hiker
1025e25846 Refactored RewindInfo into astand-alone class/file with separate
classes for time, event, and states.
2016-08-03 17:48:38 +10:00
Benau
10937333a1 Remove duplicated code in navmesh 2016-08-03 12:37:48 +08:00
hiker
3eb94e023d Fixed error in rewind when only event but no state information
was available at chosen rewind-to time.
2016-08-02 21:24:10 +10:00
hiker
9f0529f26f Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-08-01 08:42:09 +10:00
hiker
a15c9529a5 Merge remote-tracking branch 'origin/master' into rewind 2016-08-01 08:18:38 +10:00
hiker
cdde62dadb Further tweaked restitution for track and bowling ball to avoid
bowling balls jumping up and down, while still maintaining a push
back for soccer balls.
2016-08-01 08:00:14 +10:00
Benau
6904402547 Fix wrong RTL text in arena screen 2016-07-31 09:04:10 +08:00
auria.mg
40ab343922 Fix string remaining in wrong language when changing language 2016-07-30 20:52:32 -04:00
auria.mg
b69faff13d Fix indentation (tabs/spaces) 2016-07-30 19:46:15 -04:00
auria.mg
347f977ea7 Fix english string, as reported a while ago but couldn't fix then due to string freeze 2016-07-30 19:44:21 -04:00
auria.mg
a318e3b216 Log out user when deactivating internet connection, fixes #2589 2016-07-30 19:43:48 -04:00
Elderme
a3c78a7245 Fixed polycount in kart selection screen 2016-07-30 11:31:23 +02:00
Benau
637e468f18 Use uniform copyright header for source 2016-07-29 11:50:37 +08:00
hiker
efe9fa6329 Merge branch 'master' of https://github.com/supertuxkart/stk-code 2016-07-29 09:54:25 +10:00
hiker
8f7d47d3c3 Fix ball-track collision (which should also improve kart-track
collision).
2016-07-29 09:53:37 +10:00