Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
3 registered members (TipmyPip, AndrewAMD, NewbieZorro), 16,655 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Hide many panels with one key #252181
02/16/09 23:08
02/16/09 23:08
Joined: Jun 2008
Posts: 21
M-V, Germany
V
vargur Offline OP
Newbie
vargur  Offline OP
Newbie
V

Joined: Jun 2008
Posts: 21
M-V, Germany
Hi i have many panels each contained in a single wdl-file is it possible to assign one key to all of this panels to show or hide them? If it is possible how do I do that

Re: Hide many panels with one key [Re: vargur] #252184
02/16/09 23:22
02/16/09 23:22
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline
Member
Darkyyes  Offline
Member
D

Joined: Jun 2007
Posts: 152
Norway
make a toggle function for each of them
then in your player script or main.wdl
on_i = toggle_nameoftogglefunction;

or if you mean hide all the panels on one key
just put every panel in one toggle function
on_i = toggle_nameoftogglefunction;

lite-c example
Code:
function toggle_panel()
{
      if is ("insert name of panel here", VISIBLE)
      {
      reset("insert name of panel here", VISIBLE);
      }
      else
      {
      set("insert name of panel here", VISIBLE);
      }
}

without quotation marks


just add more lines with reset and set like this

Code:
function toggle_panel()
{
      if is ("insertnameofpanelhere", VISIBLE)
      {
      reset("insertnameofpanelhere", VISIBLE);
      reset("insertnameofpanelhere", VISIBLE);
      reset("insertnameofpanelhere", VISIBLE);
      reset("insertnameofpanelhere", VISIBLE);
      }
      else
      {
      set("insertnameofpanelhere", VISIBLE);
      set("insertnameofpanelhere", VISIBLE);
      set("insertnameofpanelhere", VISIBLE);
      set("insertnameofpanelhere", VISIBLE);
      }
}


dont know if this example will work directly with wdl/c-script
perhaps some function is named differtly but the basic idea is there wink
also the hide multiple panel example i gave will only check if one of the panel is showing, but it would not matter in that case and easily changeable wink
I dont know c-script in anyway frown


New to lite-c and gamestudio in general, thank you for reading.
Com, A7 v7.7
Re: Hide many panels with one key [Re: Darkyyes] #252185
02/16/09 23:28
02/16/09 23:28
Joined: Jun 2008
Posts: 21
M-V, Germany
V
vargur Offline OP
Newbie
vargur  Offline OP
Newbie
V

Joined: Jun 2008
Posts: 21
M-V, Germany
Wow this was a very fast reply I am impressed. Thank you very much I will try it that way

Re: Hide many panels with one key [Re: vargur] #252187
02/16/09 23:38
02/16/09 23:38
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline
Member
Darkyyes  Offline
Member
D

Joined: Jun 2007
Posts: 152
Norway
I try staying on when I am at home smile
hope it works that or we might find a way wink


New to lite-c and gamestudio in general, thank you for reading.
Com, A7 v7.7
Re: Hide many panels with one key [Re: Darkyyes] #252188
02/16/09 23:50
02/16/09 23:50
Joined: Jun 2008
Posts: 21
M-V, Germany
V
vargur Offline OP
Newbie
vargur  Offline OP
Newbie
V

Joined: Jun 2008
Posts: 21
M-V, Germany
tried it this way

function toggle_pan()
{
while(key_v == on)
{
wait(1);
}
"insert name of panel here".visible = ("insert name of panel here".visible == off);
"insert name of panel here".visible = ("insert name of panel here".visible == off);
"insert name of panel here".visible = ("insert name of panel here".visible == off);
"insert name of panel here".visible = ("insert name of panel here".visible == off);
}

}
on_v = toggle_pan;


and it works just perfect thank u so much

Re: Hide many panels with one key [Re: vargur] #252189
02/16/09 23:51
02/16/09 23:51
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline
Member
Darkyyes  Offline
Member
D

Joined: Jun 2007
Posts: 152
Norway
your welcome. smile trying to learn gamestudio myself. smile and I have found looking at filled examples really helps me atleast. smile
Be sure to ask on the forum, look in the aum, look at other topics. some topics may not look like its what you look for but sometimes it is. smile This community has helped me a ton. smile
Glad I could be of help. smile


New to lite-c and gamestudio in general, thank you for reading.
Com, A7 v7.7
Re: Hide many panels with one key [Re: Darkyyes] #252191
02/16/09 23:58
02/16/09 23:58
Joined: Jun 2008
Posts: 21
M-V, Germany
V
vargur Offline OP
Newbie
vargur  Offline OP
Newbie
V

Joined: Jun 2008
Posts: 21
M-V, Germany
I sent you a pm with a further question maybe if u don't mind u could help me with that too

Re: Hide many panels with one key [Re: vargur] #252194
02/17/09 00:07
02/17/09 00:07
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline
Member
Darkyyes  Offline
Member
D

Joined: Jun 2007
Posts: 152
Norway
Sure. I will take a look.


New to lite-c and gamestudio in general, thank you for reading.
Com, A7 v7.7

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1