Bugfix: if the first end camera was a static_follow_kart,

the position was not set in the first frame, resulting in
an odd 'zoom' effect.


git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@12080 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
hikerstk 2012-11-25 22:59:34 +00:00
parent 604f61d1b4
commit cd8948902a
2 changed files with 16 additions and 8 deletions

View File

@ -227,6 +227,8 @@ void Camera::setMode(Mode mode)
}
if(mode==CM_FINAL)
{
if(m_end_cameras.size()>0)
m_camera->setPosition(m_end_cameras[0].m_position.toIrrVector());
m_next_end_camera = m_end_cameras.size()>1 ? 1 : 0;
m_current_end_camera = 0;
m_camera->setFOV(m_fov);

View File

@ -34,15 +34,18 @@
*/
class GrandPrixData
{
irr::core::stringw m_name; //!< The name of the grand prix
/** The name of the grand prix. */
irr::core::stringw m_name;
/** Internal name of the grand prix, not translated. */
std::string m_id;
/** Original filename, only for error handling needed. */
std::string m_filename;
std::string m_id; //!< Internal name of the grand prix, not translated
std::string m_filename; //!< Original filename, only for error handling needed
/**
* The ident of the tracks in this grand prix in their right order, ident
* means the filename of the .track file without .track extension (ie. 'volcano')
*/
/** The ident of the tracks in this grand prix in their right order, ident
* means the filename of the .track file without .track extension
* (ie. 'volcano'). */
std::vector<std::string> m_tracks;
/** The number of laps that each track should be raced, in the right order */
@ -51,6 +54,9 @@ class GrandPrixData
/** Whether the track in question should be done in reverse mode */
std::vector<bool> m_reversed;
bool m_only_when_nolok_is_unlocked;
public:
/** Load the GrandPrixData from the given filename */