feat : 레이드 이동 메시지 수정 모두에게

This commit is contained in:
qornwh1
2026-03-16 20:36:24 +09:00
parent dd8dcc58d2
commit 6faab45ecc
2 changed files with 11 additions and 8 deletions

View File

@@ -98,7 +98,10 @@ public class RestApi : Singleton<RestApi>
response.EnsureSuccessStatusCode();
BossRaidAccessResponse? raw = await response.Content.ReadFromJsonAsync<BossRaidAccessResponse>();
if (raw == null) return null;
if (raw == null)
{
return null;
}
// API 응답 → 도메인 모델 매핑
return new BossRaidResult

View File

@@ -1079,7 +1079,7 @@ public class GameServer : ServerBase
BossRaidResult? result = await RestApi.Instance.BossRaidAccesssAsync(userNames, 1);
// 입장 실패
if (result != null)
if (result == null || result.BossId <= 0)
{
SendTo(peer,
PacketSerializer.Serialize((ushort)PacketCode.INTO_BOSS_RAID,
@@ -1142,13 +1142,13 @@ public class GameServer : ServerBase
}
SendTo(memberPeer, PacketSerializer.Serialize((ushort)PacketCode.CHANGE_MAP, response));
}
// 파티장에게 입장 성공 응답 (할당된 실제 레이드 맵 ID 전달)
SendTo(peer,
PacketSerializer.Serialize((ushort)PacketCode.INTO_BOSS_RAID,
new IntoBossRaidPacket
{ RaidId = assignedRaidMapId, IsSuccess = true, Session = result.SessionName, Token = result.Tokens }));
// 모두에게 레이드로 이동 (할당된 실제 레이드 맵 ID 전달)
SendTo(peer,
PacketSerializer.Serialize((ushort)PacketCode.INTO_BOSS_RAID,
new IntoBossRaidPacket
{ RaidId = assignedRaidMapId, IsSuccess = true, Session = result.SessionName, Token = result.Tokens }));
}
Log.Debug("[GameServer] INTO_BOSS_RAID HashKey={Key} PartyId={PartyId} AssignedRaidMapId={RaidId}", hashKey, party.PartyId,
assignedRaidMapId);