// Update is called once per frame void Update() { if (Input.GetKeyDown(KeyCode.L)) { likes += 10; setText(likes); } if (Input.GetKeyDown(KeyCode.Space)) { ObjectGeneration.populateCubicles(likes); } if (Input.GetKeyDown(KeyCode.X)) { rawLikes.generateLikeTokens(likes); } timer += 1; if (timer > 500) { timer = 0; setText(likes); } if (likes < 0) { likes = 0; } if (posts < 0) { posts = 0; } }
void Start() { ObjectGeneration = gameObject.GetComponent <objectDictionary> (); timer = 0; likes = 0; posts = 0; setText(likes); ObjectGeneration.populateCubicles(likes); }