[Pogamut-list] Rotate bot in the right angle when hearing noise

aisa87 pogamut-forum at diana.ms.mff.cuni.cz
Thu May 5 17:47:24 CEST 2011


Re: Rotate bot in the right angle when hearing noise

Author: aisa87

Great!

I have been doing some cool things (: now my bot shoots shock combos!! haha, it's even hard to kill him sometimes!

I have to adapt the code I wrote to the api of Pogamut 3.2, since move.dodge () doesn't exists now. I'm finding a lot of trouble to make the bot dodge in one direction. I am supposed to use a Location, but.. for example, I pick up a Location that is right behind the bot, and then I do move.dodge (, ), and the bot doesn't EVER dodge in that direction, it dodges in all sort of directions.. I'm not using setFocus, nothing like that. In the code I wrote, I was making him dodge in 8 different directions:

North: new Vector3d (1, 0, 0)
North-east: new Vector3d (1, 1, 0)
East: new Vector3d (0, 1, 0)
South-east: new Vector3d (-1, 1, 0)
South: new Vector3d (-1, 0, 0)
South-west: new Vector3d (-1, -1, 0)
West: new Vector3d (0, -1, 0)
North-west: new Vector3d (1, -1, 0)

I don't want him to focus, I'm taking care of that by myself. So, how can I make him behave just like that using the current api?

Best,
Fran.

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





More information about the Pogamut-list mailing list