This commit is contained in:
Naruse
2025-04-15 19:36:05 +08:00
parent dd51fb491d
commit ec8972d5d6
121 changed files with 30598 additions and 0 deletions

View File

@@ -0,0 +1,15 @@
import betterproto
from game_server.net.session import PlayerSession
from rail_proto.lib import (
SetNicknameCsReq,
SetNicknameScRsp
)
async def handle(session: PlayerSession, msg: SetNicknameCsReq) -> betterproto.Message:
if msg.is_modify:
session.player.data.name = msg.nickname
await session.notify(session.player.PlayerSyncProto())
return SetNicknameScRsp(
retcode=0,
is_modify=msg.is_modify
)