gametechmods

Robot Arena => General Support => Topic started by: Thrackerzod on February 27, 2015, 12:31:15 PM

Title: Spinning weapons do not start when match starts
Post by: Thrackerzod on February 27, 2015, 12:31:15 PM
I was trying to AI some robots that have spinning weapons.  It looks like the weapons do not begin spinning until a few seconds after the match begins.  What should I be doing so that they begin spinning right as the match begins?

Also, how do I add and use more .pys without crashing the game?
Title: Re: Spinning weapons do not start when match starts
Post by: helloface on February 27, 2015, 12:42:36 PM
Increase the range. 99 usually does the trick.
Title: Re: Spinning weapons do not start when match starts
Post by: Thrackerzod on February 27, 2015, 12:50:59 PM
That did it, thanks.

EDIT: Now I have a hammer bot that isn't firing its hammer.  Any idea as to what could be causing that?
Title: Re: Spinning weapons do not start when match starts
Post by: I Like Tacos on February 27, 2015, 02:38:51 PM
Do you have a smartzone named 'weapon'?
Title: Re: Spinning weapons do not start when match starts
Post by: Thrackerzod on February 27, 2015, 05:21:50 PM
Yes, including the lowercase.  The control that fires the hammer is named "Fire".
Title: Re: Spinning weapons do not start when match starts
Post by: cephalopod on February 27, 2015, 05:25:36 PM
What .py are you using for it?
Title: Re: Hammer weapon does not fire
Post by: Thrackerzod on February 27, 2015, 05:33:20 PM
Omni at the moment.

Updated thread name.
Title: Re: Spinning weapons do not start when match starts
Post by: cephalopod on February 27, 2015, 05:35:15 PM
That should work. Does your binding have a 'weapons' section with any numbers in it? If it doesn't, it needs one
Title: Re: Spinning weapons do not start when match starts
Post by: Thyrus on February 27, 2015, 05:53:48 PM
does "Fire" and "Spin" do the same for spinning weapons that use omni?
Title: Re: Spinning weapons do not start when match starts
Post by: Thrackerzod on February 27, 2015, 05:56:09 PM
It didn't have any numbers.  I copied the "weapons" section from the line above it, and now it fires.  Should the numbers be anything in particular?

does "Fire" and "Spin" do the same for spinning weapons that use omni?

I switched over to a different problem involving a hammer bot and didn't feel like making a new thread.
Title: Re: Spinning weapons do not start when match starts
Post by: Resetti's Replicas on February 27, 2015, 06:06:26 PM
If you have no numbers in the "weapons" section, your bot thinks it has no active weapons and will act accordingly.  You know how each component in your bot has a number, ie the first one you place is #1, second is #2, etc?  That's what the numbers in the "weapons" section means.  When all of the corresponding components have broken off, your bot switches to weaponless mode, where it cautiously moves back and forth at the opponent.  If you never want it to go into weaponless mode, put in a number that corresponds to something attached to the baseplate, like a battery.
Title: Re: Spinning weapons do not start when match starts
Post by: Thrackerzod on February 27, 2015, 06:09:30 PM
That makes sense.  How do I know what number corresponds to which component, though?  Or was I just supposed to remember the order I built it in?
Title: Re: Spinning weapons do not start when match starts
Post by: Thyrus on February 27, 2015, 06:13:24 PM
This thread should be added to something like a trouble scouting thread for AIing n stuff.
Title: Re: Spinning weapons do not start when match starts
Post by: cephalopod on February 27, 2015, 06:15:22 PM
You can use Apanx Bot Exporter to find the numbers, but I just put 0 into most of my lines - 0 corresponds to the chassis, so the weapons will always try to fire.
Title: Re: Spinning weapons do not start when match starts
Post by: Resetti's Replicas on February 27, 2015, 06:41:17 PM
If you're using Win7, you' may need to do this fix to make it work (don't worry, nothing too painful)

http://windowsxp.mvps.org/comdlg32.htm (http://windowsxp.mvps.org/comdlg32.htm)