Make ILyShine an AZ::Interface (#6923)
* Move ILyShine instance out of legacy code Signed-off-by: abrmich <abrmich@amazon.com> * Remove last remaining reference of gEnv->pLyShine Signed-off-by: abrmich <abrmich@amazon.com> * Make m_lyShine a unique pointer Signed-off-by: abrmich <abrmich@amazon.com>
This commit is contained in:
@@ -47,7 +47,7 @@ namespace LyShineExamples
|
||||
// Remove the existing example canvas if it exists
|
||||
DestroyCanvas();
|
||||
|
||||
AZ::EntityId canvasEntityId = gEnv->pLyShine->CreateCanvas();
|
||||
AZ::EntityId canvasEntityId = AZ::Interface<ILyShine>::Get()->CreateCanvas();
|
||||
if (!canvasEntityId.IsValid())
|
||||
{
|
||||
return;
|
||||
@@ -90,7 +90,7 @@ namespace LyShineExamples
|
||||
|
||||
m_healthBar.SetInvalid();
|
||||
|
||||
gEnv->pLyShine->ReleaseCanvas(m_canvasId, false);
|
||||
AZ::Interface<ILyShine>::Get()->ReleaseCanvas(m_canvasId, false);
|
||||
m_canvasId.SetInvalid();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user