In this case, I want to create a commandlet that can decode a save file that has been encoded in-engine. Currently I have to boot-up the game and run a command. It would be nice to just run a single shortcut and do this with a commandlett script. There are lots of other things I’d like to automate too.
I don’t find it hard to believe that the engine simply cannot run without a map loaded. Even if all you want to show is a menu, you still need to load a map, and there’s all that engine relevant stuff that’s in Worldinfo which is tied to a map isn’t it?
I’d just try using the smallest map possible that works for what you need the commandlet to do.
I’m working on setting one up to start our game with, beings you can only put in 256 characters into the target line. Hopefully i can add more thru the commandlet. I got the class to compile but it is not reconizing my map and its starting a listen server not a dedicated server. I’m having problems with it also. When i get it running properly, i will let you know what i did.
What we are doing at this moment is this. We took and made a shortcut from our exe to the desktop then in that shortcut i put into the target line this.
C:\UDK\UDK-2014-02\Binaries\Win32\FOPB.exe server warehouse2?dedicated=true?GameDifficulty=7?TimeOfDay=5?Weather=1?AdminPassword=ss?Game=Paintball.PBRescuePresident?MaxPlayers=16?NUMPLAY=2? –silent LOG=DEDPaintballLog.txt -ConsolePosX=0 -ConsolePosY=0
Then all i have to do is click that shortcut and it will start a dedicated server.
But what i hate is the target line will only accept 256 characters. So it limits you on what you can put into the target line. I was hoping to make a commandlet to start the dedicated server with. I was hoping to run way more parameters then you can put into the target line. But way its looking this might not work for what i was thinking.
@gamepainters The way I have it configured is that all dedicated server settings are in a custom ini file i created (DefaultDedServerSettings.ini). Then on init game, I apply them, without relying on purely launch params.
In your above example, you can access the query url part of the launch command from unrealscript, but not the other launch params (such as -ConsolePosX, or any of those), as far as i know. I would like to be able to access the entire launch string.
I have not been around for last few days. We run the servercommandlet then in the parameters we tell it which kind of server we are going to run. Only way i can think of to get more parameters added is to use a .bat file as Neongho posted above. then you can have as many parameters as you want.
like this in the login function in gameinfo class. Examples below
InPassword = ParseOption ( Options, "Password" );//admin pass
InTeam = GetIntOption( Options, "Team", 255 ); // default to "no team"
Also in the init function in whatever you call your gametypes class that extends gameinfo or in the gametype init function, i think i would gather most in the gametypes base file.
These were in our Base gametypes file.
Also in the base gametype file that extends gameinfo theres a function called
function ProcessServerTravel(string URL, optional bool bAbsolute)
in that you must get your parameters also to send when traveling to next map.