Candy Crush

Configuration

JSON
{
  "options": {
    "canvas_width": 550,
    "canvas_height": 380,
    "max_moves": 10,
    "time_left": 0,
    "game_rows": 6,
    "game_columns": 9,
    "header_height": 0,
    "margin_height_top": 0,
    "margin_height_bottom": 0,
    "backgroundColor": "transparent",
    "backgroundPosition": "center",
    "highlightColor": "black",
    "textColor": "white",
    "headerColor": "black",
    "moveColor": "white",
    "clueColor": "black",
    "datas": [
      {
        "img": GAME_URL + "/assets/candy-crush/item-1.png",
        "points": 100,
        "proba": 1
      },
      {
        "img": GAME_URL + "/assets/candy-crush/item-2.png",
        "points": 100,
        "proba": 1
      },
      {
        "img": GAME_URL + "/assets/candy-crush/item-3.png",
        "points": 100,
        "proba": 1
      },
      {
        "img": GAME_URL + "/assets/candy-crush/item-4.png",
        "points": 100,
        "proba": 1
      },
      {
        "img": GAME_URL + "/assets/candy-crush/item-5.png",
        "points": 100,
        "proba": 1
      },
      {
        "img": GAME_URL + "/assets/candy-crush/item-6.png",
        "points": 100,
        "proba": 1
      }
    ],
    "default_lang": "fr"
  },
  "texts": {
    "en": {
      "score": "Score",
      "move_left": "Moves",
      "time_left": "Time remaining",
      "flush": "No more combinations...",
      "flush2": "Shuffle!",
      "gameover": "Game over!",
      "gameover2": "Did you win?"
    },
    "fr": {
      "score": "Score ",
      "move_left": "Déplacements ",
      "time_left": "Temps restant ",
      "flush": "Plus de combinaisons possibles...",
      "flush2": "Redistribution !",
      "gameover": "Le jeu est terminé !",
      "gameover2": "Avez-vous gagné ?"
    },
    "nl": {
      "score": "Score",
      "move_left": "Bewegingen",
      "time_left": "Resterende tijd",
      "flush": "Geen meer combinaties...",
      "flush2": "Herverdeling!",
      "gameover": "Het spel is afgelopen!",
      "gameover2": "Heb je gewonnen?"
    }
  },
  "sounds": {},
  "images": {
    "backgroundImage": "",
    "rewards": {}
  }
}

Options

Key
Type
Explanation
Default
canvas_width / _height

Integer

Size of the game.

550 / 380

max_moves

Integer

Number of moves allowed.

10

time_left

Integer

Time before game over (if no max_moves). If both moves and time are set, time is used!

0

game_rows / _columns

Integer

Number of rows / columns in the game.

6 / 9

header_height
margin_height_top
margin_height_bottom

Integer

[Advanced] Layout adjustements.

0 / 0 / 0

backgroundColor

String

Background colour (visible if no image).

"transparent"

backgroundPosition

String

Background image positioning (CSS).

"center"

highlightColor

String

Colour of item selection.

"black"

textColor

String

Texts color.

"white"

headerColor

String

Header background colour.

"black"

moveColor

String

Colour of the line showing the current move.

"white"

clueColor

String

Colour of the clue line.

"grey"

datas > img

String

URL of the item visual.

datas > points

Integer

Points given per item matched.

100

datas > proba

Integer

Chances of the item to drop in the grid.

1

default_lang

String

[PTF] Default language if unmatched language.

"fr"

score

String

Text in the header.

"Score"

move_left

String

Text in the header (if max_moves set).

"Moves"

time_left

String

Text in the header (if time_left set).

"Time remaining"

flush / flush2

String

Text displayed if no more combinations.

"No more combinations..." / "Shuffle!"

gameover / gameover2

String

Text displayed at the end of the game.

"Game over!" / "Did you win?"

Assets

Key
Size
Explanation
Default
backgroundImage

550 x 380px (fit the canvas config size).

Background of the game.

/

datas > img

64 x 64px

Items of the game (must be square).

Last updated