Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- using System.Collections;
- public class NoteTrigger : MonoBehaviour {
- public Texture2D img;
- // Use this for initialization
- void Start () {
- }
- // Update is called once per frame
- void Update () {
- }
- public Texture2D noteImage
- {
- get { return img; }
- }
- void OnGUI()
- {
- if (Input.GetMouseButton(0))
- {
- float width = 600;
- float height = 600;
- GUI.DrawTexture(new Rect((Screen.width / 2) - (width / 2), (Screen.height / 2) - (height / 2), width, height), img);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement