I am in the process of making a newspaper-looking GUI for my upcoming event-based CRPG, and while making it, Blockland crashed. When I restarted Blockland, either in correlation with or not, my saved "NewspaperGui" was not in the menu for GUI select. I have the "NewspaperGui.Gui" saved in the base/client/ui/ folder, is this where it should be to load in the GUI select menu of the GUI maker? If so, where? If not, then what did I do wrong?
This would be my first serious GUI I have/am making, so I don't know much about the process of saving them and the correct place I should put them.
Answer: Everytime you work on your GUI, you have to execute it by typing
exec("base/client/ui/NewspaperGui.gui"); into the console, unless it is in an addon.
Second question.
I have made a test gui to see what I need to enter to keybind the gui and such.
File directory: Add-Ons/Client_CRPG/
In that folder, I have "NewspaperGui.gui", "Client.cs", "description.txt", and "Newspaper.png"
//NewspaperGui.gui
//--- OBJECT WRITE BEGIN ---
new GuiControl(Newspaper) {
profile = "GuiDefaultProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "0 0";
extent = "1024 768";
minExtent = "8 2";
enabled = "1";
visible = "1";
clipToParent = "1";
new GuiWindowCtrl() {
profile = "GuiWindowProfile";
horizSizing = "center";
vertSizing = "bottom";
position = "307 121";
extent = "410 432";
minExtent = "8 2";
enabled = "1";
visible = "1";
clipToParent = "1";
maxLength = "255";
resizeWidth = "1";
resizeHeight = "1";
canMove = "0";
canClose = "1";
canMinimize = "0";
canMaximize = "0";
minSize = "50 50";
closeCommand = "canvas.popDialog(NewspaperGui.gui);";
new GuiBitmapCtrl() {
profile = "GuiDefaultProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "5 27";
extent = "400 400";
minExtent = "8 2";
enabled = "1";
visible = "1";
clipToParent = "1";
bitmap = "./Newspaper";
wrap = "0";
lockAspectRatio = "0";
alignLeft = "0";
alignTop = "0";
overflowImage = "0";
keepCached = "0";
mColor = "255 255 255 255";
mMultiply = "0";
new GuiScrollCtrl(Text1) {
profile = "GuiScrollProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "13 193";
extent = "177 95";
minExtent = "8 2";
enabled = "1";
visible = "1";
clipToParent = "1";
willFirstRespond = "0";
hScrollBar = "alwaysOff";
vScrollBar = "alwaysOff";
constantThumbHeight = "0";
childMargin = "0 0";
rowHeight = "40";
columnWidth = "30";
};
new GuiScrollCtrl(Text2) {
profile = "GuiScrollProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "209 193";
extent = "177 95";
minExtent = "8 2";
enabled = "1";
visible = "1";
clipToParent = "1";
willFirstRespond = "0";
hScrollBar = "alwaysOff";
vScrollBar = "alwaysOff";
constantThumbHeight = "0";
childMargin = "0 0";
rowHeight = "40";
columnWidth = "30";
};
};
};
};
//--- OBJECT WRITE END ---
function Open_NewspaperGui.gui(%toggle)
{
if(%toggle)
{
if(NewspaperGui.gui.isAwake())
{
canvas.popDialog(NewspaperGui.gui);
}
else
{
canvas.pushDialog(NewspaperGui.gui);
}
}
}
//Client.cs
exec("./NewspaperGui.gui");
$remapDivision[$remapCount] = "Blocky999";
$remapName[$remapCount] = "NewspaperGui.gui";
$remapCmd[$remapCount] = "Open_NewspaperGui.gui";
$remapCount++;
//description.txt
Title: CRPG GUIs
Author: Blocky999
Guis for my CRPG
I'm following
this as a tutorial.
I started up Blockland, keybound it to "Alt R", started a game, pressed the keybind, nothing happened. I entered the console and nothing was displayed. What am I doing wrong?