generator client { provider = "prisma-client-js" } datasource db { provider = "postgresql" url = env("DATABASE_URL") } enum Biome { PLAINS FIELDS WOODLAND FOREST SWAMP TUNDRA MOUNTAIN CAVE DESERT } model ZoneBiomes { id String @id @default(uuid()) @db.Uuid players Player? playerId String? @db.Uuid biome Biome maxSteps Int @default(500) } model Player { id String @id @default(uuid()) @db.Uuid username String @unique password String level Int @default(1) currency Int @default(0) pow Int zest Int woosh Int luck Int aha Int wow Int stamina Int hp Int statPoints Int @default(0) exp Int @default(0) zoneBiome ZoneBiomes @relation(fields: [zoneBiomeId], references: [id]) zoneBiomeId String @db.Uuid authToken AuthToken? steps Int @default(0) } model AuthToken { token String @id @default(uuid()) @db.Uuid player Player @relation(fields: [playerId], references: [id]) playerId String @db.Uuid createdAt DateTime @default(now()) updatedAt DateTime? @updatedAt } enum MonsterType { BEAST FLYING HUMANOID GIANT INSECT UNDEAD } model Monster { id String @id @default(uuid()) @db.Uuid name String @unique monsterType MonsterType[] monsterBiomes MonsterBiome[] } model MonsterBiome { monster Monster @relation(fields: [monsterId], references: [id]) monsterId String @db.Uuid biome Biome weight Decimal time Json @@id([monsterId, biome]) } model Fight { id String @id @default(uuid()) @db.Uuid playerId String? @db.Uuid monsterId String @db.Uuid name String type MonsterType[] level Int currency Int pow Int zest Int woosh Int luck Int aha Int wow Int hp Int exp Int }