private async Task CreateAndWaitUntilCompleted() { await CreateAddressablesLoader.InitAsset(_label, Assets); await CreateAddressablesLoader.InitAsset(_assetName, Assets); await Task.Delay(2000); ClearAsset(Assets[0]); }
private async Task CreateAndWaitUntilCompleted() { await CreateAddressablesLoader.InitAsset(_label, Assets); foreach (var asset in Assets) { //OBJS LOADED PERFORM ADDITIONAL ACTIONS Debug.Log(asset.name); return; } }
public async Task LoadObjectSprites() { ObjectSprites = await CreateAddressablesLoader.CreateAsset <AllObjects>(OBJECT_SPRITES); Object = await CreateAddressablesLoader.CreateAsset <GameObject>(OBJECT_NAME); GameObject gameObject = await CreateAddressablesLoader.CreateGameObject(NEXT_ROUND_PARTICLE); NextRoundParticle = gameObject.GetComponentInChildren <ParticleSystem>(); NextRoundParticle.Stop(); }
private async Task CreateAndWaitUntilComplete() { await CreateAddressablesLoader.InitByNameOrLabel(_label, Assets); foreach (var asset in Assets) { //Asset is now fully loaded Debug.Log("Loaded asset: " + asset.name); } Task.Delay(TimeSpan.FromSeconds(5)); CleanUpFinishedAssets(Assets[0]); }
public async Task <HorizontalView> CreateHorizontalView(Transform parent) { GameObject gameObject = await CreateAddressablesLoader.CreateGameObject(HORIZONTAL_VIEW_NAME, parent); return(gameObject.GetComponent <HorizontalView>()); }
public async Task <GameObject> CreatePlayStateView() { return(await CreateAddressablesLoader.CreateGameObject(PLAY_STATE_VIEW_NAME));; }
public async Task <RoundView> CreateRoundView(Transform parent) { GameObject gameObject = await CreateAddressablesLoader.CreateGameObject(ROUND_VIEW_NAME, parent); return(gameObject.GetComponent <RoundView>()); }
public async Task <GameOverView> CreateGameOverView(Transform parent) { GameObject gameObject = await CreateAddressablesLoader.CreateGameObject(GAME_OVER_VIEW_NAME, parent); return(gameObject.GetComponent <GameOverView>()); }
public async Task <DestinationObjectView> CreateDestinationObjectView(Transform parent) { GameObject gameObject = await CreateAddressablesLoader.CreateGameObject(DESTINATION_VIEW_NAME, parent); return(gameObject.GetComponent <DestinationObjectView>()); }