Game Development Community

Manipulating values from outside the engine

by David De Bels · in Torque Game Engine · 02/03/2009 (10:20 am) · 2 replies

Hi there,

for a project I need to manipulate some values from outside the engine through use of an external program, such as a player's speed and direction.
My thought would be to use an I/O file or so and make the game read values from it and use a different external program to change the values in that file at the same framerate as the Torque game.
But that's not really all that efficient.

Is there a better way to do this in TGE?

Thanks in advance.

#1
02/03/2009 (3:13 pm)
one of the easiest methods to do that would be to use a TCPObject in game, get it to listen on a specific port and then you can send in commands for the game to process.

We use that approach and it works very nicely indeed I can even tell the game server to restart itself :)
#2
02/04/2009 (12:58 am)
Thanks, that sounds like the kind of thing I'm looking for.
I'll give it a try.