Advertisement
Guest User

Untitled

a guest
Nov 12th, 2014
283
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.68 KB | None | 0 0
  1. using UnityEngine;
  2. using System.Collections;
  3.  
  4. public class WeatherController : MonoBehaviour {
  5.    
  6.     public GameObject unistormSystemEditor;
  7.     private UniStormWeatherSystem_C weatherSystem;
  8.    
  9.     // Use this for initialization
  10.     void Start () {
  11.         if (unistormSystemEditor != null) {
  12.             weatherSystem = unistormSystemEditor.GetComponent<UniStormWeatherSystem_C>();                          
  13.         }
  14.         else Debug.Log ("Must attach UnistormSystemEditor object to WeatherControll sript");
  15.     }
  16.    
  17.     // Update is called once per frame
  18.     void Update () {
  19.         if (Input.GetKeyDown(KeyCode.C)) weatherSystem.weatherForecaster = 12;
  20.         if (Input.GetKeyDown(KeyCode.T)) weatherSystem.hourCounter = 3;
  21.     }  
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement