Fixed crash in end camera - hopefully the last problem.
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@5634 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
bc50f128ce
commit
6c7cdb1b7b
@ -399,7 +399,11 @@ void Camera::update(float dt)
|
|||||||
*/
|
*/
|
||||||
void Camera::handleEndCamera(float dt)
|
void Camera::handleEndCamera(float dt)
|
||||||
{
|
{
|
||||||
switch(m_end_cameras[m_current_end_camera].m_type)
|
EndCameraInformation::EndCameraType info
|
||||||
|
= m_end_cameras.size()==0 ? EndCameraInformation::EC_AHEAD_OF_KART
|
||||||
|
: m_end_cameras[m_current_end_camera].m_type;
|
||||||
|
|
||||||
|
switch(info)
|
||||||
{
|
{
|
||||||
case EndCameraInformation::EC_STATIC_FOLLOW_KART:
|
case EndCameraInformation::EC_STATIC_FOLLOW_KART:
|
||||||
{
|
{
|
||||||
|
@ -106,9 +106,9 @@ private:
|
|||||||
EC_AHEAD_OF_KART A camera that flies ahead of the kart
|
EC_AHEAD_OF_KART A camera that flies ahead of the kart
|
||||||
always pointing at the kart.
|
always pointing at the kart.
|
||||||
*/
|
*/
|
||||||
enum {EC_STATIC_FOLLOW_KART,
|
typedef enum {EC_STATIC_FOLLOW_KART,
|
||||||
EC_AHEAD_OF_KART}
|
EC_AHEAD_OF_KART} EndCameraType;
|
||||||
m_type;
|
EndCameraType m_type;
|
||||||
|
|
||||||
/** Position of the end camera. */
|
/** Position of the end camera. */
|
||||||
Vec3 m_position;
|
Vec3 m_position;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user