Can a program connect to T3D engine through UDP network?
by Kien T Nguyen · in Torque 3D Professional · 09/09/2012 (10:54 pm) · 5 replies
Hello everyone,
I know that T3D uses UPD protocol for network connection between the server and players.
I want to use a special control device for players instead of keyboard or gamepad.
I will write a program to process the device signals in the functions liked ones which are output by gamepad.
For example the device signals are processed to control players going forward/backward, turning left/right and so on.
Is it possible to make a connection between the device program and T3D engine?
If it is, then how can I do?
Thank you.
I know that T3D uses UPD protocol for network connection between the server and players.
I want to use a special control device for players instead of keyboard or gamepad.
I will write a program to process the device signals in the functions liked ones which are output by gamepad.
For example the device signals are processed to control players going forward/backward, turning left/right and so on.
Is it possible to make a connection between the device program and T3D engine?
If it is, then how can I do?
Thank you.
About the author
#2
09/10/2012 (7:24 am)
You will need to integrate the vendor SDK into Torque to make use of special devices. This has been done with a large number of serious games from helicopter simulations to firing range simulations with real (though modified for a presentation space) weapons. You will need to know the device SDK/API intimately and have a very good handle on input processing in Torque since you will most likely have to modify it significantly to work with the vendor API.
#3
I had bought T3D 1.2 and I know how to work with device.
But I haven't got much experience in input processing in T3D.
I have been digging the T3D but still have had no answer to work with the device.
Could anybody kindly guide me how to solve this problem?
09/10/2012 (8:37 am)
Thank you, David. It is a good news for me. I had bought T3D 1.2 and I know how to work with device.
But I haven't got much experience in input processing in T3D.
I have been digging the T3D but still have had no answer to work with the device.
Could anybody kindly guide me how to solve this problem?
#4
I'm actually talking out my rear - never have tried it myself. But I think the theory is sound....
Wait - sorry, just saw you're working on integrating a controller. David is right, you'll need to add your controller's SDK to T3D, then just script the input. Should not be terribly difficult. There is already code in place for a "controller" device, you could probably modify it to use your new device.
09/10/2012 (9:14 am)
If you only need to use UDP you can probably get it going through a modified TCPObject (need to get it to talk to UDP instead, but most of the core stuff is there). Then create two of those in script - one to send and one to receive - and set your game-side scripts up to handle the interaction.I'm actually talking out my rear - never have tried it myself. But I think the theory is sound....
Wait - sorry, just saw you're working on integrating a controller. David is right, you'll need to add your controller's SDK to T3D, then just script the input. Should not be terribly difficult. There is already code in place for a "controller" device, you could probably modify it to use your new device.
#5
I prefer to write a separate code for device then send controls to T3D.
In your reply, it was unclear to me about "set your game-side scripts up to handle the interaction". Can you explain in more detail?
09/12/2012 (12:43 am)
Thank you, Richard. I prefer to write a separate code for device then send controls to T3D.
In your reply, it was unclear to me about "set your game-side scripts up to handle the interaction". Can you explain in more detail?
Torque Owner Robert Fritzen
Phantom Games Development