Exemple #1
0
        private static void DeathDropRun(GameSession.ToSyncDropResponse message)
        {
            GameSession.ToSyncDropResponse.Types.Success success = message.Success;
            if (success != null)
            {
                DeathDrop deathDrop = success.Success_.DeathDrop;
                if (deathDrop != null)
                {
                    ///Debug.LogError("DropHandlerdeathDrop.DropList:" + deathDrop.DropList);
                    List <DropInfo> myDropList = new List <DropInfo>();
                    foreach (var item in deathDrop.DropList)
                    {
                        var dInfo = new DropInfo();
                        dInfo.PlayerUid = item.PlayerUid;
                        dInfo.ChestTid  = item.ChestTid;
                        dInfo.ShipTlv   = item.ShipTlv;
                        dInfo.Quality   = item.Quality;
                        myDropList.Add(dInfo);
                    }

                    Debug.Log($"ToSyncDropResponse:DeathDropRun->heroid = {deathDrop.HeroID} myDropList.Count = {myDropList.Count}");

                    if (myDropList != null && myDropList.Count > 0)
                    {
                        DropItemManager.Instance.SetDropItemInfoByDeath(deathDrop.HeroID, myDropList);
                    }
                }
            }
        }
Exemple #2
0
 void Start()
 {
     deathDrop = this;
 }