public void SaveNullShouldNotTryAddToDatabase() { //Arrange WeatherMain expecWeatherMain = new WeatherMain() { Humidity = 0, Pressure = 0, Temperature = 0, TemperatureMin = 0, TemperatureMax = 0, }; Wind expectedWind = new Wind() { Direction = 0, Speed = 0 }; PredictionDate expectedPredictionDate = new PredictionDate() { Time = DateTime.Now, }; Clouds expectedClouds = new Clouds() { All = 0 }; Forecast expectedForecast = new Forecast() { Clouds = expectedClouds, WeatherMain = expecWeatherMain, Wind = expectedWind, Time = expectedPredictionDate, CityId = 0 }; ForecastEntity expectedEntity = new ForecastEntity() { WeatherMain = expecWeatherMain, Wind = expectedWind, PredictionDate = expectedPredictionDate, Clouds = expectedClouds, CityServiceId = 0, Forecast = expectedForecast }; var weatherContextMock = new Mock <WeatherDataContext>(); weatherContextMock.Setup(x => x.Forecast.Add(It.IsAny <Forecast>())).Returns((Forecast f) => f); weatherContextMock.Setup(x => x.City.Add(It.IsAny <City>())).Returns((City f) => f); weatherContextMock.Setup(x => x.Clouds.Add(It.IsAny <Clouds>())).Returns((Clouds f) => f); weatherContextMock.Setup(x => x.PredictionDate.Add(It.IsAny <PredictionDate>())).Returns((PredictionDate f) => f); weatherContextMock.Setup(x => x.WeatherMain.Add(It.IsAny <WeatherMain>())).Returns((WeatherMain f) => f); weatherContextMock.Setup(x => x.Wind.Add(It.IsAny <Wind>())).Returns((Wind f) => f); WeatherManager weather = new WeatherManager(weatherContextMock.Object); //Act var savedEntities = weather.SaveForecastEntity(expectedEntity).Result; //Assert Assert.Equal(1, savedEntities); weatherContextMock.Verify(x => x.SaveChangesAsync(), Times.Never); }
public override void Draw(GameTime gameTime) { var batch = gameRef.spriteBatch; batch.Begin(SpriteSortMode.Deferred, BlendState.AlphaBlend, SamplerState.PointClamp, DepthStencilState.Default, RasterizerState.CullNone); { batch.Draw(backgroundImage, new Rectangle(0, 0, Game1.GAME_WIDTH, Game1.GAME_HEIGHT), Color.White); powerUpMgr.Draw(batch); players.ForEach((p) => { p.Draw(batch, gameTime); }); batch.Draw(backgroundoverlay, Vector2.Zero, WeatherManager.BgColor); WeatherManager.Draw(batch, gameTime); EffectManager.Draw(batch, gameTime); FadeOutRect.Draw(batch, Vector2.Zero, FadeOutColor); } batch.End(); batch.Begin(SpriteSortMode.Deferred, BlendState.Additive); { WeatherManager.Bolts.ForEach(b => b.Draw(batch)); } batch.End(); }
public LocationsPage() { this.InitializeComponent(); this.NavigationCacheMode = NavigationCacheMode.Required; Application.Current.Resuming += LocationsPage_Resuming; wm = WeatherManager.GetInstance(); GPSPanelViewModel = new ObservableCollection <LocationPanelViewModel>() { null }; LocationPanels = new ObservableCollection <LocationPanelViewModel>(); LocationPanels.CollectionChanged += LocationPanels_CollectionChanged; LocationQuerys = new ObservableCollection <LocationQueryViewModel>(); int max = Enum.GetValues(typeof(WeatherUtils.ErrorStatus)).Cast <int>().Max(); ErrorCounter = new bool[max]; // CommandBar CommandBarLabel = App.ResLoader.GetString("Nav_Locations/Text"); PrimaryCommands = new List <ICommandBarElement>() { new AppBarButton() { Icon = new SymbolIcon(Symbol.Edit), Label = App.ResLoader.GetString("Label_Edit"), } }; EditButton = PrimaryCommands.First() as AppBarButton; EditButton.Click += AppBarButton_Click; }
public IEnumerator WeatherFinder() { print("Preparing..."); GameObject manager = GameObject.Find("WeatherManager"); myWeather = manager.GetComponent <WeatherManager>(); weatherC = manager.GetComponent <WeatherControl>(); //myWeather.cityName = CitySearch; //myWeather.GetJsonData(); yield return(StartCoroutine(GetCityData())); weatherC.spawnWeatherEmote(myWeather.weather); GameObject.Find("WeatherText(TMP)").GetComponent <TextMeshPro>().text = myWeather.weather; GameObject.Find("CityText(TMP)").GetComponent <TextMeshPro>().text = myWeather.location; print(myWeather.location); print(myWeather.weather); print(myWeather.geoLat); print(myWeather.geoLon); print(myWeather.geoLocation); print("WEATHER FOUND!"); }
// Start is called before the first frame update void Start() { dfUnity = GameObject.Find("DaggerfallUnity").GetComponent <DaggerfallUnity>(); weatherManager = GameObject.Find("WeatherManager").GetComponent <WeatherManager>(); my_StartTime = Random.Range(1045, 1100); my_EndTime = Random.Range(330, 360); }
void Awake() { Weather = GetComponent <WeatherManager>(); _startSequence = new List <IGameManager>(); _startSequence.Add(Weather); StartCoroutine(StartupManagers()); }
protected override void ActivationBehaviour() { if (weatherManager == null) { weatherManager = FindObjectOfType <WeatherManager>(); } }
private void Awake() { if (weatherManager == null) { weatherManager = FindObjectOfType <WeatherManager>(); } }
public override bool CheckTrigger(Task caller) { WeatherManager WeatherManager = GameManager.Instance.WeatherManager; switch (weather) { case WeatherType.Sunny: return(!WeatherManager.IsRaining && !WeatherManager.IsOvercast && !WeatherManager.IsStorming && !WeatherManager.IsSnowing && WeatherManager.currentOutdoorFogSettings.density == WeatherManager.SunnyFogSettings.density); case WeatherType.Cloudy: return(false); // TODO: weather not implemented in the weather manager case WeatherType.Overcast: return(WeatherManager.IsOvercast && WeatherManager.currentOutdoorFogSettings.density != WeatherManager.HeavyFogSettings.density && !WeatherManager.IsRaining && !WeatherManager.IsStorming && !WeatherManager.IsSnowing); case WeatherType.Fog: return(WeatherManager.IsOvercast && WeatherManager.currentOutdoorFogSettings.density == WeatherManager.HeavyFogSettings.density && !WeatherManager.IsStorming && !WeatherManager.IsSnowing); case WeatherType.Rain: return(WeatherManager.IsRaining && !WeatherManager.IsStorming && !WeatherManager.IsSnowing); case WeatherType.Thunder: return(WeatherManager.IsStorming && !WeatherManager.IsSnowing); case WeatherType.Snow: return(WeatherManager.IsSnowing); default: throw new Exception("Weather: unexpected weather type"); } }
/// <summary> /// Draw map npc obj magic etc. /// </summary> /// <param name="gameTime">Provides a snapshot of timing values.</param> private void DrawGamePlay(GameTime gameTime) { if (Globals.IsWaterEffectEnabled) { WaterEffectBegin(); } //Map npcs objs magic sprite MapBase.Instance.Draw(_spriteBatch); //Player Globals.ThePlayer.Draw(_spriteBatch); //Weather WeatherManager.Draw(_spriteBatch); //Super magic if (Globals.IsInSuperMagicMode) { Globals.SuperModeMagicSprite.Draw(_spriteBatch); } if (Globals.IsWaterEffectEnabled) { WaterEffectEnd(gameTime); } //Fade in, fade out if (ScriptExecuter.IsInFadeIn || ScriptExecuter.IsInFadeOut) { ScriptExecuter.DrawFade(_spriteBatch); } }
private static ushort CalculateSelfHeight(WeatherManager wm, int x, int z) { int num; //Terrain min int num1; //Terrain avg int num2; //Terrain max int num3; //Tree number of item's hit float single; //tree min float single1; //tree avg float single2; //tree max float single3 = ((float)x - 64f) * 135f; float single4 = ((float)z - 64f) * 135f; float single5 = ((float)(x + 1) - 64f) * 135f; float single6 = ((float)(z + 1) - 64f) * 135f; Singleton <TerrainManager> .instance.CalculateAreaHeight(single3, single4, single5, single6, out num, out num1, out num2); //new - ignore tree data. if (OptionsWrapper <Configuration> .Options.UseNoWindEffects) //My Additions to overide tree effects. { return((ushort)Mathf.Clamp(num1 + num2 >> 1, 0, 65535)); } //end new Singleton <TreeManager> .instance.CalculateAreaHeight(single3, single4, single5, single6, out num3, out single, out single1, out single2); int num4 = Mathf.RoundToInt(single1 * 64f); //treeavg height int num5 = Mathf.RoundToInt(single2 * 64f); //treemax height int num6 = num1 + (num4 - num1) * Mathf.Min(num3, 100) / 100; // note: num6 translated = TerrMin + (newTreeAvg -Terrainmin ) * Min(TreeHits,100) /100 int num7 = Mathf.Max(num2, num5); // note: num7 translated = max of (TerrainMaxheight or TreeMaxHeight) //org return((ushort)Mathf.Clamp(num6 + num7 >> 1, 0, 65535)); }
public static void Load(Microsoft.Xna.Framework.Content.ContentManager p_loader) { JKContentManager.Particles._jump_particle = p_loader.Load <Texture2D>("particles/jump_particle"); JKContentManager.Particles.JumpParticleSprites = JKContentManager.Util.SpriteChopUtilGrid(JKContentManager.Particles._jump_particle, new Point(JKContentManager.Particles._jump_particle.Width / JKContentManager.Particles._jump_particle.Height, 1), new Vector2(0.5f, 1f)); Texture2D texture2D = p_loader.Load <Texture2D>("particles/jump_particle_water"); JKContentManager.Particles.JumpParticleSpritesWater = JKContentManager.Util.SpriteChopUtilGrid(texture2D, new Point(texture2D.Width / texture2D.Height, 1), new Vector2(0.5f, 1f)); Texture2D texture2D2 = p_loader.Load <Texture2D>("particles/water_splash"); JKContentManager.Particles.WaterSplashSprites = JKContentManager.Util.SpriteChopUtilGrid(texture2D2, new Point(texture2D2.Width / texture2D2.Height, 1), new Vector2(0.5f, 0.5f)); JKContentManager.Particles.SnowSettings = XmlSerializerHelper.Deserialize <SnowParticleEntity.SnowSettings>("Content/mods/particles/snow_settings.xml"); JKContentManager.Particles._snow_particle = p_loader.Load <Texture2D>("particles/snow_jump_particle"); Rectangle rectangle = new Rectangle(0, 0, 144, 108); for (int i = 0; i < JKContentManager.Particles._snow_particle.Height / rectangle.Height; i++) { rectangle.Y = rectangle.Height * i; JKContentManager.Particles.SnowSprites.Add(i, JKContentManager.Util.SpriteChopUtilGrid(JKContentManager.Particles._snow_particle, new Point(4, 3), new Vector2(0.5f, 1f), rectangle)); } WeatherManager.WeatherEffect weatherEffect = XmlSerializerHelper.Deserialize <WeatherManager.WeatherEffect>(p_loader.RootDirectory + "/mods/particles/weather.xml"); foreach (WeatherManager.Weather weather in weatherEffect.weathers) { JKContentManager.Particles.WeatherSprites.Add(weather.name, JKExtensions.UltraContent.LoadContentArr <Texture2D>(p_loader, "particles/" + weather.name)); } WeatherManager.Load(weatherEffect); }
// Use this for initialization private void Start() { _mazeGenerator = GetComponent <MazeGenerator>(); _player = GameObject.FindWithTag("player"); _weatherManager = GameObject.Find("WeatherStation").GetComponent <WeatherManager>(); Init(); }
private void InitializeData() { DateTime fiveDaysLater = new DateTime(); DateTime now = new DateTime(); now = fiveDaysLater = DateTime.Now; fiveDaysLater = fiveDaysLater.AddDays(5); WeatherManager weatherManager = new WeatherManager(new WeatherDataContext()); CityManager cityManager = new CityManager(new WeatherDataContext()); var cities = cityManager.GetObservedCities(); Dictionary <string, List <ForecastEntity> > entities = new Dictionary <string, List <ForecastEntity> >(); foreach (var city in cities) { entities.Add(city.Name, weatherManager.GetForecasts(city, now, fiveDaysLater)); } var labels = new List <string>(); MinTemperatures = new ChartValues <double>(); MaxTemperatures = new ChartValues <double>(); foreach (var entity in entities) { MinTemperatures.Add(entity.Value.Min(x => x.WeatherMain.TemperatureMin)); MaxTemperatures.Add(entity.Value.Max(x => x.WeatherMain.TemperatureMax)); labels.Add(entity.Key); } Cities = labels.ToArray(); }
public static void Postfix(WeatherManager __instance, ref DataStore __state) { if (IgnoreHelper.IsIgnored() || MultiplayerManager.Instance.CurrentRole == MultiplayerRole.Client) { return; } // don't send command if target values have not been changed if (!__state.HasChanged(__instance)) { return; } Command.SendToAll(new WeatherCommand { CurrentCloud = __instance.m_currentCloud, TargetCloud = __instance.m_targetCloud, CurrentFog = __instance.m_currentFog, TargetFog = __instance.m_targetFog, CurrentNothernLights = __instance.m_currentNorthernLights, TargetNothernLights = __instance.m_targetNorthernLights, CurrentRain = __instance.m_currentRain, TargetRain = __instance.m_targetRain, CurrentRainbow = __instance.m_currentRainbow, TargetRainbow = __instance.m_targetRainbow, CurrentTemperature = __instance.m_currentTemperature, TargetTemperature = __instance.m_targetTemperature, }); }
void Awake() { timeController = transform.GetComponent <TimeController>(); notifierController = GameObject.Find("UI/Notifier").GetComponent <NotifierController>(); weatherManager = GameObject.Find("WeatherManager").GetComponent <WeatherManager>(); watsonManager = GetComponent <WatsonManager>(); }
private void Update() { if (_Player == null) { _Player = ComponentManager <Player> .Value; } if (_Network_Player == null) { _Network_Player = ComponentManager <Network_Player> .Value; } if (_AzureSkyController == null) { _AzureSkyController = UnityEngine.Object.FindObjectOfType <AzureSkyController>(); } if (_WeatherManager == null) { _WeatherManager = UnityEngine.Object.FindObjectOfType <WeatherManager>(); } if (_Raft == null) { _Raft = ComponentManager <Raft> .Value; } if (Cheat.fixTimeScale) { Time.timeScale = 0f; } else { if (!visible) { Time.timeScale = 1f; } } if (UnityEngine.Input.GetKeyDown(KeyCode.F3)) { ModAPI.Log.Write("Flying"); Cheat.FlyMode = !Cheat.FlyMode; } // if clicked button if (UnityEngine.Input.GetKeyDown(KeyCode.F1)) { ModAPI.Log.Write("Menü"); if (visible) { // menu is closed _Player.SetMouseLookScripts(true); Helper.SetCursorVisibleAndLockState(false, CursorLockMode.Locked); Time.timeScale = 1f; } else { // menu is open _Player.SetMouseLookScripts(false); Helper.SetCursorVisibleAndLockState(true, CursorLockMode.None); Time.timeScale = 0f; } visible = !visible; } }
// Use this for initialization void Start() { citizenManager = FindObjectOfType <CitizenManager>(); if (citizenManager == null) { Debug.Log("No Citizen Manager was Found"); } energyManager = FindObjectOfType <EnergyManager>(); if (energyManager == null) { Debug.Log("No Energy Manager was Found"); } polutionManager = FindObjectOfType <PolutionManager>(); if (polutionManager == null) { Debug.Log("No Polution Manager was Found"); } weatherManager = FindObjectOfType <WeatherManager>(); if (weatherManager == null) { Debug.Log("No Weather Manager was Found"); } uIManager = FindObjectOfType <UIManager>(); }
private void initMap() { if (map != parent.Map) { if (map != null && lastFaction != null) { unseeSeenCells(lastFaction, lastFactionShownCells); } if (!disabled && mapCompSeenFog != null) { mapCompSeenFog.fowWatchers.Remove(this); } map = parent.Map; mapCompSeenFog = map.getMapComponentSeenFog(); thingGrid = map.thingGrid; glowGrid = map.glowGrid; roofGrid = map.roofGrid; weatherManager = map.weatherManager; lastFactionShownCells = mapCompSeenFog.getFactionShownCells(parent.Faction); if (!disabled) { mapCompSeenFog.fowWatchers.Add(this); } mapSizeX = map.Size.x; mapSizeZ = map.Size.z; } }
/// <summary> /// Script startup function /// </summary> public void StartScript() { API.consoleOutput("####Script started!####"); WeatherManager weatherManager = new WeatherManager(); API.onVehicleDeath += VehicleManager.Instance().VehicleDestroyedEvent; API.onPlayerEnterVehicle += VehicleManager.Instance().VehicleEnterEvent; API.onPlayerExitVehicle += VehicleManager.Instance().VehicleExitEvent; //API.onPlayerConnected += PlayerManager.Instance().HandlePlayerConnect; API.onPlayerDisconnected += PlayerManager.Instance().HandlePlayerDisconnect; API.onPlayerFinishedDownload += PlayerManager.Instance().HandlePlayerConnect; PlayerManager.Instance().InitAccountCreationId(); PlayerManager.Instance().InitTextMessagesId(); PlayerManager.Instance().InitCharacterCreationId(); PlayerManager.Instance().InitCharacterSelectorModels(); PlayerManager.Instance().InitPhoneNumbers(); PlayerManager.Instance().InitCharacterGenders(); VehicleManager.Instance().LoadVehiclesFromDB(); HouseManager.Instance().LoadHouseTemplates(); JobManager.Instance().InitJobPickupPoints(); ItemManager.Instance().InitializeItems(); MapManager.Instance().Initialize(); JobManager.Instance().Initialize(); FactionManager.Instance().InitializeFactions(); API.consoleOutput("####Script load complete!####"); }
public static void Postfix(WeatherManager __instance, Map map) { if (map.weatherManager.curWeather.defName == "LotRW_HealingRainWD") { if (Find.TickManager.TicksGame % 10 == 0) { Pawn pawn = map.mapPawns.AllPawnsSpawned.RandomElement(); if (!pawn.Position.Roofed(map)) { IEnumerable <Hediff_Injury> injuries = pawn.health.hediffSet.GetHediffs <Hediff_Injury>(); if (injuries != null && injuries.Count() > 0) { Hediff_Injury injury = injuries.RandomElement(); if (injury.CanHealNaturally() && !injury.IsPermanent()) { injury.Heal(Rand.Range(.2f, 2f)); if (Rand.Chance(.5f)) { EffectMaker.MakeEffect(ThingDef.Named("Mote_HealingWaves"), pawn.DrawPos, map, Rand.Range(.4f, .6f), 180, 1f, 0); } else { EffectMaker.MakeEffect(ThingDef.Named("Mote_HealingWaves"), pawn.DrawPos, map, Rand.Range(.4f, .6f), 180, 1f, 0, 180, .1f, .02f, .19f, false); } } } } } } }
private void Awake() { instance = this; myAudioSource = GetComponent <AudioSource>(); soilHumidity = 0.5f; rainParticleSystem.SetActive(false); }
public FireMonitor() { _weatherManager = Singleton <WeatherManager> .instance; _buildingManager = Singleton <BuildingManager> .instance; _guideManager = Singleton <GuideManager> .instance; _simulationManager = Singleton <SimulationManager> .instance; }
// Use this for initialization void Start() { //instantiate clouds targetCol = normalCol; ticker = timer; wm = (WeatherManager)GameObject.Find ("WeatherManager").GetComponent<WeatherManager>(); }
public static async Task PostAlerts(LocationData location, List <WeatherAlert> alerts) { var wm = WeatherManager.GetInstance(); // Post weather alert notifications if (wm.SupportsAlerts && alerts != null && alerts.Count > 0) { // Only alert if we're in the background if (App.IsInBackground) { // Check if any of these alerts have been posted before // or are past the expiration date var unotifiedAlerts = alerts.Where(alert => alert.Notified == false && alert.ExpiresDate > DateTimeOffset.Now); // Post any un-notified alerts Helpers.WeatherAlertCreator.CreateAlerts(location, unotifiedAlerts.ToList()); // Update all alerts alerts.ForEach(alert => alert.Notified = true); // Save alert data await Settings.SaveWeatherAlerts(location, alerts); } } }
public override void OnCreate() { base.OnCreate(); mContext = ApplicationContext; wm = WeatherManager.GetInstance(); if (complicationIds == null) { complicationIds = new List <int>(); } var oldHandler = Java.Lang.Thread.DefaultUncaughtExceptionHandler; Java.Lang.Thread.DefaultUncaughtExceptionHandler = new UncaughtExceptionHandler((thread, throwable) => { Logger.WriteLine(LoggerLevel.Error, throwable, "SimpleWeather: {0}: UncaughtException", TAG); if (oldHandler != null) { oldHandler.UncaughtException(thread, throwable); } else { Java.Lang.JavaSystem.Exit(2); } }); }
/// <summary> /// Start up the state /// </summary> /// <param name="_mgr">State manager for this state</param> /// <returns></returns> public override bool Startup(StateManager _mgr) { // store reference to the state manager StateMgr = _mgr; // get reference to the ogre manager OgreManager engine = StateMgr.Engine; //Instantiate everything WeatherMgr = new WeatherManager(); CityManager.SetGameMgr(this); //Initialize everythings createScene(engine); createUI(); createCommands(); //Initialize the City Manager (that's everything right?) CityManager.Init(0, 0); CompositorManager.Singleton.AddCompositor(engine.Window.GetViewport(0), "Bloom"); CompositorManager.Singleton.AddCompositor(engine.Window.GetViewport(0), "Radial Blur"); // OK return(true); }
public SettingsPage() { this.InitializeComponent(); wm = WeatherManager.GetInstance(); RestoreSettings(); }
private async void KeyEntry_Tapped(object sender, Windows.UI.Xaml.Input.TappedRoutedEventArgs e) { var keydialog = new Controls.KeyEntryDialog(APIComboBox.SelectedValue.ToString()); keydialog.PrimaryButtonClick += async(ContentDialog dialog, ContentDialogButtonClickEventArgs args) => { var diag = dialog as Controls.KeyEntryDialog; string key = diag.Key; string API = APIComboBox.SelectedValue.ToString(); if (await WeatherManager.IsKeyValid(key, API)) { KeyEntry.Text = Settings.API_KEY = key; Settings.API = API; wm.UpdateAPI(); RequestAppTrigger = true; Settings.KeyVerified = true; UpdateKeyBorder(); AlertSwitch.IsEnabled = wm.SupportsAlerts; diag.CanClose = true; diag.Hide(); } else { diag.CanClose = false; } }; await keydialog.ShowAsync(); }
private void Awake() { if (WeatherManager.instance == null) { WeatherManager.instance = this; } }
public async Task ChangeCity(CityInfo newCity) { mainPageFrame.Visibility = Visibility.Collapsed; TileManager.UpdateTile(); progressRing.IsActive = true; Model.SelectedCity = newCity; Weather_Displayed weather = null; try { weather = await WeatherManager.GetWeather(newCity); } catch (Exception ex) { WeatherManager.ShowConnectFailDialog(ex); return; } finally { progressRing.IsActive = false; mainPageFrame.Visibility = Visibility.Visible; } var tuple = new Tuple <Weather_Displayed, MainPage>(weather, this); mainPageFrame.Navigate(typeof(WeatherPage), tuple); }
// Use this for initialization void Start() { current = this.GetComponent<AudioSource> (); wm = this.GetComponent<WeatherManager> (); weath = wm.getWeather (); setSong (weath); current.Play (); }
private void Awake() { Weather = GetComponent<WeatherManager>(); var tempImageManager = GetComponent<ImagesManager>(); _startSequence = new List<IGameManager>(); _startSequence.Add(Weather); _startSequence.Add(tempImageManager); StartCoroutine(StartupManagers()); }
void Start () { player = GameObject.FindGameObjectWithTag("Player"); tree_manager = gameObject.GetComponent<TreeManager>(); chunkGen = gameObject.GetComponent<ChunkGenerator>(); weather_manager = gameObject.GetComponent<WeatherManager>(); shrine_manager = gameObject.GetComponent<ShrineManager>(); chunkGen.chunk_size = chunk_size; chunkGen.chunk_resolution = chunk_resolution; cur_chunk = new Vector2(-1, -1); loaded_chunks = new List<Vector2>(); loaded_tree_chunks = new List<Vector2>(); loaded_shrine_chunks = new List<Vector2>(); }
// Use this for initialization void Start() { day = 1; weatherManager = GameObject.Find("WeatherManager").GetComponent<WeatherManager>(); }
// Use this for initialization void Start() { m_resourceManager = GameObject.FindGameObjectWithTag("ResourceManager").GetComponent<resourceManager>(); weatherManager = GameObject.Find("WeatherManager").GetComponent<WeatherManager>(); for(int i=0; i<MAXFRAMELEVEL; i++) { Debug.Log("At frame level " + i + " a frame upgrade costs " + getFrameUpgradeCost(i).toString()); } for(int frameLevel = 1; frameLevel < MAXFRAMELEVEL; frameLevel++) { for(int materialLevel = 1; materialLevel < MAXMATERIALLEVEL; materialLevel++) { Debug.Log("At frame level " + frameLevel + " and material level " + materialLevel + " a material upgrade costs " + getMaterialUpgradeCost(frameLevel, materialLevel).toString()); } } }
// Use this for initialization void Start() { weatherManager = GameObject.Find("WeatherManager").GetComponent<WeatherManager>(); textMesh = GetComponent<TextMesh>(); }