Some converts of usage of Shapebase for Gamebase to make camera/control object swapping easier.

This commit is contained in:
Areloch 2016-05-30 03:13:19 -05:00
parent 74a2005d15
commit 553cf260f1
2 changed files with 2 additions and 2 deletions

View file

@ -117,7 +117,7 @@ void GuiCrossHairHud::onRender(Point2I offset, const RectI &updateRect)
GameConnection* conn = GameConnection::getConnectionToServer();
if (!conn)
return;
ShapeBase* control = dynamic_cast<ShapeBase*>(conn->getControlObject());
GameBase* control = dynamic_cast<GameBase*>(conn->getCameraObject());
if (!control || !(control->getTypeMask() & ObjectMask) || !conn->isFirstPerson())
return;

View file

@ -339,7 +339,7 @@ bool GameProcessCameraQuery(CameraQuery *query)
if (connection && connection->getControlCameraTransform(0.032f, &query->cameraMatrix))
{
query->object = dynamic_cast<ShapeBase*>(connection->getControlObject());
query->object = dynamic_cast<GameBase*>(connection->getCameraObject());
query->nearPlane = gClientSceneGraph->getNearClip();
// Scale the normal visible distance by the performance