Make ipo animations always enabled. + start of work to have music on the challenge completed screen but doesn't appear to work yet
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@11801 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
8f2c2e396f
commit
8111440317
@ -65,7 +65,7 @@ BillboardAnimation::BillboardAnimation(const XMLNode &xml_node)
|
||||
* \param dt Time since last call. */
|
||||
void BillboardAnimation::update(float dt)
|
||||
{
|
||||
if ( UserConfigParams::m_graphical_effects )
|
||||
//if ( UserConfigParams::m_graphical_effects )
|
||||
{
|
||||
Vec3 xyz(m_node->getPosition());
|
||||
// Rotation doesn't make too much sense for a billboard,
|
||||
|
@ -304,7 +304,7 @@ ThreeDAnimation::~ThreeDAnimation()
|
||||
*/
|
||||
void ThreeDAnimation::update(float dt)
|
||||
{
|
||||
if ( UserConfigParams::m_graphical_effects || m_important_animation )
|
||||
//if ( UserConfigParams::m_graphical_effects || m_important_animation )
|
||||
{
|
||||
Vec3 xyz = m_node->getPosition();
|
||||
Vec3 scale = m_node->getScale();
|
||||
|
@ -266,6 +266,11 @@ namespace GUIEngine
|
||||
*/
|
||||
virtual MusicInformation* getMusic() const { return stk_config->m_title_music; }
|
||||
|
||||
/**
|
||||
* \return which music to play at this screen, if accessed in "in-game-menu" mode
|
||||
*/
|
||||
virtual MusicInformation* getInGameMenuMusic() const { return NULL; }
|
||||
|
||||
virtual int getWidth();
|
||||
|
||||
virtual int getHeight();
|
||||
|
@ -20,6 +20,7 @@
|
||||
|
||||
#include <SColor.h>
|
||||
|
||||
#include "audio/music_manager.hpp"
|
||||
#include "challenges/challenge_data.hpp"
|
||||
#include "challenges/game_slot.hpp"
|
||||
#include "challenges/unlock_manager.hpp"
|
||||
@ -746,3 +747,9 @@ void FeatureUnlockedCutScene::eventCallback(GUIEngine::Widget* widget,
|
||||
} // eventCallback
|
||||
|
||||
// -------------------------------------------------------------------------------------
|
||||
|
||||
MusicInformation* FeatureUnlockedCutScene::getInGameMenuMusic() const
|
||||
{
|
||||
MusicInformation* mi = music_manager->getMusicInformation("race_summary.music");
|
||||
return mi;
|
||||
}
|
@ -167,6 +167,8 @@ public:
|
||||
|
||||
/** override from base class to handle escape press */
|
||||
virtual bool onEscapePressed() OVERRIDE;
|
||||
|
||||
virtual MusicInformation* getInGameMenuMusic() const OVERRIDE;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -217,8 +217,19 @@ void StateManager::onTopMostScreenChanged()
|
||||
{
|
||||
if (m_game_mode == MENU && GUIEngine::getCurrentScreen() != NULL)
|
||||
{
|
||||
music_manager->startMusic(GUIEngine::getCurrentScreen()->getMusic());
|
||||
if (GUIEngine::getCurrentScreen()->getMusic() != NULL)
|
||||
{
|
||||
music_manager->startMusic(GUIEngine::getCurrentScreen()->getMusic());
|
||||
}
|
||||
}
|
||||
else if (m_game_mode == INGAME_MENU && GUIEngine::getCurrentScreen() != NULL)
|
||||
{
|
||||
if (GUIEngine::getCurrentScreen()->getInGameMenuMusic() != NULL)
|
||||
{
|
||||
music_manager->startMusic(GUIEngine::getCurrentScreen()->getInGameMenuMusic());
|
||||
}
|
||||
}
|
||||
|
||||
} // onTopMostScreenChanged
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user