Commit Graph

85 Commits

Author SHA1 Message Date
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
Benau
fce3eec66f New GUI for track only screen, used in network and loaded from replay 2016-03-20 16:23:49 +08:00
Benau
96a10ce92c Update strings 2016-02-29 10:59:42 +08:00
Benau
a6412d7a07 Add ghost icon, use it in race setup screen 2016-02-15 09:28:36 +08:00
Benau
b410c8f67c Make soccer menu useful in single player
Notice: As race_manager->setKartSoccerTeam(i, info.team) already
pre-set karts team, there is no need to test for
(getNumKartsInTeam(SOCCER_TEAM_RED) == 0 || getNumKartsInTeam(SOCCER_TEAM_BLUE) == 0),
so the the menu code is simplified.
2016-01-16 16:11:33 +08:00
Benau
d14a39e0f7 Initial work on soccer AI, plus lots of code re-factor/clean up.
To test, you need to update stk-assets with the dummy soccer field.
In single player, you are limited to be in red team for now, so just
shoot the ball into the blue goal. Also max-goal is limited to 4.

Regarding AIs, the steering with ball logic is handled in
SoccerAI::correctBallPosition, max AI supported in single player
is limited to 5 by now.

The AI is not as good as Zidane or Ronaldo, but steering with ball
for human is not as easy as not normal driving anyway, so don't
laugh at the AIs. :)

TODO: Friendly-team firing, polish the soccer field.
2016-01-15 18:25:52 +08:00
hiker
68e37c902f Merge remote-tracking branch 'origin/master' into refactor_networking 2015-12-15 22:52:55 +11:00
hiker
ee7097af35 Added some default settings for race mode and send them to the server.
Changed major and minor mode in protocols from 1-byte to int, since 1-byte
is too small to store the actual values.
2015-12-03 07:53:56 +11:00
Benau
62f5be0d9d First playable version of battle AI
TODO:
backwards firing
better handling to obstacles
ai karts number selection
win/lose screen handling

Please use a better navmesh to test
2015-11-21 15:58:03 +08:00
Benau
f4b723de82 Merge remote-tracking branch 'origin/battleAI' into battleAI 2015-11-15 12:29:01 +08:00
hiker
00e7c35484 Match one more .stkgui and .cpp file name. 2015-10-07 16:37:42 +11:00
MiroslavR
ccf9cee2ff Fix SuperTux difficulty button state not updating correctly 2015-09-18 20:48:18 +02:00
hiker
9b562d31f4 Replaced Widget's set(De)Activated functions with one setActive(bool)
function, which simplifies code for various screen a lot.
2015-07-03 16:19:28 +10:00
hiker
d4f3fc88d6 Merged pull requests #2191. 2015-06-02 14:50:32 +10:00
hiker
8d07d26c25 Updated (c) year to include 2015. 2015-03-30 11:42:50 +11:00
hiker
aa64f31f83 Added Screen::push() function to shorten the calls to pushScreen(). 2014-09-23 16:43:50 +10:00
hiker
2600b17132 Removed unused code and objects. 2014-09-19 14:31:25 +10:00
hiker
c9936ffb97 Forgot to actually add the new files :( 2014-08-25 10:47:36 +10:00
hiker
43593d6312 Made getCurrentUser() a static function. 2014-04-08 08:06:52 +10:00
nixt
c3bd527b8c Merge remote-tracking branch 'upstream/master'
Conflicts:
	data/shaders/ssao.frag
2014-03-06 04:25:17 +05:30
hiker
4d6b110e56 Removed unnecessary #include of user_config.hpp in other hpp files
(to reduce the amount of recompilation when user_config.hpp is changed).
2014-02-26 12:52:16 +11:00
hiker
97be85777d Started to move current player info from unlock manager into
player_manager.
2014-02-09 23:22:45 +11:00
nixt
43f1c59a6e Huge merge from trunk, part 1.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/battleAI@14659 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-12-08 03:45:57 +00:00
hikerstk
bced8cdb9f Merged with trunk, part 1 (due to previous failures I am splitting this
patch).


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/uni@14605 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-12-02 04:27:55 +00:00
deveee
07a3c4f3d5 Minor changes in soccer mode
- scoring points correctly
 - goal text only on the center of screen, not everywhere
 - soccer mode enabled only in multiplayer
 - disable rotating after player confirmation - should look the same as in kart selection
 - restore master-player-only after back to race setup

git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@13680 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-09-14 12:08:22 +00:00
hilnius
ea2b52a663 merging hilnius's branch
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/uni@13394 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-07-31 18:03:11 +00:00
auria
f198e93d0a Bugfix: in some cases, like after tutorial, game would play at wrong difficulty
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@13117 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-07-07 22:52:01 +00:00
auria
16dcb4f38b Lock the highest difficulty until the game was beaten
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12891 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-06-19 23:21:22 +00:00
curaga
b56bf4dc53 Remove trailing space, git doesn't like it
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12797 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-05-29 22:04:35 +00:00
hikerstk
9a9ff77812 iAdded new 'best' AI difficulty. ATM this is not locked yet, and
art work (icon) is still missing. Also we have to find what
to call it (atm 'Iron Man').


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12637 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-04-11 06:17:46 +00:00
hikerstk
aea7a001c5 Bugfix: when playing batle mode, the number of karts is set to the number of players
(independent on the number of AIs selected), and UserConfigParam::m_num_karts is not
changed (which is correct imho).
When then a single race is started, the displayed number of AIs is based on this
m_num_karts. But if a normal race is started (without adjusting the number of
AI karts), the number of karts in the race_manager was not updated (it is only
updated when changing the number of AIs), resulting in the wrong number of karts to
be used (based on the battle mode, and not based on the number shown in the GUI).
This patch just updates the race_manager with the number of AI karts that is shown
in the GUI, so that those values are now in synch.


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12592 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-04-03 11:12:25 +00:00
hikerstk
ec2ca8a2f8 Re-enabled easter egg mode.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12520 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-02-21 05:57:35 +00:00
funto66
07c74c41b5 Merge soccer mode back into trunk - but still WIP, can be disabled via a #define in race_setup_screen.cpp
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12475 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-02-11 22:30:50 +00:00
hikerstk
6dd7bdc4b6 Disabled easter egg mode.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12443 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-02-02 11:32:24 +00:00
hikerstk
845465d60a Fixed #858: driving in overworld would reset number of
AI karts to 0.


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12342 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-01-07 00:44:06 +00:00
funto66
9824370beb Minor cleanup: remove useless ArenasScreen::setUsedForSoccer()
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/christmas@12326 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-01-02 12:16:44 +00:00
funto66
fa7c3cffb3 Soccer mode: WIP GUI state screen for choosing the teams and the number of goals to score in order to win
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/christmas@12318 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2013-01-01 13:58:16 +00:00
funto66
e16c03edf2 Added a special type of tracks for soccer arenas
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/christmas@12300 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2012-12-22 22:33:15 +00:00
funto66
a05e26bf05 Soccer mode - WIP
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/christmas@12296 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2012-12-21 21:04:10 +00:00
hikerstk
29be45b198 Added preliminary easter-egg mode. It still needs a icon (battle mode
used atm), and a better easter egg model (atm bunny from snow mountain,
... whith turns out has lost the black nose). One track has easter eggs
added (math class).


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12281 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2012-12-17 00:33:47 +00:00
hikerstk
7d33125f54 Mostly cosmetic change: renamed RD_EASY etc to
DIFFICULTY_EASY to make it easier to understand;and
removed separate DIFFICULTY_COUNT constant and
replaced it with an entry in the enum (this means
one less change if a difficulty is added). 
Changed layout to be closer to our style in race_manager.hpp.


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11733 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2012-10-21 23:06:33 +00:00
auria
dd487346aa Introduce (in a totally optional way) the C++2011 feature to explicitely mark overrides. This bit us quite a few times in the past, so if we start using this more then those with GCC 4.7 will at least catch the errors when they happen :)
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11231 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2012-05-14 00:04:26 +00:00
auria
0455efd20d Massive refactor in challenge code to allow having more than 1 progression
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10349 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-12-05 22:00:42 +00:00
hikerstk
3185c5fcc9 Cleaned up world.hpp:
- sorted declarations so that all virtual functions
  are together.
- Renamed *_IDENT variables to IDENT_* so that the
  naming is consistent
- Using std::string& for IDENT_* instead of char*
- Use pointer for out variables in getDefaultCollectibles.
- Moved m_fastest_lap variable from world to LinearWorld.
- Many many cosmetic changes to follow our style guide.


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9852 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-09-16 01:49:38 +00:00
auria
c4d06b5c1e Allow accessing 3-stirkes in single-player mode if artist-debug-mode is enabled, that's easier to debug tracks
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9655 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-08-29 01:32:05 +00:00
auria
9fee0c3530 Fixed potential assertion failure in screen setup
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9436 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-08-06 22:50:12 +00:00
auria
4d2b57321b Apply redskull's patch to fix FTL locking. Thanks\!
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9393 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-07-31 00:55:32 +00:00
auria
4157f7dc10 More work on 'thou shalt not include irrlicht.h everywhere carelessly'
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@8665 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-05-22 19:45:17 +00:00
auria
e239a0c8fa Remember number of AI karts
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@8155 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-03-31 23:02:30 +00:00
auria
7377d6739e Add uniform back buttons everywhere in a subtle location
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@8078 178a84e3-b1eb-0310-8ba1-8eac791a3b58
2011-03-26 23:51:49 +00:00