mirror of
https://github.com/rafi1212122/PemukulPaku
synced 2025-12-12 19:24:34 +01:00
* Deleted TestCommand.cs No longer needed. * Update AbyssCommand.cs Added a command to adjust the player's bracket at will. * Update User.cs Added Abyss Group Value * Update Command.cs Added Examples[] to the constructor and handler. * Update HelpCommand.cs Made the Help command more helpful! * Update AbyssCommand.cs Added Help Examples * Update GiveCommand.cs Added help examples, handles negative inputs again, added more aliases, can add or remove materials by ID, can now for add all skipped characters with `give avatars-scuffed` * Update AbyssCommand.cs missed a quote * Update UltraEndlessGetMainDataReqHandler.cs Bracket can now be set with commands. Need to unscuff the fight cycle. * Update GiveCommand.cs Cheeky give gold command * Further refined the Help Command --------- Co-authored-by: TerminalAide0017 <Sucks@code>
47 lines
1.9 KiB
C#
47 lines
1.9 KiB
C#
using Common;
|
|
using Common.Resources.Proto;
|
|
using Common.Utils.ExcelReader;
|
|
|
|
namespace PemukulPaku.GameServer.Handlers
|
|
{
|
|
[PacketCmdId(CmdId.UltraEndlessGetMainDataReq)]
|
|
internal class UltraEndlessGetMainDataReqHandler : IPacketHandler
|
|
{
|
|
|
|
public void Handle(Session session, Packet packet)
|
|
{
|
|
uint bracket = session.Player.User.AbyssGroupLevel;
|
|
uint temp = session.Player.User.AbyssDynamicHard;
|
|
UltraEndlessGetMainDataRsp Rsp = new()
|
|
{
|
|
retcode = UltraEndlessGetMainDataRsp.Retcode.Succ,
|
|
ScheduleId = 1028,
|
|
GroupLevel = bracket,
|
|
TopGroupLevel = 9,
|
|
CupNum = 2000,
|
|
MainData = new()
|
|
{
|
|
ScheduleId = 1028,
|
|
EffectTime = 0,
|
|
BeginTime = 0,
|
|
EndTime = (uint)Global.GetUnixInSeconds() + 3600 * 24 * 7,
|
|
CloseTime = (uint)Global.GetUnixInSeconds() + 3600 * 24 * 7 + 1200,
|
|
CurSeasonId = 1
|
|
},
|
|
DynamicHardLevel = temp,
|
|
LastSettleInfo = new() { }
|
|
};
|
|
Rsp.MainData.SiteLists.AddRange(Common.Utils.ExcelReader.UltraEndlessSite.GetInstance().All.Where(x => x.SiteId > 1019).Select(siteData =>
|
|
{
|
|
List<UltraEndlessFloorExcel> floorDatas = Common.Utils.ExcelReader.UltraEndlessFloor.GetInstance().GetFloorDatasFromStageId(siteData.StageId);
|
|
var siteInfo = new Common.Resources.Proto.UltraEndlessSite() { SiteId = (uint)siteData.SiteId };
|
|
siteInfo.FloorLists.AddRange(floorDatas.Select(x => new Common.Resources.Proto.UltraEndlessFloor() { Floor = (uint)x.FloorId, MaxScore = 0 }));
|
|
|
|
return siteInfo;
|
|
}));
|
|
|
|
session.Send(Packet.FromProto(Rsp, CmdId.UltraEndlessGetMainDataRsp));
|
|
}
|
|
}
|
|
}
|