Files
ashen-realms/apps/api/src/world/world.module.ts
Bastian Wagner bb307da0ff feat: wire HuntingController/HuntingModule and enrich current-location with monster pool
Registers HuntingModule (POST /api/hunts) into the DI graph alongside its
new entities, and adds possibleMonsters (enabled LocationMonster pool,
weight-descending, empty when hunting is disabled) to
WorldService.getCurrentLocation. Also updates the pre-existing
DB-less app.e2e-spec.ts to override HuntingModule the same way the other
feature modules already are, since it now needs a real DataSource.
2026-08-19 12:53:09 +02:00

25 lines
828 B
TypeScript

import { Module } from '@nestjs/common';
import { TypeOrmModule } from '@nestjs/typeorm';
import { Character } from '../characters/entities/character.entity';
import { LocationMonster } from '../monsters/entities/location-monster.entity';
import { MonsterDefinition } from '../monsters/entities/monster-definition.entity';
import { TravelModule } from '../travel/travel.module';
import { LocationConnection } from './entities/location-connection.entity';
import { WorldController } from './world.controller';
import { WorldService } from './world.service';
@Module({
imports: [
TypeOrmModule.forFeature([
Character,
LocationConnection,
LocationMonster,
MonsterDefinition,
]),
TravelModule,
],
controllers: [WorldController],
providers: [WorldService],
})
export class WorldModule {}