OpenTTD Dedicated Server Window Name

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Post Reply
Nigma
Engineer
Engineer
Posts: 24
Joined: 14 Apr 2009 10:54
Location: Netherlands
Contact:

OpenTTD Dedicated Server Window Name

Post by Nigma »

Hello again,
Im setting up a few servers and running them with a few macro`s.

Now i want to write a few automessages and that actualy works, but the macro selects the server by WindowName.
And so far both my server run under the same WindowName, is there a way to change these?
Im guessing the -D automaticly designates the window name since a normal (undedicated) game has a different WindowName.

Note: there are propably already programs that can run and manage servers and even do automessages, but i like to do it my own way so i know exactly whats going on.

Thanks.
Advertising successfull - Setting up dedicated server - Building website
dihedral
Tycoon
Tycoon
Posts: 1053
Joined: 14 Feb 2007 17:48

Re: OpenTTD Dedicated Server Window Name

Post by dihedral »

there are, e.g. autopilot, ap+ or the new rewrite avignon (though we are still working on our first beta release :-P)

my guess would be to see if cmd.exe allows you to change the window name ;-) then start that first instead of openttd.exe and from the command line you can run openttd.exe -D ;-)
Nigma
Engineer
Engineer
Posts: 24
Joined: 14 Apr 2009 10:54
Location: Netherlands
Contact:

Re: OpenTTD Dedicated Server Window Name

Post by Nigma »

It seems to work when it comes to changing the window names, but if i run openttd.exe -D it just opens a new window.

I tryed some other things too to see if there might be priority over which windows its picks.
So far i can not get my macro to pick the right window.

Is there any way to change the Windowname?

Maybe a reasonable suggestion for the future? (OpenTTD Dedicated <Servername>)

Id love to post this under Suggestions aswell as Problems (since its a problem for me atm) but that would cause confusion and double posing so i would like to ask people for a solution aswell as feedback on the posibilities of this as a suggestion.
Advertising successfull - Setting up dedicated server - Building website
User avatar
subzero22
Engineer
Engineer
Posts: 50
Joined: 29 Oct 2008 04:29
Contact:

Re: OpenTTD Dedicated Server Window Name

Post by subzero22 »

for some reason I couldn't find any free window title bar changers like I have about a year or so ago. I have no need for them anymore but here's one you might like to try out. Title Bar Changer Studio It's a program to change the title bars or your programs and does a little more.
The Jokemaster

Are developers able to fix the problems?
Of course not. That would be silly. All they can do is stare blankly at the magic that makes the game run, it's not like they're able to read the code or find the errors.
Nigma
Engineer
Engineer
Posts: 24
Joined: 14 Apr 2009 10:54
Location: Netherlands
Contact:

Re: OpenTTD Dedicated Server Window Name

Post by Nigma »

Thanks for the suggestion but i found a way to work around the window name all together,
It seemed obvious there should be something else besides window names else windows cant make a difference either.

So i found the Windows Unique ID that every window gets, Im using that now without trouble.


Still it might be a good idea to allow easyer window title changes since no program i found would allow it.
Advertising successfull - Setting up dedicated server - Building website
omgits3am
Engineer
Engineer
Posts: 14
Joined: 21 Apr 2009 01:59

Re: OpenTTD Dedicated Server Window Name

Post by omgits3am »

Hi, i often play openttd in offline single player mode, but as a curiosity could someone upload a macro or batch file to show how to automatically open the game and start a server and to include the server specs like map size etc etc. Although i cant really imagine having windows boot up everyday with openttd server in the autostart process, but i suppose having a dedicated server that would be the whole point. Perhaps some smart person will write an openttd remote control program?? hint hint ;)
dihedral
Tycoon
Tycoon
Posts: 1053
Joined: 14 Feb 2007 17:48

Re: OpenTTD Dedicated Server Window Name

Post by dihedral »

did you read this thread (/me points at 2nd post) or did you just hit the reply button?
omgits3am
Engineer
Engineer
Posts: 14
Joined: 21 Apr 2009 01:59

Re: OpenTTD Dedicated Server Window Name

Post by omgits3am »

haha! wow, im sorry i must have just woken up... but my question was specifically how to set the server specs when opening the game with the -d option, i assume that autopilot will either do that or allow remotely controling the game.. i probably should examine the 2 programs you mention before posting, but my question is really are there any additional parameters after the -d option to control game specs or loading of a savegame or autosaved server game?
Nigma
Engineer
Engineer
Posts: 24
Joined: 14 Apr 2009 10:54
Location: Netherlands
Contact:

Re: OpenTTD Dedicated Server Window Name

Post by Nigma »

Im not sure if its allowed to display the names but out of honesty to reply ill just say how i run my servers.

I simply use Windows XP Pro (i tried linux but couldnt get handy enough with it)
I got OTTD its own partition so i can clone A LOT of folders.
Then you copy all the cfg files into those folders and start your games using the -c <file location> to load the individual cfg files
Once all the settings are done i close the game and get autohotkey
i basicly told it to upload the server status (some random php file) and the cfg file online.
then start the server.
and should the server go offline to upload the status again only to say its offline.
Advertising successfull - Setting up dedicated server - Building website
Eddi
Tycoon
Tycoon
Posts: 8267
Joined: 17 Jan 2007 00:14

Re: OpenTTD Dedicated Server Window Name

Post by Eddi »

omgits3am wrote:haha! wow, im sorry i must have just woken up... but my question was specifically how to set the server specs when opening the game with the -d option, i assume that autopilot will either do that or allow remotely controling the game.. i probably should examine the 2 programs you mention before posting, but my question is really are there any additional parameters after the -d option to control game specs or loading of a savegame or autosaved server game?
firstly, there is a significant difference between "-d" and "-D", secondly, there is "-h", which will give you an additional list of command line options, the most important of which are probably "-c" and "-g".
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: No registered users and 20 guests