<?php

declare(strict_types=1);

namespace app\common\service;

/**
 * 兼容层：保留旧类名，内部转发到 GameRecordService
 */
final class GamePeriodService
{
    public const KEY_AUTO_CREATE = GameRecordService::KEY_AUTO_CREATE;
    public const KEY_MANUAL_CREATE = GameRecordService::KEY_MANUAL_CREATE;

    public static function getConfigBool(string $key): bool
    {
        return GameRecordService::getConfigBool($key);
    }

    public static function getPeriodSettings(): array
    {
        return GameRecordService::getRecordSettings();
    }

    public static function savePeriodSettings(array $data): void
    {
        GameRecordService::saveRecordSettings($data);
    }

    public static function hasActivePeriod(): bool
    {
        return GameRecordService::hasActiveRecord();
    }

    public static function tickAutoCreate(): void
    {
        GameRecordService::tickAutoCreate();
    }

    public static function createNextPeriodForManual(): array
    {
        return GameRecordService::createNextRecordForManual();
    }
}
