using System.Collections; using System.Collections.Generic; using UnityEngine; public class PlayerSitHandler : Singleton { public bool isSit { get; private set; } public Dictionary playerSitDict { get; private set; } public void ReceivePackage(H0411_tagPlayerSit vNetData) { if (playerSitDict == null) { playerSitDict = new Dictionary(); } playerSitDict[vNetData.PlayerID] = vNetData.Type; GActorPlayerBase playerBase = GAMgr.Instance.GetBySID(vNetData.PlayerID) as GActorPlayerBase; if (playerBase != null) { if (vNetData.Type == 0) { GA_Player player = playerBase as GA_Player; if (player != null) { player.StopMoveToPosition(); } playerBase.Dazuo(); } else if (vNetData.Type == 1) { playerBase.IdleImmediate(); } } } }