Guest User

Untitled

a guest
Jan 7th, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. // Update is called once per frame
  2. void Update()
  3. {
  4. if (Input.GetKeyDown(KeyCode.RightArrow))
  5. {
  6. gameObject.SetActive(false);
  7. NextSlide.PreviousSlide = this;
  8. NextSlide.gameObject.SetActive(true);
  9. }
  10. else if (Input.GetKeyDown(KeyCode.LeftArrow) && PreviousSlide != null)
  11. {
  12. gameObject.SetActive(false);
  13. PreviousSlide.gameObject.SetActive(true);
  14. }
  15. }
Add Comment
Please, Sign In to add comment