Adventure-Bot / adventure-bot

Slay a monster! Stab your friend! Adventure Bot!
https://www.adventurebot.io/
6 stars 6 forks source link

Zombies always have the same art #163

Closed brian-gates closed 2 years ago

brian-gates commented 2 years ago

Zombie art asset always result in an index of 0.

https://github.com/Adventure-Bot/adventure-bot/blob/229fd38c32ad65dcf2c0070ca9c7f10962fa6d51/packages/game/src/utils/asset.ts#L28-L29

brian-gates commented 2 years ago
setInterval(() => {
  pipe(
    randomUUID(),
    (seed) => crypto.createHash('md5').update(seed).digest('hex'),
    (hash) => console.log(hash, parseInt(hash, 16) % 4)
  )
}, 1000)
0b85afae0464ea66417665a357842733 0
4afa4b08b33306ea8dcce472886b6bdf 0
2c1a6395914d04cab583f105bfe9c43d 0
ec8a37b10e93a4af129fa5077b24940d 0
c0d1ee0f91a3dcfd7ecea2ae92196f9f 0
22c6c16f8d31bbc6e255923b9be29ff9 0
361f2022b878a9eca77b55af1ed2606e 0
9ed459aab54e780a668551b24ab9f247 0
3a1eb8c41ef34c9500ae0b77f6275148 0
fb62a377d4296ac94abec70ce68152c8 0
a3098bbc986228191f1c9dd358222c3d 0
f14d5b9d632508a093df5ec49790d074 0
e2c2e464de8a8eeec18f69cf72b41ce7 0