Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- using System.Collections;
- public class MenuItem : MonoBehaviour
- {
- public void ToggleHighlight(bool on)
- {
- Vector3 pos = transform.position;
- if (on)
- {
- pos.z = -1.0f;
- }
- else
- {
- pos.z = 0.0f;
- }
- transform.position = pos;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement