home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
GameStar 2000 February
/
Gamestar_15_2000-02_cd1.bin
/
Patche
/
BZ2BetaPatch101b.exe
/
addon
/
bzshell_multi_name.cfg
< prev
next >
Wrap
Text File
|
2000-01-01
|
4KB
|
203 lines
// ================
// BATTLEZONE SHELL
// ================
//
// CREATE THE NAME DIALOG
//
CreateControl("GameName", "STATIC")
{
// inherit root STATIC's dimensions
Geometry("PARENTWIDTH", "PARENTHEIGHT");
ColorGroup("BACKGROUND");
Style("MODAL");
CreateControl("Name", "STATIC")
{
ColorGroup("MAGENTA");
Geometry("HCENTRE", "VCENTRE");
Position(0, 5);
Size(200, 140);
BorderSize(10);
BevelSize(5);
TabSize(150, 10);
Style("OUTLINE", "TABROOT");
Title("Game Info");
TitleFont("MEDIUM");
//
// create the name title
//
CreateControl("NameTitle", "STATIC")
{
Geometry("LEFT", "TOP");
Position(-5, 0);
Size(40, 10);
Font("MEDIUM");
Text("Name");
JustifyText("LEFT");
Style("TRANSPARENT");
}
//
// create the name edit box
//
CreateControl("NameEdit", "EDIT")
{
ColorGroup("BLACKBLUE");
Geometry("LEFT", "TOP");
Position(0, 20);
Size(200, 10);
BorderSize(5);
BevelSize(5);
Style("ROLLOVER", "OUTLINE");
Font("SMALL");
UseVar("network.session.namebox");
Cursor("Highlight");
NotifyParent("Edit::Enter", "Okay");
MaxLength(33); // 32 characters + 1 for the end
}
//
// create the password title
//
CreateControl("PasswordTitle", "STATIC")
{
Geometry("LEFT", "TOP");
Position(-5, 40);
Size(80, 10);
Font("MEDIUM");
Text("Password");
JustifyText("LEFT");
Style("TRANSPARENT");
}
//
// create the password edit box
//
CreateControl("PasswordEdit", "EDIT")
{
ColorGroup("BLACKBLUE");
Geometry("LEFT", "TOP");
Position(0, 60);
Size(200, 10);
BorderSize(5);
BevelSize(5);
Style("ROLLOVER", "OUTLINE");
Font("SMALL");
UseVar("network.session.password");
Cursor("Highlight");
NotifyParent("Edit::Enter", "Okay");
MaxLength(21); // 21 characters + 1 for the end
}
//
// create the server message title
//
CreateControl("ServerMsg", "STATIC")
{
Geometry("LEFT", "TOP");
Position(-5, 80);
Size(200, 10);
Font("MEDIUM");
Text("Server Message");
JustifyText("LEFT");
Style("TRANSPARENT");
}
//
// create the server message edit box
//
CreateControl("ServerMsgEdit", "EDIT")
{
ColorGroup("BLACKBLUE");
Geometry("LEFT", "TOP");
Position(0, 100);
Size(200, 10);
BorderSize(5);
BevelSize(5);
Style("ROLLOVER", "OUTLINE");
Font("SMALL");
UseVar("network.session.servermsg");
Cursor("Highlight");
NotifyParent("Edit::Enter", "Okay");
MaxLength(250); // limit to reasonable length
}
//
// create the Launch button
//
CreateControl("Okay", "BUTTON")
{
ColorGroup("BLACKBLUE");
Geometry("RIGHT", "BOTTOM");
Position(-10, -5);
Size(70, 0);
BorderSize(10);
BevelSize(5);
Font("SMALL");
JustifyText("CENTER");
Text("OK");
Style("ROLLOVER", "OUTLINE");
Cursor("Highlight");
NotifyParent("Button::Press", "Okay");
}
//
// create the cancel button
//
CreateControl("Cancel", "BUTTON")
{
ColorGroup("BLACKBLUE");
Geometry("Left", "BOTTOM");
Position(10, -5);
Size(70, 0);
BorderSize(10);
BevelSize(5);
Font("SMALL");
JustifyText("CENTER");
Text("Cancel");
Style("ROLLOVER", "OUTLINE");
Cursor("Highlight");
NotifyParent("Button::Press", "Cancel");
}
OnEvent("Control::Activate")
{
Cmd("network.session.listoff");
}
OnEvent("Control::Deactivate")
{
Cmd("network.session.liston");
}
//
// handle the Okay event
//
OnEvent("Okay")
{
FadeOut("|ShellMultiVehicle");
FadeOut("|GameName");
FadeOut("|ShellMulti");
//FadeOut("|ShellMultJoin");
Cmd("network.session.create");
Cmd("shell.multi.createGame");
// FadeIn("|ShellMultiOption");
FadeIn("|Communications");
}
//
// handle the Cancel event
//
OnEvent("Cancel")
{
FadeOut("|GameName");
FadeIn("|ShellMultiJoin");
Cmd("network.session.autorefreshon");
}
}
}