Hello Guest

Author Topic: Window Script  (Read 91 times)

ironquark

  • Newbie
  • *
  • Posts: 14
    • View Profile
Window Script
« on: October 28, 2017, 09:17:13 PM »
Hi

I'm using Window script from 2dtoolkit,

How to hide/show the window with all objects?

I need to know the class name of window script, to hide and show the window on a button.

See image:
https://imgur.com/2omAyIG
https://imgur.com/ZnKzLuH


Thanks
« Last Edit: October 28, 2017, 09:40:03 PM by ironquark »

ironquark

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Window Script
« Reply #1 on: October 29, 2017, 11:58:04 AM »
With this line:

   Button1 = GameObject.Find("ToggleButton1").GetComponent<tk2dUIToggleButton>();

I can acess the button with the class tk2dUIToggleButton, what is the name of the class for the Window?

ironquark

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Window Script
« Reply #2 on: October 29, 2017, 12:10:56 PM »
With this:

      mywindow = GameObject.Find ("Window").GetComponent<tk2dUILayout>();

I'm able to acess the component window, my question is, How to hide/show the window?

ironquark

  • Newbie
  • *
  • Posts: 14
    • View Profile
Re: Window Script
« Reply #3 on: November 01, 2017, 01:06:07 PM »
For a while I'm using this solution:

GameObject.Find ("Window").SetActive(false);

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9646
    • View Profile
Re: Window Script
« Reply #4 on: November 11, 2017, 10:09:50 PM »
Hi,
Did you try that thing I suggested in the email?