mirror of
https://github.com/MikuLeaks/KianaBH3.git
synced 2025-12-14 22:04:36 +01:00
20 lines
615 B
Python
20 lines
615 B
Python
import betterproto
|
|
import random
|
|
from game_server.net.session import Session
|
|
from utils.time import get_unix_in_seconds
|
|
from lib.proto import GetOpenworldEndlessDataReq, GetOpenworldEndlessDataRsp
|
|
|
|
|
|
async def handle(
|
|
session: Session, msg: GetOpenworldEndlessDataReq
|
|
) -> betterproto.Message:
|
|
return GetOpenworldEndlessDataRsp(
|
|
retcode=0,
|
|
begin_time=0,
|
|
end_time=int(get_unix_in_seconds() + 3600 * 24 * 7),
|
|
close_time=int(get_unix_in_seconds() + 3600 * 24 * 7 + 1200),
|
|
random_seed=random.randint(1, 1000000),
|
|
hard_level=msg.level,
|
|
type=msg.type,
|
|
)
|