Request About Hosting in T3D
by Depidesign · in Torque 3D Professional · 05/21/2012 (12:15 pm) · 7 replies
Hi GG Fam, I was wondering if anyone came up with a way to automatically host a game. For instance, the typical setup is to click the play button, choose the level you'd like to play and/or modify, click the host check box, then click GO!
What i would like to accomplish is the ability to completely by pass the level selection, and start the game automatically hosting.
What i would like to accomplish is the ability to completely by pass the level selection, and start the game automatically hosting.
About the author
Interactive Media Designer with experience in graphic design, motion graphic design, video editing, web design, and ui design. Applications of Choice: Adobe Creative Suite, Native-Instruments, Cakewalk Sonar,Sony Sound Forge, and FL Studio
#2
05/21/2012 (12:40 pm)
Alternatively, just modify the GUI and load a default mission from a Main Menu button passing the parameter for type of server to be Multiplayer, and a parameter for the level to load.
#3
05/21/2012 (1:47 pm)
I'm sorry but that is exactly what I'm looking for. I know explaining is alot but if you know of a resource that can help, that would be great.
#4
go to main menu
press f10
select play button
in command field paste this:
createAndConnectToLocalServer("MultiPlayer", "levels/Empty Terrain.mis" );
05/21/2012 (2:13 pm)
start gamego to main menu
press f10
select play button
in command field paste this:
createAndConnectToLocalServer("MultiPlayer", "levels/Empty Terrain.mis" );
#5
05/21/2012 (2:29 pm)
Here's a quick and dirty example of putting a "jump straight to the mission and host it" button on the Main Menu:new GuiButtonCtrl() {
text = "HOST DEFAULT MISSION";
groupNum = "-1";
buttonType = "PushButton";
useMouseEvents = "0";
position = "442 604";
extent = "140 30";
minExtent = "8 2";
horizSizing = "right";
vertSizing = "bottom";
profile = "GuiButtonProfile";
visible = "1";
active = "1";
command = "createAndConnectToLocalServer(\"MultiPlayer\", \"levels/Empty Terrain.mis\" );";
tooltipProfile = "GuiToolTipProfile";
hovertime = "1000";
isContainer = "0";
canSave = "1";
canSaveDynamicFields = "0";
};
#6
Take note though, that if you hand-modify the command property in a text editor you'll need to use the escape character before the quote mark on the strings.
05/21/2012 (2:35 pm)
Heh, ahsan beat me to it. Just follow his instructions.Take note though, that if you hand-modify the command property in a text editor you'll need to use the escape character before the quote mark on the strings.
#7
05/21/2012 (4:12 pm)
Wow thanks guys... I'm not a developer. I'm mostly an artist finding my way around.
Associate Michael Hall
Distracted...