You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.1 KiB
39 lines
1.1 KiB
1 month ago
|
using Sog;
|
||
|
using ProtoCSStruct;
|
||
|
|
||
|
namespace Battle
|
||
|
{
|
||
|
internal static class BattleCreateSvc
|
||
|
{
|
||
|
public static void StartBattle(BattleObj battle)
|
||
|
{
|
||
|
TraceLog.Trace("BattleCreateSvc.StartBattle battleId {0}", battle.battleInfo.BattleId);
|
||
|
|
||
|
|
||
|
}
|
||
|
|
||
|
|
||
|
|
||
|
public static void DeleteAllPlayerInBattle(BattleObj battle)
|
||
|
{
|
||
|
// foreach (var player in battle.playerList)
|
||
|
// {
|
||
|
// BattleServerUtils.GetPlayerTableOp().RemovePlayer(player);
|
||
|
// }
|
||
|
}
|
||
|
|
||
|
public static void OnBattleDestroy(BattleObj battle)
|
||
|
{
|
||
|
TraceLog.Trace("BattleCreateSvc.OnBattleDestroy battleId {0} destroy", battle.BattleId);
|
||
|
|
||
|
SSBattleDestroyNotify notify = new SSBattleDestroyNotify();
|
||
|
notify.BattleId = battle.BattleId;
|
||
|
|
||
|
//BattleServerUtils.GetPacketSender().SendToInstanceServer((int)SSGameMsgID.BattleDestroyNotify, ref notify, 0);
|
||
|
|
||
|
DeleteAllPlayerInBattle(battle);
|
||
|
|
||
|
BattleMatchNotify.NotifyAllPlayerCancelBattle(battle);
|
||
|
}
|
||
|
}
|
||
|
}
|