mirror of
https://github.com/EpinelPS/EpinelPS.git
synced 2025-12-13 07:24:52 +01:00
Add some stuff
This commit is contained in:
@@ -46,7 +46,7 @@ namespace EpinelPS.StaticInfo
|
||||
public Dictionary<int, GachaType> gachaTypes = new Dictionary<int, GachaType>(); // Fixed initialization
|
||||
public Dictionary<int, EventManager> eventManagers = new Dictionary<int, EventManager>();
|
||||
public Dictionary<int, LiveWallpaperRecord> lwptablemgrs = new Dictionary<int, LiveWallpaperRecord>(); // Fixed initialization
|
||||
private Dictionary<int, AlbumResourceRecord> albumResourceRecords = new Dictionary<int, AlbumResourceRecord>();
|
||||
public Dictionary<int, AlbumResourceRecord> albumResourceRecords = new Dictionary<int, AlbumResourceRecord>();
|
||||
public Dictionary<int, UserFrameTableRecord> userFrameTable = new Dictionary<int, UserFrameTableRecord>();
|
||||
public Dictionary<int, ArchiveRecordManagerRecord> archiveRecordManagerTable = new Dictionary<int, ArchiveRecordManagerRecord>();
|
||||
public Dictionary<int, ArchiveEventStoryRecord> archiveEventStoryRecords = new Dictionary<int, ArchiveEventStoryRecord>();
|
||||
|
||||
@@ -7,9 +7,12 @@ namespace EpinelPS.LobbyServer.Msgs.Event
|
||||
{
|
||||
protected override async Task HandleAsync()
|
||||
{
|
||||
var req = await ReadData<ReqGetEventMissionClear>();
|
||||
|
||||
var req = await ReadData<ReqGetEventMissionClear>(); //has EventIdList
|
||||
|
||||
|
||||
var response = new ResGetEventMissionClear();
|
||||
// response.ResGetEventMissionClear.Add(new NetEventMissionClearData(EventId = 0, EventMissionId = 0 , CreatedAt = 0));
|
||||
|
||||
// TODO
|
||||
await WriteDataAsync(response);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
using EpinelPS.Database;
|
||||
using EpinelPS.Utils;
|
||||
using EpinelPS.StaticInfo; // For GameData access
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace EpinelPS.LobbyServer.Msgs.Event
|
||||
{
|
||||
@@ -8,19 +11,16 @@ namespace EpinelPS.LobbyServer.Msgs.Event
|
||||
{
|
||||
protected override async Task HandleAsync()
|
||||
{
|
||||
var req = await ReadData<ReqGetEventScenarioData>();
|
||||
var user = GetUser();
|
||||
var req = await ReadData<ReqGetEventScenarioData>();
|
||||
|
||||
// Access GameData instance
|
||||
var gameData = GameData.Instance;
|
||||
|
||||
// Create a response object
|
||||
var response = new ResGetEventScenarioData();
|
||||
if (user.EventInfo.ContainsKey(req.EventId))
|
||||
{
|
||||
var evt = user.EventInfo[req.EventId];
|
||||
response.ScenarioIdList.AddRange(evt.CompletedScenarios);
|
||||
}
|
||||
else
|
||||
{
|
||||
user.EventInfo.Add(req.EventId, new EventData());
|
||||
}
|
||||
|
||||
// Get all scenario_group_id values from albumResourceRecords starting with "event_"
|
||||
response.ScenarioIdList.Add(gameData.albumResourceRecords.Values.Where(record => record.scenario_group_id.StartsWith("event_")).Select(record => record.scenario_group_id).ToList());
|
||||
|
||||
await WriteDataAsync(response);
|
||||
}
|
||||
|
||||
@@ -62,6 +62,19 @@ namespace EpinelPS.LobbyServer.Msgs.Event
|
||||
EventSystemType = 1
|
||||
},
|
||||
JoinAt = 0
|
||||
});
|
||||
response.EventWithJoinData.Add(new NetEventWithJoinData()
|
||||
{
|
||||
EventData = new NetEventData()
|
||||
{
|
||||
Id = 70070,
|
||||
EventSystemType = 6,
|
||||
EventVisibleDate = DateTime.UtcNow.Subtract(TimeSpan.FromDays(7)).Ticks,
|
||||
EventStartDate = DateTime.UtcNow.Subtract(TimeSpan.FromDays(1)).Ticks,
|
||||
EventEndDate = DateTime.Now.AddDays(20).Ticks,
|
||||
EventDisableDate = DateTime.Now.AddDays(20).Ticks
|
||||
},
|
||||
JoinAt = 0
|
||||
});
|
||||
|
||||
await WriteDataAsync(response);
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace EpinelPS.LobbyServer.Msgs.Event.Mission
|
||||
{
|
||||
var req = await ReadData<ReqGetEventMissionClearList>();
|
||||
|
||||
var response = new ResGetEventMissionClearList();
|
||||
var response = new ResGetEventMissionClearList(); //field ResGetEventMissionClearMap data type NestEventMissionClear field NestEventMissionClear data type NetEventMissionClearData fields EventId EventMissionId CreatedAt
|
||||
|
||||
// TOOD
|
||||
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
using EpinelPS.Utils;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using EpinelPS.Database;
|
||||
|
||||
namespace EpinelPS.LobbyServer.Msgs.Event.StoryEvent
|
||||
{
|
||||
@@ -13,14 +9,22 @@ namespace EpinelPS.LobbyServer.Msgs.Event.StoryEvent
|
||||
protected override async Task HandleAsync()
|
||||
{
|
||||
var req = await ReadData<ReqStoryDungeonEventData>();
|
||||
var user = GetUser();
|
||||
var evid = req.EventId;
|
||||
var user = GetUser();
|
||||
var eventData = user.EventInfo[evid];
|
||||
var response = new ResStoryDungeonEventData();
|
||||
response.RemainTicket = 5;
|
||||
|
||||
var response = new ResStoryDungeonEventData()
|
||||
response.TeamData = new NetUserTeamData()
|
||||
{
|
||||
LastContentsTeamNumber = 1,
|
||||
Type = 20
|
||||
};
|
||||
response.LastClearedEventStageList.Add(new NetLastClearedEventStageData()
|
||||
{
|
||||
TeamData = new NetUserTeamData(),
|
||||
RemainTicket = 10,
|
||||
};
|
||||
|
||||
DifficultyId = eventData.Diff,
|
||||
StageId = eventData.LastStage
|
||||
});
|
||||
// TOOD
|
||||
|
||||
await WriteDataAsync(response);
|
||||
|
||||
Reference in New Issue
Block a user