Search Unity

Texture access to game icon

Discussion in 'iOS and tvOS' started by Tomo-Games, Oct 20, 2014.

  1. Tomo-Games

    Tomo-Games

    Joined:
    Sep 20, 2010
    Posts:
    223
    Is there a system call to access the initial game icon as a Texture2D object? Seems silly to do this manually. Like load by Resource folder or get it from a game object, yada.

    Thanks.
     
  2. fffMalzbier

    fffMalzbier

    Joined:
    Jun 14, 2011
    Posts:
    3,276
    If you need the access to the texture , just reference it. There is no call to get the icon at runtime.
    In the editor you probably can access the player-preferences via script.
     
  3. Tomo-Games

    Tomo-Games

    Joined:
    Sep 20, 2010
    Posts:
    223
    If I could just reference it I wouldn't be asking... Otherwise I'll be doing the old GameObject public var grab.
     
  4. fffMalzbier

    fffMalzbier

    Joined:
    Jun 14, 2011
    Posts:
    3,276
    The icon is not included into the unity .assets files that are compiled on build, so you have no way to access it.
    Is is for a specific platform? Maybe you can use a .net call to get the icon on windows or a other native call on ios or Android to retrieve the icon but unity does not provide it.
    Do you like to access it to save some hard disk space of the application or its just a convenient thing, than you could make a editor script or something that is including it for you before the build.