Skip to content

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

55 watching

Forks

Latest commit

 

History

8 Commits

Folders and files

Repository files navigation

webots-competition-organizer-template

Webots Badge

Organize

Make repositories

First, you need to make a repository like this by clicking on the green button Use this template. You also need to do the same for the competitor repository so the competitors can fork it and push their controllers.

Personal Access Token

PAT (Personal Access Token) is necessary to be able to pull a code from a participant's private repositories.

  • Generate a new token here. In the Select scopes section check repo.
    • If this repository is hosted at a GitHub organization you will need to create a new GitHub account and generate the token for it.
  • Create a new secret, name it BOT_PAT_KEY and paste the key you have just generated.
  • Create a new secret again, name it BOT_USERNAME and put your username in it.
    • If this repository is hosted at a GitHub organization use your bot's username.
  • Let the participants know they have to add your username to Settings > Manage access so you have the right to clone their private repositories.

Customize

The sample competition is just a sample and you probably want implement a custom scenario and rules.

  • Change the scenario in the world file (worlds/competition.wbt).
  • Change the contest manager controller:
    • The purpose of this supervisor controller is to keep a track of the competitors and their points, something like a referee.
    • You should write the competition results to /tmp/results.txt, so the results can be parsed by CI.
      # Format of `/tmp/results.txt`:
      #   winner: [index of winner]
      #   points: [points of the first robot], [points of the second robot]
      winner: 0
      points: 111, 0
    • Once the match is over, you should use the Emitter node to send done on channel 1024 so our animation recorder is aware the match is done.

Publish the results

The Webots GitHub action generates a preview of the competition and publishes it to the gh-pages branch. Therefore, you have to choose the gh-pages branch as the publishing source. Then, you can access the preview at [your_username].github.io/[your_repo_name].

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

55 watching

Forks

Releases

Packages

Contributors

Languages