Author Topic: Reversing Controls  (Read 726 times)

Offline WhamettNuht

  • *
  • Posts: 1302
  • Rep: 12
  • Robot Building Drag Queen
    • View Profile
    • Awards
  • Discord: WhamettNuht #1457
Reversing Controls
« on: September 02, 2009, 03:28:27 AM »
Hey All
I made a robot like Stinger recently (drive like Stinger aswell!) and tried to AI it, but when the AI'ed version is "Upside down" the robots controlls are then reversed and it ends up driving into a wall.
The cure may be right under my nose, it may not, but is there any way of getting the robot to reverse the controlls when upside down, and then putting them back to normal when right side up.
BTW the robot is using the Frenzy AI PY.
Thanks
Wham
EDIT: I just realised i posted this in the wrong section, sorry! :(
Was meant to go in Technical Suport...
Damn I should probably put something fancy in this bit huh?

Offline Naryar

  • Posts: 23267
  • Rep: 20
  • hybrids oui oui
    • http://www.youtube.com/us
  • Awards BOTM Winner
    • View Profile
    • Awards
  • Skype: TheMightyNaryar
Reversing Controls
« Reply #1 on: September 02, 2009, 04:04:58 AM »
What bot type it is exactly? A vertical SpinHammer ?

Technically Frenzy.py uses it's weapon 'Hammer' to selfright if inverted, but i dont know if it supports 'invertible':True...

Offline somestrangeguy

  • *
  • Posts: 2068
  • Rep: 2
  • If you can read this, your monitor is turned on.
  • Awards BOTM Winner
    • View Profile
    • Awards
Reversing Controls
« Reply #2 on: September 02, 2009, 04:51:27 AM »
Quote from: WhamettNuht;63643
The cure may be right under my nose


Indeed. You need to add 'nose':math.pi/2 to your AI code if /2 doesnt work try *2 or just math.pi