초기커밋

This commit is contained in:
2025-05-01 07:20:41 +09:00
commit 98bb2e3c5c
2747 changed files with 646947 additions and 0 deletions

View File

@@ -0,0 +1,108 @@
using Amazon.DynamoDBv2.DocumentModel;
using Google.Protobuf.WellKnownTypes;
using Nettention.Proud;
using ServerCommon;
using ServerCore; using ServerBase;
using System.Collections.Concurrent;
using static ClientToGameMessage.Types;
using static ClientToGameReq.Types;
namespace GameServer
{
// public partial class ClientSession : IEntityWithSession
// {
//
// public void HandleGetClaimInfoReq()
// {
//
// ServerErrorCode errorCode = claimInfoRefresh(_selectedChar);
//
// if(errorCode != ServerErrorCode.Success)
// {
// clientToGame.Response.ErrorCode = errorCode;
// Send(RmiContext.ReliableSend, clientToGame);
// return;
// }
//
// List<ClientToGame> CtoGs = ClaimRewardHelper.MakeClaimSendInfo(_selectedChar, true);
// Send(RmiContext.ReliableSend, CtoGs[0]);
//
// return;
// }
//
// public void claimInfosRefreshAndNoti(object player)
// {
// // if (!player.archiveEvents.TryGetValue(EEventType.ClaimReward, out var eventInfos))
// // {
// // Log.getLogger().error("archiveEvents is null");
// // return;
// // }
// //
// // if(eventInfos.RefreshEvent())
// // {
// // eventInfos.EventUpdateNoti();
// // }
// }
//
//
// public ServerErrorCode claimInfoRefresh(object player)
// {
// if (!player.archiveEvents.TryGetValue(EEventType.ClaimReward, out var eventInfos))
// {
// Log.getLogger().error("archiveEvents is null");
// return ServerErrorCode.ServerLogicError;
// }
//
// bool needUpdate = eventInfos.RefreshEvent();
// return ServerErrorCode.Success;
// }
//
// public void HandleClaimReset()
// {
// if (_selectedChar == null)
// {
// Log.getLogger().error("_selectedChar is null");
// throw new Exception("HandleClaimReset() and _selectedChar is null");
// }
//
//
// // ClaimNormalEntity newNormalEntity = new ClaimNormalEntity(_selectedChar.claimNormalEntity.DocumentForUpdate());
// // ClaimMembershipEntity newMembershipEntity = new ClaimMembershipEntity(_selectedChar.claimMembershipEntity.DocumentForUpdate());
// //
// // newNormalEntity.Attr = new();
// // newMembershipEntity.Attr = new();
// // Document docNormal = newNormalEntity.DocumentForUpdate();
// // Document docMembership = newMembershipEntity.DocumentForUpdate();
// // var cts = new CancellationTokenSource();
// //
// // List<DBDocumentInfo> dBDocumentInfos = new();
// // dBDocumentInfos.Add(new DBDocumentInfo(docNormal, EDBExecuteType.Update));
// // dBDocumentInfos.Add(new DBDocumentInfo(docMembership, EDBExecuteType.Update));
// //
// // try
// // {
// // GameServerApp.Instance.MainDB.Transaction(dBDocumentInfos, 2).WaitAsync(cts.Token);
// // }
// // catch (OperationCanceledException)
// // {
// // //ErrorLog
// // return;
// // }
// // finally
// // {
// // cts.Dispose(); // CancellationTokenSource 해제
// // }
// // _selectedChar.claimNormalEntity.ReadFrom(docNormal);
// // _selectedChar.claimMembershipEntity.ReadFrom(docMembership);
// return;
//
//
// }
//
//
}