void Launch() { if (Input.GetKey(KeyCode.Space) && energyTotal > 0 && isActive) { rigidBody.AddRelativeForce(Vector3.up * flySpeed * Time.deltaTime); GetEnergy(); jetParticle.Play(); EnergyCollected?.Invoke(energyTotal); SoundManager.Instance.PlaySound(SoundManager.Instance.flySound); } else { jetParticle.Stop(); } }
protected async Task ApplyRevealedPresenceTracks(SelfCtx ctx) { // Energy Energy += EnergyPerTurn; EnergyCollected?.Invoke(this); // ! Elements were added when the round started. // Do actions AFTER energy and elements have been added - in case playing ManyMindsMoveAsOne - Pay 2 for power card. foreach (ITrackActionFactory action in Presence.RevealedActions) { if (action.RunAfterGrowthResult) { await action.ActivateAsync(ctx); } } }