Skip to content

Commit

Permalink
fixed collision issue with the PRNG and renamed some types
Browse files Browse the repository at this point in the history
  • Loading branch information
iChristwin committed May 10, 2024
1 parent 77e3c6d commit f53c94e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion src/utils/props.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import seedrandom from "seedrandom";

export function m3terProps(seed) {
const random = seedrandom(seed);
const random = seedrandom.alea(seed);
const eyesIndex = Math.round(random() * 15);
const mouthIndex = Math.round(random() * 11);
const textureIndex = Math.round(random() * 5);
Expand Down
33 changes: 17 additions & 16 deletions src/utils/types.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,39 +3,40 @@ export const eyeTypes = [
"bulging",
"dizzy",
"eva",
"frame1",
"frame2",
"frame-1",
"frame-2",
"glow",
"hal",
"happy",
"hearts",
"robocop",
"round",
"roundFrame01",
"roundFrame02",
"round-frame-1",
"round-frame-2",
"sensor",
"shade01",
"shade",
];

export const mouthType = [
"none",
"arturito",
"bite",
"diagram",
"grill01",
"grill02",
"grill03",
"grill-1",
"grill-2",
"grill-3",
"robocop",
"smile01",
"smile02",
"square01",
"square02",
"smile-1",
"smile-2",
"square-1",
"square-2",
];

export const textureType = [
"none",
"camo01",
"camo02",
"dirty01",
"dirty02",
"camo-1",
"camo-2",
"dirty-1",
"dirty-2",
"dots",
];

0 comments on commit f53c94e

Please sign in to comment.