Technical Details

Game Resolution Algorithm

  • Up to five cryptomonsters join a game.
  • The cryptomonsters are numbered according to the order that they join the game.
  • The game starts, when the last monster joins.
  • When the game starts, the most recent Litecoin blockchain block (let's mark it with index i) is bound to the game and the platform enters a waiting state - it waits for the block with index i+2 to be mined and propagated through the network. This upcoming block (unknown at the time, when the game starts) is called the resolving block.
  • Depending on its level each cryptomonster is assigned with a winning evolutionary range.
    The sum of the lengths of all ranges equals exactly 65536.
    You can check the examples below.
  • When the resolving block (the block with index i+2) is mined and propagated through the Litecoin Blockchain, its hash value is converted into a special number, called the magic number, as it is defined below.

    HIGH_BYTE = the sum of the first 16 bytes of the block's hash value, stored in one byte
    LOW_BYTE = the sum of the last 16 bytes of the block's hash value, stored in one byte
    Magic Number = (HIGH_BYTE << 8) | LOW_BYTE

    Note #0: The magic number is a 16-bit unsigned integer value.
    Note #1: There is nothing magical about the magic number except its name.
    Note #2: The resolving block may happen to be an orphaned/stale block and, in this case, will be accepted by the platform. However, in order to minimize this possibility, the platform awaits a block with index i+3 to appear in the Blockchain before finalizing a game based on a resolving block with index i+2.
  • The winner is the monster, whose winning evolutionary range the magic number is in.
  • The final step is the monster's crypto evolution, which happens as follows:
    The winner's level increases by 20% of the total sum of the loser levels
    Each loser's level decreases by 20%
    The winner exchanges its:
      ✗ body color for the body color of the 1th loser;
      ✗ eyes for the eyes of the 2th loser;
      ✗ mouth for the mouth of the 3th loser;
      ✗ legs for the legs of the 4th loser;
    If a loser's level drops below 0.2, the loser can't evolve anymore and ascends to the Cryptomonsters Heaven

Evolutionary ranges - examples

Example #1: Five monsters join a game and have equal levels (level 1), they also have equal winning chances - therefore their winning evolutionary ranges are:
MonsterWinning ChanceWinning Evolutionary Range
IndexLevel fromtolength
111/50 (0x0000)13107 (0x3333)13108
211/513108 (0x3334)26214 (0x6666)13107
311/526215 (0x6667)39321 (0x9999)13107
411/539322 (0x999A)52428 (0xCCCC)13107
511/552429 (0xCCCD)65535 (0xFFFF)13107
Example #2: Five monsters join a game, the first monster has level 4 and the remaining monsters - level 1:
MonsterWinning ChanceWinning Evolutionary Range
IndexLevel fromtolength
144/8 = 1/20 (0x0000)32767 (0x7FFF)32768
211/832768 (0x8000)40959 (0x9FFF)8192
311/840960 (0xA000)49151 (0xBFFF)8192
411/849152 (0xC000)57343 (0xDFFF)8192
511/857344 (0xE000)65535 (0xFFFF)8192