Author Topic: Shift Weapon AI help  (Read 1028 times)

Offline Resetti's Replicas

  • *
  • Posts: 4399
  • Rep: 18
  • Replica King
    • ResettisReplicas
  • Awards BOTM Winner
    • View Profile
    • Awards
  • See profile for gamer tags: Yes
Shift Weapon AI help
« on: May 23, 2011, 10:36:41 AM »
I'm tinkering with the ShiftWeapon AI for one of my bots (It's the one where you mount a spin motor onto a servo so that the configuration of your spin weapon changes constantly) and I don't understand what the variables do.  Can anyone explain these, plus the range of acceptable numbers?
'servoNbPos', 'servoTimer', ''servodelta,' and 'servorange.'

Also is there a way to make the servo pivot less often.  At the moment it's shifting about once per 1-2 seconds

Offline Squirrel_Monkey

  • Squirrel_Monkeyweight
  • *
  • Posts: 7582
  • Rep: 7
  • [Insert clever and witty comment here]
    • 0SquirrelMonkey0
    • View Profile
    • Awards
Re: Shift Weapon AI help
« Reply #1 on: May 23, 2011, 10:42:34 AM »
list.append( ("shiftweapon II", "ShiftWeapon3", { 'nose': math.pi, 'servospeed':30,'servodelta':0.05, 'servoTimer':35, 'servoNbPos':4,'weapons': (1,2,3,4) }) )
EDIT to fit bot.
Better than GK since 2009.
I think SM is a pretty cool guy, eh builds unicycle-bots and doesn't afraid of anything

Offline Resetti's Replicas

  • *
  • Posts: 4399
  • Rep: 18
  • Replica King
    • ResettisReplicas
  • Awards BOTM Winner
    • View Profile
    • Awards
  • See profile for gamer tags: Yes
Re: Shift Weapon AI help
« Reply #2 on: May 23, 2011, 10:45:36 AM »
I have that already, I want to know how it affects the bot's performance when I change the numbers

Offline Squirrel_Monkey

  • Squirrel_Monkeyweight
  • *
  • Posts: 7582
  • Rep: 7
  • [Insert clever and witty comment here]
    • 0SquirrelMonkey0
    • View Profile
    • Awards
Re: Shift Weapon AI help
« Reply #3 on: May 23, 2011, 10:47:12 AM »
Experiment I guess.
servospeed might be how fast it turns.
EDIT: Seems to explain it well in the python file.
Better than GK since 2009.
I think SM is a pretty cool guy, eh builds unicycle-bots and doesn't afraid of anything

Offline Clickbeetle

  • *
  • Posts: 3374
  • Rep: 21
  • In Soviet Russia, bugs stomp YOU!
  • Awards BOTM Winner
    • View Profile
    • Beetle Bros site
    • Awards
Re: Shift Weapon AI help
« Reply #4 on: May 29, 2011, 08:53:40 PM »

Already explained this in a PM.  But for this

Also is there a way to make the servo pivot less often.  At the moment it's shifting about once per 1-2 seconds


you want to increase servoTimer.

To lack feeling is to be dead, but to act on every feeling is to be a child.
-Brandon Sanderson, The Way of Kings

Offline ACAMS

Re: Shift Weapon AI help
« Reply #5 on: May 29, 2011, 10:59:31 PM »
Experiment I guess.
servospeed might be how fast it turns.
EDIT: Seems to explain it well in the python file.


Are you Sparkbutt double accounting????


We don't guess in Technical support, if you don't know then keep quiet!

Offline Squirrel_Monkey

  • Squirrel_Monkeyweight
  • *
  • Posts: 7582
  • Rep: 7
  • [Insert clever and witty comment here]
    • 0SquirrelMonkey0
    • View Profile
    • Awards
Re: Shift Weapon AI help
« Reply #6 on: May 30, 2011, 04:13:38 AM »
Well, no-one else was helping so I did my own experiments with the .py file to see what it did then made observations.
Better than GK since 2009.
I think SM is a pretty cool guy, eh builds unicycle-bots and doesn't afraid of anything