-
Notifications
You must be signed in to change notification settings - Fork 2
Convert World To Screen Coordinates
Pavle edited this page Feb 15, 2021
·
2 revisions
static ZLevelManager* levelManager = reinterpret_cast<ZLevelManager*>(Globals::g_pLevelManagerSingleton);
if (!levelManager)
{
return;
}
ZHitman5* player = levelManager->m_rHitman.m_pInterfaceRef;
if (!player)
{
return;
}
static ZUserFeedbackManager userFeedbackManager;
userFeedbackManager.m_pHitman = levelManager->m_rHitman;
float4 playerWorldPosition = {};
player->GetSpatialEntityPtr()->GetWorldPosition(&playerWorldPosition);
SVector3 screenCoordinates;
bool reject;
userFeedbackManager.ConvToScreenSpace(&screenCoordinates, &playerWorldPosition, 0, 0, &reject);