Game Development Community

RayCasting to Identify an Object in remote

by TigerHeros · in Torque 3D Professional · 08/10/2010 (10:42 am) · 3 replies


Hi all


I am working in client with Remote Dedicated Server. When the User clicked the Object I want to

display the Object Name.

I know the raycasting method to identify the Object Name in local client and server.

could any one help me how can i raycasting and identify the Object Name in remote server?


#1
08/10/2010 (11:46 am)
commandToServer, pass the cam pos and forward vector and let the server do the ray cast, and return the object's name,

Or you could try and do the cast locally, and try to resolve the ghosted ID of the object through the NetConnection object, check the documentation on how to do this. (woot, there is documentation!)
#2
08/10/2010 (12:19 pm)
You need a small source code change to do the raycast directly in the client, though, since the containerRayCast() function only tests server-side objects.
#3
08/12/2010 (6:01 am)
@manoel Netro and Tim Thank You for your reply.

How can i get the ghost id of the Object through the Net Connection Object?

Could You Help me?