Control Panel won't be repositioned...

Started by barefoot, Tue 24/05/2011 14:25:02

Previous topic - Next topic

barefoot

Hi guys

I am trying to reposition the control panel but it refuses to go lower and the top of it is being blocked by another small gui... is the CP able to be repositioned?

cheers

barefoot
I May Not Be Perfect but I Have A Big Heart ..

Khris

You're changing the position in the editor, right?

At the very top of Global.asc is a function called initialize_control_panel().
There should be this line in there (line 6 in a default game): gPanel.Centre();

Comment it out or remove it.


Now, how did I find this? When I looked at the GUI in the editor, I noticed that its position is set to 0;0 while in the game it's in the middle of the screen. Thus at some point, gPanel is centered. So I looked through the functions in Global.asc and what do you know, there's a function that's all about initializing the control panel. That's what it's called: initialize_control_panel().

Seriously barefoot, when are you going to start figuring things out for yourself?

barefoot

#2
Cheers Khris

I have figured out quite a lot of stuff and configuring it lately.. learning bits here and there...

I have made a button on a gui with access to the control panel and it works, it was just the repositioning and yes, your reply has been implemented and now works as it should  :D

Unfortunately a large cake has to be eaten in more than one bite...  slow but sure...

I want to thank you again for knocking variables into me... especially for your last posts to me..

PS: I'm buying a c book to study... A book's easier for me read with my goggles on..

:=

cheers Khris

barefoot



I May Not Be Perfect but I Have A Big Heart ..

SMF spam blocked by CleanTalk