public TerrainType(TerrainStaticData data) { gameplayData = data; this.prefabs = new TerrainPrefabs(gameplayData.name); TypeContainer <TerrainType> .add(this.gameplayData.name, this); }
public PropertyType(string assetName, TerrainStaticData data) { gameplayData = data; prefab = loadPrefabByName( assetName ); TypeContainer<PropertyType>.add( gameplayData.name, this ); }
public PropertyType(string assetName, TerrainStaticData data) { gameplayData = data; prefab = loadPrefabByName(assetName); TypeContainer <PropertyType> .add(gameplayData.name, this); }
public TerrainType(TerrainStaticData data, TerrainPrefabs prefabs) { gameplayData = data; if (prefabs == null) { this.prefabs = new TerrainPrefabs(gameplayData.name); } TypeContainer <TerrainType> .add(gameplayData.name, this); }
//Cleanup function for the Texture2D, since Mono's GC won't catch it when TerrainStaticData dies. //TODO: Does this even need to be called? The only time I can imagine it happening is when the app closes, and then the memory will be freed anyway. public static void Destroy(TerrainStaticData gameplayTerrainData) { Texture2D.Destroy(gameplayTerrainData.icon); gameplayTerrainData = null; }
public TerrainType(TerrainStaticData data, TerrainPrefabs prefabs) { gameplayData = data; if (prefabs == null) this.prefabs = new TerrainPrefabs( gameplayData.name ); TypeContainer<TerrainType>.add( gameplayData.name, this ); }
public TerrainType(TerrainStaticData data) { gameplayData = data; this.prefabs = new TerrainPrefabs( gameplayData.name ); TypeContainer<TerrainType>.add( this.gameplayData.name, this ); }
//Cleanup function for the Texture2D, since Mono's GC won't catch it when TerrainStaticData dies. //TODO: Does this even need to be called? The only time I can imagine it happening is when the app closes, and then the memory will be freed anyway. public static void Destroy(TerrainStaticData gameplayTerrainData) { Texture2D.Destroy( gameplayTerrainData.icon ); gameplayTerrainData = null; }