private void Start() { // Get Satellite Stats Component satelliteStats = GetComponent <SatelliteStats>(); captureData = GetComponent <CaptureData>(); // Disable Cooldown Bar cooldownBar.SetActive(false); slider = cooldownBar.GetComponentInChildren <Slider>(); }
private void Start() { data = new MagnetometerData[MAX_DATA]; satelliteStats = GetComponent <SatelliteStats>(); index = 0; capturingData = false; cooldownBar.SetActive(false); slider = cooldownBar.GetComponentInChildren <Slider>(); CaptureDataText.text = "Acquisition de donnees (" + GetIndex().ToString() + "/" + MAX_DATA.ToString() + ")"; //CaptureDataText.color = gr.Evaluate(((float)index + 1) / 15f); }
private void Start() { // Get GameManager satelliteStats = gameManager.GetComponent <SatelliteStats>(); // Initialize ind temporaryValues = new bool[5]; InitializeTempValues(); satelliteStats.commCollision = CanTransmit(); satelliteStats.lightCollision = SolarCharging(); }
private void Start() { satelliteStats = GetComponent <SatelliteStats>(); antennaDeployer = GetComponent <AntennaDeployer>(); payloadDeployer = GetComponent <PayloadDeployer>(); scoreboard = GetComponent <Scoreboard>(); gameOver = false; timeOver = false; gameOverUI.SetActive(false); gameUI.SetActive(true); button.interactable = true; }
private void Start() { deployPayload = false; payloadBroke = false; // Get payload GameObject and the CollisionDetector diamond = payload.transform.GetChild(0).gameObject; collisionDetector = diamond.GetComponent <CollisionDetector>(); satelliteStats = GetComponent <SatelliteStats>(); if (riskPayloadDeployement >= Random.Range(0f, 1f)) { failure = true; endParticule = false; } }
private void Start() { deployAntenna = false; antennaBroke = false; scaleAntenna = false; // Get antennaGroup Parent antennaGroup = antenna.gameObject.GetComponentInParent <Transform>(); // Get SatelliteStats Script satelliteStats = GetComponent <SatelliteStats>(); if (riskAntennaDeployement >= Random.Range(0f, 1f)) { failure = true; } }
public void UpdateScoreAndMoney() { SatelliteStats.IncreaseScore(dataTransmitted * PointsPerDataTransmitted); SatelliteStats.IncreaseMoney(dataTransmitted * PointsPerDataTransmitted); }
void Start() { this.Level = 1f; this.OrbitingSpeed = this.MediumOrbitingSpeed.Value; this.Stats = this.BaseStats; }
protected override void OnUpdate() { InitEntityQueryCache(15); // Gun Entities.ForEach((Satellite satellite, Gun gun, Health health) => { SatelliteStats stats = this.CalculateStats(satellite); gun.ShootFrequency = stats.PrimaryMagnitude; gun.AimSpeed = stats.SecondaryMagnitude; gun.ShootRange = stats.Reach; gun.DetectRange = stats.Reach; health.DamageResistances = stats.DamageResistances; }); // Ram Entities.WithNone <Gun, Laser, Aura>().ForEach((Satellite satellite, Health health) => { SatelliteStats stats = this.CalculateStats(satellite); health.ImpactDamage = new Damage() { Amount = stats.PrimaryMagnitude, Type = DamageType.PHYSICAL }; satellite.transform.localScale = new Vector3(stats.Reach, stats.Reach, stats.Reach); health.DamageResistances = stats.DamageResistances; }); // Laser Entities.ForEach((Satellite satellite, Laser laser, Health health) => { SatelliteStats stats = this.CalculateStats(satellite); laser.BaseTickDamage = new Damage() { Amount = stats.PrimaryMagnitude, Type = DamageType.HEAT }; laser.AddedDamagePerTick = stats.SecondaryMagnitude; laser.Range = stats.Reach; health.DamageResistances = stats.DamageResistances; }); // Chill Entities.ForEach((Satellite satellite, Aura aura, Health health) => { SatelliteStats stats = this.CalculateStats(satellite); List <Effect> newEffects = new List <Effect>(); foreach (Effect effect in aura.EffectsApplied) { if (effect.Type == EffectType.CHILL) { newEffects.Add(new Effect() { Duration = stats.SecondaryMagnitude, Magnitude = stats.PrimaryMagnitude, Stackable = effect.Stackable, Type = effect.Type }); aura.EffectsApplied = newEffects; break; } } aura.Range = stats.Reach; health.DamageResistances = stats.DamageResistances; }); }