Talk:BasicGFSurfer

From Robowiki
Revision as of 03:41, 10 March 2011 by Voidious (talk | contribs) (migrating talk)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

From old wiki

This bot is stronger than expected. -- GrubbmGait

Yeah, it's stronger than my Squirrel, which was SUPPOSED to take that code and improve it but all it did was make it worse :(. --Bayen

I don't think the tutorials are under the RWPCL, I fiugured the code was just to use and abuse for anything thats sports your fancy. (not that my bots aren't under the RWPCL anyway) -- Chase-san

PEZ put GFTargetingBot under the RWPCL, but I consider the WaveSurfing/Tutorial to be available to use however you want. -- Voidious

I lifted the RWPCL licensing now. The code is in the public domain. Of course I do believe very hard in OpenSource and would encourage anyone to use it anyway. -- PEZ

I put Squirrel's code in the jar, so that makes it open source, right? Anyway, I don't think anyone would really want to use my code, for two reasons. It's extremely messy, and Squirrel isn't that good. Oh well --Bayen

  • Yes, that makes it open source ;) -- Voidious

Hmm, when i run Plains against BasicGFSurfer, i sometimes get a

wiki.BasicGFSurfer 1.0: Exception: java.lang.ArrayIndexOutOfBoundsException: 5
java.lang.ArrayIndexOutOfBoundsException: 5
    at wiki.GFTWave.setSegmentations(BasicGFSurfer.java:386)
    at wiki.BasicGFSurfer.onScannedRobot(BasicGFSurfer.java:102)
    at robocode.peer.robot.EventManager.onScannedRobot(Unknown Source)
    at robocode.peer.robot.EventManager.processEvents(Unknown Source)
    at robocode.peer.RobotPeer.tick(Unknown Source)
    at robocode.peer.RobotPeer.turnRadar(Unknown Source)
    at robocode._AdvancedRadiansRobot.turnRadarRightRadians(Unknown Source)
    at wiki.BasicGFSurfer.run(BasicGFSurfer.java:51)
    at robocode.peer.RobotPeer.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)

Also, on two of the rounds, BasicGFSurfer is stopped.

----------------------
Round 3 initializing....
Let the games begin!
Round 3 cleaning up.
----------------------
Round 4 initializing....
Let the games begin!
wiki.BasicGFSurfer 1.0 has been stopped.  No score will be generated.
Round 4 cleaning up.
----------------------
Round 5 initializing....
Let the games begin!
wiki.BasicGFSurfer 1.0 has been stopped.  No score will be generated.
Round 5 cleaning up.
----------------------
Round 6 initializing....
Let the games begin!
Round 6 cleaning up.
----------------------
etc

--Starrynte

I can see why - it has MAX_DISTANCE set to 900, but technically the maximum distance should be 1000 - BOT_WIDTH (because it measures from center of the bot) on an 800x600 field (like a 3/4/5 right triangle). If you are as far away as possible, it will be a higher index than the stat buffer is initialized with. Really, the safest thing to do would be to calculate MAX_DISTANCE based on battlefield width and height. Hopefully, that stoppage thing is also related. I'll update the GFTargetingBot tutorial; somebody should release a BasicSurfer 1.1 =) -- Voidious

  • Maybe the introduction should be changed to read, "... the basic, buggy implementation of a WaveSurfer with GuessFactorTargeting ...". =P -- AaronR

Bugfixed version 1.01 available. Made a more robust fix than just increasing the distance, without any effect on distances < 900. MAX_DISTANCE remains 900.

int distanceIndex = Math.min(DISTANCE_INDEXES-1, (int)(distance / (MAX_DISTANCE / DISTANCE_INDEXES)));

-- GrubbmGait

You cannot post new threads to this discussion page because it has been protected from new threads, or you do not currently have permission to edit.

Contents

Thread titleRepliesLast modified
BasicDCSurfer1001:58, 4 December 2013

BasicDCSurfer

when will somebody make BasicDCSurfer

Tmservo (talk)00:49, 1 December 2013

Why don't you make one?

Skilgannon (talk)13:58, 1 December 2013

because i Don't really have any programming skills

Tmservo (talk)14:17, 1 December 2013

Then what benefit would a BasicDCSurfer be?

Chase18:59, 1 December 2013
Edited by author.
Last edit: 13:44, 2 December 2013

maybe you should make a basic dc surfer im asking Everyone

Tmservo (talk)00:31, 2 December 2013

It's just not necessary. Between the Wave Surfing Tutorial and DCBot or the Dynamic Clustering Tutorial, there's plenty of info to help someone make such a bot. The tutorials aren't intended to provide base code for every possible combination - making exactly the bot you want is the interesting part. :-)

Voidious (talk)01:33, 2 December 2013
 

Reply to message 'maybe you should make a basic dc surfer im asking everyone' from Tmservo:

By BasicDCSurfer do you mean a surfer with a DCBot's gun or a surfer using Dynamic Clustering in its movement? Because for the first one, it's a few copy-pastes and it's finished(I've done it and I'm pretty nooby). But sometimes I find a glitch in DCBot's gun...

BeastBots101 (talk)02:01, 3 December 2013