Skip to content

Commit

Permalink
remove berries from wonderbox items (#1221)
Browse files Browse the repository at this point in the history
  • Loading branch information
sylvainpolletvillard authored Nov 10, 2023
1 parent e7ddbd9 commit fa2314d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/models/item-factory.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import { Item, BasicItems, SynergyStones } from "../types/enum/Item"
import { Item, SynergyStones, CompletedItems } from "../types/enum/Item"
import { SetSchema } from "@colyseus/schema"
import { pickRandomIn } from "../utils/random"

export default class ItemFactory {
static createWonderboxItems(existingItems: SetSchema<Item>): Item[] {
const wonderboxItems: Item[] = []
for (let n = 0; n < 2; n++) {
const elligibleItems = (Object.keys(Item) as Item[]).filter(
const elligibleItems = CompletedItems.filter(
(i) =>
!BasicItems.includes(i) &&
!SynergyStones.includes(i) &&
!wonderboxItems.includes(i) &&
!existingItems.has(i) &&
Expand Down

0 comments on commit fa2314d

Please sign in to comment.