Files
vyryi-back/app/slots/registry.py
Redsandy 5125b52583 Add spin session functionality and update game mechanics
- Introduced a new `spin_sessions` table to track user spin activities.
- Updated the API to include a new endpoint for spinning games, allowing users to place bets and specify spin counts.
- Enhanced game information structure and added validation for bets and spin counts.
- Implemented the `Forest Fortune` slot game mechanics, including payline evaluation and scatter functionality.
- Updated dependencies in `pyproject.toml` for development and added `httpx` for HTTP requests.
- Added unit tests for the new slot mechanics and API endpoints to ensure functionality and reliability.
2026-08-12 15:27:24 +03:00

30 lines
807 B
Python
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
from __future__ import annotations
from app.slots.base import BaseSlot
from app.slots.coming_soon import ComingSoonSlot
from app.slots.forest_fortune import ForestFortuneSlot
_SLOTS: list[BaseSlot] = [
ComingSoonSlot(
slug="raven-reels",
title="Вороньи Барабаны",
description="Слоты у врат Вырия. Скоро откроются.",
),
ComingSoonSlot(
slug="golden-gate",
title="Золотые Врата",
description="Портал удачи. Пока запечатан.",
),
ForestFortuneSlot(),
]
_BY_SLUG: dict[str, BaseSlot] = {slot.slug: slot for slot in _SLOTS}
def list_slots() -> list[BaseSlot]:
return list(_SLOTS)
def get_slot(slug: str) -> BaseSlot | None:
return _BY_SLUG.get(slug)