Ejemplo n.º 1
0
 protected override void Start()
 {
     base.Start();
     anim           = GetComponent <Animator> ();
     movement       = FindObjectOfType <ControlMovement>();
     buttonSwitcher = FindObjectOfType <ButtonSwitcher>();
 }
Ejemplo n.º 2
0
 // Use this for initialization
 void Start()
 {
     controlMovement = FindObjectOfType<ControlMovement>();
     buttonSwitcher = FindObjectOfType<ButtonSwitcher>();
     npc = this.transform.GetComponentInParent<NPC>();
     //Debug.Log(npc.name);
     inventroy = FindObjectOfType<Inventory>();
 }
Ejemplo n.º 3
0
 // Use this for initialization
 void Start()
 {
     controlMovement = FindObjectOfType <ControlMovement>();
     buttonSwitcher  = FindObjectOfType <ButtonSwitcher>();
     npc             = this.transform.GetComponentInParent <NPC>();
     //Debug.Log(npc.name);
     inventroy = FindObjectOfType <Inventory>();
 }
Ejemplo n.º 4
0
 private void CheckMouseSwitcher()
 {
     if ((bool)Left.IsChecked)
     {
         MenuButton = ButtonSwitcher.LeftButton;
     }
     if ((bool)LeftRight.IsChecked)
     {
         MenuButton = ButtonSwitcher.LeftRightButton;
     }
     if ((bool)Right.IsChecked)
     {
         MenuButton = ButtonSwitcher.RightButton;
     }
     UpdateText(MenuButton);
 }
Ejemplo n.º 5
0
        private void UpdateText(ButtonSwitcher MenuButton)
        {
            string text = string.Empty;

            switch (MenuButton)
            {
            case ButtonSwitcher.LeftButton:
                text = "Left click here to show a context menu";
                break;

            case ButtonSwitcher.LeftRightButton:
                text = "Left or right click here to show a context menu";
                break;

            case ButtonSwitcher.RightButton:
                text = "Right click here to show a context menu";
                break;
            }
            edit.Clear();
            edit.Document.Blocks.Add(new Paragraph(new Run(text)));
        }