| Blockland Forums > Modification Help |
| [Tutorial] Making a Gui |
| << < (27/30) > >> |
| Greek2me:
--- Quote from: AGlass0fMilk on August 28, 2010, 01:53:48 PM ---No, instead of guiname.add(newcontrol) do existingparent.add(newcontrol); Existing parent could be any GUI control anywhere --- End quote --- What is the parent though? Is that just the name of the existing GUI? |
| AGlass0fMilk:
--- Quote from: Greek2me on August 29, 2010, 11:27:08 AM ---What is the parent though? Is that just the name of the existing GUI? --- End quote --- The parent is the control, window, or GUI that th new control sticks to. If the control doesn't have a parent (a window), the control just floats around. Parent the new control to the control you want it to be in/on (window, scrollbar, swatch). |
| Greek2me:
Can you tell me what is wrong with this then: --- Code: ---if(!%Added) { JoinServerPassGUI.add( new GuiCheckBoxCtrl() { profile = "GuiCheckBoxProfile"; horizSizing = "right"; vertSizing = "bottom"; position = "71 80"; extent = "140 30"; minExtent = "8 2"; visible = "1"; variable = "vargoeshere"; text = "text"; groupNum = "-1"; buttonType = "ToggleButton"; } ); %Added = 1; } --- End code --- Right now it just floats on its own. |
| Greek2me:
Nevermind, I had to set the window as the object. All good now, thanks everyone. |
| alex dude:
Is it possible to edit default gui's like the wrench events? And if so, Where to put files? |
| Navigation |
| Message Index |
| Next page |
| Previous page |