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

aisa87 pogamut-forum at diana.ms.mff.cuni.cz
Thu Apr 28 01:05:44 CEST 2011


Rotate bot in the right angle when hearing noise

Author: aisa87

Hi,

I have been experiencing some trouble trying to make the bot turnTo a noise. I have done the following:

    @EventListener (eventClass = HearNoise.class)
    protected void hearNoise (HearNoise event) {
        move.turnTo(event.getRotation().toLocation());
    }

The listener works just fine, the problem is, the bot does not turn, ever! I used turnTo (); because I do not know what else I can do with Rotation (which is what event.getRotation() retrieves). Any help would be appreciated.

I was also planning on doing some smart shooting with the rocket launcher and flack cannon. I still have not done any research, but I guess It is all a matter of playing with the speed of the enemy and the vector he is following (also the speed of the projectiles you are shooting). Someone has done anything like that?

Finally, I would like to remark again, that incomingProjectile listener, is not working, it does not update the position of the projectile.

Cheers, Fran.

(:

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





More information about the Pogamut-list mailing list