少年修仙传客户端代码仓库
client_Wu Xijin
2018-09-17 31720f586ec3b23d713201506b288b88bae592da
Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
2个文件已修改
28 ■■■■■ 已修改文件
System/PlayerDead/PlayerDeadModel.cs 19 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/PlayerDead/RebornWin.cs 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
System/PlayerDead/PlayerDeadModel.cs
@@ -4,6 +4,7 @@
using UnityEngine;
using System.Collections.Generic;
using System.Collections;
using System.Text;
public class PlayerDeadModel : Model, IBeforePlayerDataInitialize,IPlayerLoginOk
{
@@ -21,6 +22,7 @@
    public void OnBeforePlayerDataInitialize()
    {
        npcRealmLv = 0;
        IsCanReborn = false;
        isOpenPrompting = true;
        this.deadCD = 0;
@@ -82,9 +84,10 @@
    public int localBossState { get; private set;}
    public string killerName { get; private set; }
    public bool isKillByPlayer { get; private set; }
    public int npcRealmLv { get; private set; }
    private void RefreshPlayerDieInfo(string key, ArrayList infolist)
    {
        npcRealmLv = 0;
        switch(key)
        {
            case "PK_lhs_318691":
@@ -101,6 +104,7 @@
                    if(nPCConfig != null)
                    {
                        killerName = nPCConfig.charName;
                        npcRealmLv = nPCConfig.Realm;
                    }
                    isKillByPlayer = false;
                }
@@ -108,6 +112,19 @@
        }
    }
    public bool CheckIsRealmSuppress(out StringBuilder builder)
    {
        builder = new StringBuilder();
        if(npcRealmLv > PlayerDatas.Instance.baseData.realmLevel)
        {
            var curRealmConfig = Config.Instance.Get<RealmConfig>(npcRealmLv);
            builder.AppendFormat("<Img img={0}/>", curRealmConfig.Img);
            return true;
        }
        return false;
    }
    private void AddlistenPlayerHP(PlayerDataRefresh type, int value)
    {
        if (type != PlayerDataRefresh.HP || value > 0 || playerIsDie) return;
System/PlayerDead/RebornWin.cs
@@ -6,6 +6,7 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Text;
using UnityEngine;
using UnityEngine.Events;
using UnityEngine.UI;
@@ -123,7 +124,15 @@
        private void OnHideBtnlist()
        {
            _btnlist.SetActive(false);
            StringBuilder builder;
            if(DeadModel.CheckIsRealmSuppress(out builder))
            {
                _rebornWorldText.text = Language.Get("PlayerReborn106",builder.ToString());
            }
            else
            {
            _rebornWorldText.text = Language.Get("PlayerReborn104");
            }
            _timeDownText.gameObject.SetActive(true);
        }
        private void RefreshAutoRebornTime(float obj)