Menu

#36 Initial Placement

1.3
closed
Battle (24)
3
2012-10-06
2007-01-21
Anonymous
No

Some way to specify where bots start on the field (and their heading), so I can test if my bot behaves correcly when starting in the corner, right next to the other bot, ect.

-- Simonton

Discussion

  • Flemming N. Larsen

    Logged In: YES
    user_id=1249353
    Originator: NO

    Can you give me an example of how to specify the initial position, heading etc.?

     
  • Nobody/Anonymous

    Logged In: NO

    Ideali configurable via *.battle file. LuVar

     
  • Nobody/Anonymous

    Logged In: NO

    I think this is consistent way...

    robocode.battle.rules.inactivityTime=450
    robocode.battle.selectedRobots=sample.Corners,sample.Fire,sample.MyFirstRobot,sample.SittingDuck,sample.Walls
    robocode.battle.selectedRobots.Possitions=(10,13,230),(100,130,0),(77,13,1),(10,34,5),(77,13,230)
    robocode.battleField.height=600

    (x,y,headingAngle)

    but conflicts like (10,10,0) (10,10,45) should be handled, input like () should be handled like random position etc.

    My use of this feature will be in creating robots by evolutionary methods. (if they have same start position, it is easiest to learn them something :)

    PS: I am new in robocode and I don't know, if this example is consistent...

     
  • Flemming N. Larsen

    Logged In: YES
    user_id=1249353
    Originator: NO

    This sound reasonable, and I will of course implement in a comming version. :-)

     
  • Flemming N. Larsen

    Logged In: YES
    user_id=1249353
    Originator: NO

    This feature has now been implemented in the comming Robocode 1.3 Beta.

     
  • Flemming N. Larsen

    Logged In: YES
    user_id=1249353
    Originator: NO

    This feature has been added into Robocode 1.3 Beta.

    The format is almost like you suggested. Here is and example:

    (50,50,90),(100,100,?),?,(200,150),,(?),(30,?,180)

    The question mark means "random". Omitting a parameter also means random.

    If the position has already been taken or collides with another robot boundaries that has already "taken" the position, then the robot will be put on a random position.

     
  • Lubomir Varga

    Lubomir Varga - 2007-04-13

    Logged In: YES
    user_id=1624049
    Originator: NO

    thanks :-)

     
  • SourceForge Robot

    Logged In: YES
    user_id=1312539
    Originator: NO

    This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     

Anonymous
Anonymous

Add attachments
Cancel





MongoDB Logo MongoDB