Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 04-26-2011, 11:55 PM
Devil_Lord2 Devil_Lord2 is offline
David K?
Devil_Lord2's Avatar
Join Date: Apr 2011
Location: PA, MD.
Posts: 643
Devil_Lord2 can only hope to improve
GUI Control canMove not working.

Scripting Level = Beginner "always"
Code isn't the whole script because obviously it isn't finished.

Everything is under onCreated for testing purposes.

So, I'm not too bad at GUI's and ZeroG wanted me to make one for the server. Basically wanted a window with tabs.. now I could have put the tabs on a guiwindowctrl, but then I would have the tab under the bad top window spot.. and the minimize, close, and such buttons...

So, I was thinking I could recreate a 'window' so to speak, with the tabs above it and have it moveable.. technically what I have could work not moveable.. Anyway... let's get to the point.

Main Problem: canMove does not work for the outside container holding the third guicontrol, and tabs.. however the third guicontrol could move with it on... this is odd to me.. I've even tried to move it outside of the tab and third guicontrol clicking in the second's box.

Second GuiControl won't move.

Sub Problem: profile.fillcolor and fillcolor isn't working, not too important.

Anyone know why the second window isn't moving the two things it is containing? Yet the third would? I tried putting canMove on the two as well because I thought they would be holding it down.. but that was a stupid thought. :]

Or, is there a window without the top bar that I could use instead?
I'd love to figure this out, because I'd like to make a GUI tutorial.
I don't find wikia or bible that helpful for many of the tutorials or information... I'd like to make tutorials for new people, not people who know what to do... GUI's I feel semi confident in making a tutorial for.. other scripting I do not.

PHP Code:
findplayer("Devil_Lord2").addweapon(this.name);

//#CLIENTSIDE
function onCreated(){   
    new 
GuiControl("Frontier_MainMenuCtrl"){  //Invisible Controller Box
      
position = {screenheight/2-300screenwidth/2};
      
extent   "600, 600";
      
      new 
GuiControl("Frontier_MainMenu"){    //Invisible Compact Box
        
useownprofile true;
        
fillColor = {25500};
        
position = {55,0};
        
extent   "300, 300";
        
text     "Main Menu";
        
canMove  true;        // This I want to work, but does not.
        
visible  true
        
        new 
GuiControl("Frontier_MainBox"){  //Invisible Box will hold text.
          
profile.fillcolor = {250,250,250,.8};
          
useownprofile true;
          
profile.border 3;
          
position = {1,30};
          
extent   "300, 270";
          
text     "Main Menu";
          
//canMove = true;     // This does work
        
}  
        
        new 
GuiTabCtrl("Frontier_MainTabs"){  //Tabs above the text box.
          
position "1,0";
          
extent   "400,30";
          
tabwidth =  55;
          
          
clearrows();
          
addrow(0,"Help");
          
addrow(1,"Quest");
          
addrow(2,"Credits");
          
setSelectedRow(0);
        }       
      }    
   }

__________________

Digital Media Artist - David K? </3 (UnLoved)
www.davidkrout.com
www.twitch.com/DavidKkz



Reply With Quote
  #2  
Old 04-27-2011, 12:41 AM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
When you click it, Frontier_MainBox receives the click instead of the control under it (Frontier_MainMenu). You can make it "click-throughable" by doing...

PHP Code:
useownprofile true;
profile.modal false
Source:
http://forums.graalonline.com/forums...96&postcount=9
__________________
Quote:
Reply With Quote
  #3  
Old 04-27-2011, 12:46 AM
Mark Sir Link Mark Sir Link is offline
Kevin Azite
Mark Sir Link's Avatar
Join Date: Sep 2005
Posts: 1,489
Mark Sir Link is just really niceMark Sir Link is just really nice
Send a message via AIM to Mark Sir Link
for your other problem, move the fillcolor change to below where you change useownprofile = true;

ex:
PHP Code:
useownprofile true;
profile.fillcolor = {rgba}; 
Reply With Quote
  #4  
Old 04-27-2011, 03:24 AM
Devil_Lord2 Devil_Lord2 is offline
David K?
Devil_Lord2's Avatar
Join Date: Apr 2011
Location: PA, MD.
Posts: 643
Devil_Lord2 can only hope to improve
Unsure what the modal part does, but I tried it, and moved the fillcolor to the bottom.. both did not work D:

I might end up putting everything in a GuiWindowCtrl anyway. >.>
I can't seem to understand why the one GuiControl could move, and the other cannot, besides the point one is the host of two other things.. Evil..

I appreciate both of your help, so far still not working however.
__________________

Digital Media Artist - David K? </3 (UnLoved)
www.davidkrout.com
www.twitch.com/DavidKkz



Reply With Quote
  #5  
Old 04-27-2011, 03:56 AM
Mark Sir Link Mark Sir Link is offline
Kevin Azite
Mark Sir Link's Avatar
Join Date: Sep 2005
Posts: 1,489
Mark Sir Link is just really niceMark Sir Link is just really nice
Send a message via AIM to Mark Sir Link
you may need a border around the GUIControl for it to be moved
Reply With Quote
  #6  
Old 04-27-2011, 04:29 AM
Devil_Lord2 Devil_Lord2 is offline
David K?
Devil_Lord2's Avatar
Join Date: Apr 2011
Location: PA, MD.
Posts: 643
Devil_Lord2 can only hope to improve
:o I will try that again! With the newly added things.

-edit- Nope D: and I put that below useownprofile..

>:O The thing just hates me..
__________________

Digital Media Artist - David K? </3 (UnLoved)
www.davidkrout.com
www.twitch.com/DavidKkz



Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 03:09 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.