[Q]ROTATETO not working for me. Malformed outgoing messages?

3 views
Skip to first unread message

metageoff

unread,
May 16, 2010, 1:27:42 PM5/16/10
to unrealdecoy
In response to this message:

SEENPLAYER|UTPlayerController_0|Player|255|UTWeap_RocketLauncher_0|
0,-200847,0|-115.29,-325.28,-80.85|0.00,0.00,0.00|True

I see the enemy id is "UTPlayerController_0" and the location_vector
is "-115.29,-325.28,-80.85"

I thought I could do either of the following to rotate my bot towards
the enemy:

ROTATETO|UTPlayerController_0|Target

ROTATETO|-115.29,-325.28,-80.85|Location

but the bot does not rotate in either case. Am I formatting the
message wrong? I'm stumped.

Geoff

PS. FIRE|None|False also does nothing.

metageoff

unread,
May 16, 2010, 2:50:58 PM5/16/10
to unrealdecoy
I figured maybe I goofed and my outgoing traffic was only being logged
and not sent.

Not so. Follows is a snippet of network traffic sniffed using ngrep:

T 192.168.1.113:4530 -> 192.168.1.128:61589 [AP]
SEENPLAYER|UTPlayerController_0|Player|255|UTWeap_Enforcer_0|
0,25835,0|-169.69,260.14,-79.00|322.33,-252.74,0.00|True|EOM.

##
T 192.168.1.128:61589 -> 192.168.1.113:4530 [AP]
ROTATETO|-169.69,260.14,-79.00|Location
FIRE|UTPlayerController_0|False
RUNTO|0.0|0.0|-169.69,260.14,-79.00

Compare to similar snippet when running testbot.py

T 192.168.1.113:4530 -> 192.168.1.128:61589 [AP]
SEENPLAYER|UTPlayerController_0|Player|255|UTWeap_Enforcer_0|
0,25835,0|-169.69,260.14,-79.00|322.33,-252.74,0.00|True|EOM.

##
T 192.168.1.128:61589 -> 192.168.1.113:4530 [AP]
ROTATETO|-169.69,260.14,-79.00|Location
FIRE|UTPlayerController_0|False
RUNTO|0.0|0.0|-169.69,260.14,-79.00

metageoff

unread,
May 16, 2010, 2:58:13 PM5/16/10
to unrealdecoy
should mention that the trace snippet for testbot.py was a successful
one. It did rotate, fire and run. Mine does not.

Geoff

Will

unread,
May 18, 2010, 9:51:31 AM5/18/10
to unrealdecoy
We've had some trouble with the ROTATETO message. In fact I'm pretty
sure it doest work. (broken mutator code)

Try using the ROTATEBY message, it takes a radian amount to rotate by.
It seems to be the only one we've had any luck with.

Geoff Longman

unread,
May 18, 2010, 11:31:11 AM5/18/10
to unrea...@googlegroups.com
understood. But the only message I've sent that the server has recognized is the INIT.

FIRE,
RUNTO,
JUMP,


are all not working for me.

Geoff

PS. ROTATETO works for the testbot.py btw.

warf

unread,
May 18, 2010, 12:19:43 PM5/18/10
to unrealdecoy
ROTATETO works, but I believe it takes the pawn class name as the
second parameter (usually this looks like "DummyBot_XX"). It's also
possible that the mutator doesn't correctly create a pawn for actual
player characters, I haven't tested this part extensively.

As for getting your messages recognized by the server, I'm not sure if
you're using the .NET library (I've heard there's a javascript bot
lurking out there somewhere ;) ), but you'll need to be mindful of how
your chosen technology deals socket I/O at a low level. The two
biggest problems I had building a PHP bot were:

1) Some socket implementations in PHP (and also C) will transparently
buffer data until it feels like transmitting it over the wire, usually
in bulk. Presumably it does this for efficiency. So looking at the
outgoing packets, there would be no traffic for a few seconds... then
suddenly a few KB of queued messages would gusher forth at once, and
the server would largely ignore them. So flushing the socket somehow
after each message EOM is imperative.

2) With 1) solved, at least one of the socket implementations in PHP
that I tried was simply *too fast* for the server. The network traffic
looked normal, but until I introduced an artificial delay in the
message code between outgoing messages, the server would seem to react
randomly to some messages, and not to others. The delay that worked
best for me in PHP was 30-50ms between outgoing messages -- then
everything started getting picked up on the server side.

-Warf

Geoff Longman

unread,
May 18, 2010, 1:25:52 PM5/18/10
to unrea...@googlegroups.com
Cool. Thanks for the insight. testbot.py has no problem fighting real
players so I'll investigate the buffering and or timing issues.
Awesome. Geoff

Sent from my iPod

Will Harding

unread,
May 18, 2010, 2:45:33 PM5/18/10
to unrea...@googlegroups.com

Did you get the python test bot from somewhere other than my bitbucket account?

I'm asking because I never put a ROTATETO message into the code. 

On May 18, 2010 1:26 PM, "Geoff Longman" <glon...@gmail.com> wrote:

Cool. Thanks for the insight. testbot.py has no problem fighting real players so I'll investigate the buffering and or timing issues. Awesome. Geoff

Sent from my iPod

On 2010-05-18, at 12:19 PM, warf <jeffrey...@gmail.com> wrote: > ROTATETO works, but I belie...

Geoff Longman

unread,
May 18, 2010, 3:58:27 PM5/18/10
to unrea...@googlegroups.com
My bad. you're right, no ROTATETO - I'm getting befuddled!

I think I've mixed up my threads in this group! sorry.

Geoff
Reply all
Reply to author
Forward
0 new messages