[Pogamut-list] Retrieving Bot location in UT map context

michal.bida pogamut-forum at diana.ms.mff.cuni.cz
Thu Apr 29 22:54:05 CEST 2010


 Re: Retrieving Bot location in UT map context

Author: michal.bida

Sorry, I've overlooked this thread completely last few days. :-)

FloorNormal is currently exported just for the bot himself and not for other players/bots he sees. To get FloorNormal we need to trace a ray in UnrealEngine that is rather costy operation (roughly around 1 ms for one ray) - it is a question if it worth adding to Player message or not. 

Now, there are two ways how to get to this variable concerning other players and bots. First way is to connect with ObservingConnection and there you get Self message for the player/bot you are observing. Unfortunately observing connection is not supported much at the moment (although it should be possible to use it, but noone has tried yet). :-/

Second way is to launch a ray for yourself with Trace.class command with TraceActors set to false. You would launch this ray from player current location to somewhere beneath him and get TraceResponse class message as a response holding also a normal of the plane the ray hit (it should be floor under the player). The biggest disadvantage of this is the lag you get by issuing a command and waiting for response. But sinse synchronous batch delay is 250ms it could be probably ok.

Best,
michal

-- 
Reply Link: <http://diana.ms.mff.cuni.cz/main/tiki-view_forum_thread.php?forumId=4&comments_reply_threadId=4&comments_parentId=106&post_reply=1#form>





More information about the Pogamut-list mailing list