270 {
271 super.SetActive(active);
273 EntityAI item_in_hands = player.GetHumanInventory().GetEntityInHands();
274
275 if( item_in_hands )
276 {
277 if( m_MainWidget.FindAnyWidget( "Cursor" ) )
278 {
279 m_MainWidget.FindAnyWidget( "Cursor" ).Show( active );
280 }
281
282 if( active )
283 {
285 GetMainWidget().GetScreenPos(
x,
y );
286 PrepareOwnedTooltip( item_in_hands, -1,
y );
287 }
288 }
289 else
290 {
291 if (active)
292 m_MainWidget.FindAnyWidget( "hands_preview_root" ).SetAlpha( 0.85 );
293 else
294 m_MainWidget.FindAnyWidget( "hands_preview_root" ).SetAlpha( 0.7 );
295 }
296 }
proto native CGame GetGame()