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
1 registered members (TipmyPip), 15,499 guests, and 5 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
Show and hide panel on key click #250105
02/05/09 22:50
02/05/09 22:50
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline OP
Member
Darkyyes  Offline OP
Member
D

Joined: Jun 2007
Posts: 152
Norway
Show and hide panel on key click
how to make a toogle function to show and hide a panel on lets say the key k,

//main inventory
PANEL* test_panel =
{
bmap = test_panel;
layer = 0;
flags = SHOW;
}


New to lite-c and gamestudio in general, thank you for reading.
Com, A7 v7.7
Re: Show and hide panel on key click [Re: Darkyyes] #250107
02/05/09 22:54
02/05/09 22:54
Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
Quad Offline
Senior Expert
Quad  Offline
Senior Expert

Joined: Oct 2007
Posts: 5,211
İstanbul, Turkey
Code:
function toogle_the_panel(){
  toggle(test_panel,SHOW);
}


or

Code:
function toogle_the_panel(){
  if(is(test_panel,SHOW))
  {
     reset(test_panel,SHOW);
  }
  else{
     set(test_panel,SHOW); 
  }
}


and in your main fucniton before the while:

on_k = toggle_the_panel;

OR

in your main while

if(key_k) toggle_the_panel();


3333333333
Re: Show and hide panel on key click [Re: Quad] #250111
02/05/09 23:20
02/05/09 23:20
Joined: Jun 2007
Posts: 152
Norway
D
Darkyyes Offline OP
Member
Darkyyes  Offline OP
Member
D

Joined: Jun 2007
Posts: 152
Norway
Thank you very much smile


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

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

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