Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How are the puzzles eported? #31

Open
rubo77 opened this issue Feb 18, 2024 · 1 comment
Open

How are the puzzles eported? #31

rubo77 opened this issue Feb 18, 2024 · 1 comment

Comments

@rubo77
Copy link

rubo77 commented Feb 18, 2024

I would like to add an export/share option to Roboyard as well. How are the puzzles exported? I would like to use the same format for exchangeablility

Eastcoast-Laboratories/Roboyard#24

@smack42
Copy link
Owner

smack42 commented Feb 19, 2024

The relevant code is implemented in class Board
https://github.com/smack42/DriftingDroids/blob/master/src/driftingdroids/model/Board.java

There are two alternative ways to import/export the board states:

game ID (works for original Ricochet Robots boards, only)

  • getGameID() is export/save
  • createBoardGameID() is import/load
  • example: 0132+50+01B63F4512+AD

custom board load/save (works for all kinds of boards)

  • getGameDump() is export/save
  • createBoardGameDump() is import/load
  • example (same board as the game ID above):
    !DriftingDroids_game!A5ADC6DF!AAAEk3ja5VIxDsIwDLxzYAfEysDIB1iZ+AYLY9/BR5hYWBl4BBNvQOIVYEdN1bouYq+ls+7ai+M4AYCZYaqJiptip9grFmASukBtRCGNcMFQ8IeNtcpVnZGuXNFlDYi4F/7JBvr1ZrrDsFFsuwfPS6cYT5PsFKLT8cw6xcKJsHdjdDvTHWJ0983egx/3A9CYK5aZrXMX25Q0H0U0H2h8BeOVUWzEPG/7gEcyfqeJK+z35TPRfBbjz1z/lLd5peL5Avt9DJ0=!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants