const BtlItemPicPath = BtlPicPath + "BtlItem/";
class BtlItemData {
    constructor(_No, _name, _Setu1, _Setu2) {
        this._No = _No; 
        this._name = _name; 
        this._Setu1 = _Setu1; 
        this._Setu2 = _Setu2; 
    }
}
let EnItemNo = {
    BaniBom: 0,     
    NuiGuard: 1,    
    Kaifuku: 2,     
    Itm301: 301,   
    Itm302: 302,   
    Itm303: 303,   
    Itm304: 304,   
    Itm305: 305,   
    Itm306: 306,   
    Itm307: 307,   
    Itm308: 308,   
    Itm309: 309,   
    Itm310: 310,   
    Itm311: 311,   
    Itm312: 312,   
    Itm313: 313,   
    Itm314: 314,   
    Itm315: 315,   
};
let btlItemDatas = [];
btlItemDatas.push(new BtlItemData(0, "★バニラちゃんボンバー",
    "全キャラのHPが1になる爆発を巻き起こす", SCol.Red + "※デバッグ用"));
btlItemDatas.push(new BtlItemData(1, "★ヌイガード",
    "ダメージを大幅カットする盾を作り出す", SCol.Red + "※デバッグ用"));
btlItemDatas.push(new BtlItemData(2, "リペアデータ",
    "体力を30回復する", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm301, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm302, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm303, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm304, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm305, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm306, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm307, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm308, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm309, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm310, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm311, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm312, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm313, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm314, "", "", ""));
btlItemDatas.push(new BtlItemData(EnItemNo.Itm315, "", "", ""));
let BtlItemCheck = function (_id) {
    if (_id < 10) return false;
    for (let i = 0; i <= btlItemDatas.length - 1; i++) {
        if (btlItemDatas[i]._No == _id) return true;
    }
    return false;
}
let BtlItem_SaveData = Game_System.prototype.initialize;
Game_System.prototype.initialize = function () { 
    BtlItem_SaveData.call(this);
    this.SetAdSys = [-1, -1, -1]; 
    this.AdSysCT = [];  
};
class AdSysCTData {
    constructor(_id , _ct){
        this.id = _id;
        this.ct = _ct;
    }
}
let btlItemSettingFlg = false;
let BtlItem_SettingUpdate = Game_Interpreter.prototype.NUpdate;
Game_Interpreter.prototype.NUpdate = function () {
    BtlItem_SettingUpdate.call(this);
    if (!btlItemSettingFlg) {
        for (let i = 0; i <= btlItemDatas.length - 1; i++) {
            if (btlItemDatas[i]._name == "") {
                btlItemDatas[i]._name = $dataItems[btlItemDatas[i]._No].name;
                let setuArr = $dataItems[btlItemDatas[i]._No].description.split("\n");
                btlItemDatas[i]._Setu1 = setuArr[0];
                if (setuArr.length > 1) btlItemDatas[i]._Setu2 = setuArr[1];
            }
        }
        btlItemSettingFlg = true;
    }
}
Game_Interpreter.prototype.BtlItemSetUp = function () {
    btlItemBtnArr = [];
    if ($gameSystem.SetAdSys == undefined) $gameSystem.SetAdSys = [-1, -1, -1];
    for (let i = 0; i <= $gameSystem.SetAdSys.length - 1; i++) {
        if ($gameSystem.SetAdSys[i] != -1) {
            if ($gameSystem.SetAdSys[i] == EnItemNo.Itm301 && !BtlData._逃走可能Flg) {
                continue;
            }
            btlItemBtnArr.push(new BtlItemBtn($gameSystem.SetAdSys[i], 1));
        }
    }
    if (!$gameSwitches.value(SW_NoDebug) && DbgFlg) { 
        if (btlItemBtnArr.length < 3) btlItemBtnArr.push(new BtlItemBtn(EnItemNo.BaniBom, 1)); 
        if (btlItemBtnArr.length < 3) btlItemBtnArr.push(new BtlItemBtn(EnItemNo.NuiGuard, 1)); 
        VaniBonUseFlg = false;  
    }
    if ($gameSwitches.value(SW_ルーザーズ敗北)) {
        btlItemBtnArr = [];
    }
}
let btlItemBtnArr = []; 
class BtlItemBtn { 
    constructor(_No, _Kaisu) {
        this._No = _No; 
        this._Kaisu = _Kaisu; 
    }
}
let GetBtlItemData = function (_No) {
    for (let i = 0; i <= btlItemDatas.length - 1; i++) {
        if (btlItemDatas[i]._No == _No) {
            return btlItemDatas[i];
        }
    }
}
let btlItemBtnPos = new Pos2D(727, 101);
const BtlItemMaxViewCount = 5; 
let btlItemPicArr = []; 
Game_Interpreter.prototype.BtlItemBtnDraw = function () {
    btlItemPicArr = [];
    if (TutorialDgn管理No > 0) {
        for (let i = 0; i < btlItemBtnArr.length; i++) {
            if (btlItemBtnArr[i]._No == 302) {
                btlItemBtnArr.splice(i , 1);
            }
        }
    }
    for (let i = 0; i <= BtlItemMaxViewCount - 1; i++) {
        this.DelSprite(PN_BtlItemBtn + i);
        this.DelSprite(PN_BtlItemCnt + i);
    }
    if (this.ゴブリン称号装備確認()) return; 
    for (let i = 0; i <= btlItemBtnArr.length - 1; i++) {
        this.SetSpriteC(PN_BtlItemBtn + i, BtlItemPicPath + "Btn_AdSys" + btlItemBtnArr[i]._No,
            btlItemBtnPos._x - (i * 110), btlItemBtnPos._y, 255, 80, 80);
        for (let j = 0; j < $gameSystem.AdSysCT.length; j++) {
            if ($gameSystem.AdSysCT[j].id == btlItemBtnArr[i]._No && $gameSystem.AdSysCT[j].ct > 0) {
                this.SetSpriteCellC(PN_BtlItemCnt + i, BtlItemPicPath + "Btn_AdSysNo", 10,
                    $gameSystem.AdSysCT[j].ct, btlItemBtnPos._x - (i * 110), btlItemBtnPos._y,
                    255, 80, 80);
            }
        }
        btlItemPicArr.push(PN_BtlItemBtn + i);
    }
}
Game_Interpreter.prototype.AdSysCt_CountDown = function (_cnt) {
    _cnt = typeof _cnt !== 'undefined' ? _cnt : 1;
    for (let i = 0; i < $gameSystem.AdSysCT.length; i++) {
        if ($gameSystem.AdSysCT[i].ct > 0)
            $gameSystem.AdSysCT[i].ct -= _cnt;
    }
    this.BtlItemBtnDraw();
}
let btlItem_SetuDrawFlg = false;
class BtlItemBtn_Data {
    constructor(_No, _SpDataArr) {
        this._No = _No;
        this._SpDataArr = _SpDataArr;
    }
}
let btlItemBtn_DataArr = [];    
let btlItemUseItemCnt = [];     
Game_Interpreter.prototype.BtlItemBtnUpdate = function () {
    if (LastEffectUISelectUpdate) return;
    if (!IsPlayerSelect) return;
    if (BtlActiveTouchUIUpdateOff) return;
    let overNo = overPointerSpCkArr(btlItemPicArr);
    for (let i = 0; i <= btlItemPicArr.length - 1; i++) this.SpriteCngColor(btlItemPicArr[i]);
    if (overNo != -1 && BtlData.Mode == EnBtlMode.CardSelect) {
        let ckNo = overNo - PN_BtlItemBtn;
        if (btlItemBtnArr[ckNo] == undefined) return;
        let _DNo = btlItemBtnArr[ckNo]._No; 
        this.SpriteCngColor(overNo, [50, 50, 50, 0]);
        if (GetSpriteData(PN_BtlItemTxt + 0) != null &&
            GetSpriteData(PN_BtlItemTxt + 1) != null &&
            GetSpriteData(PN_BtlItemTxt + 2) != null) {
            let _SaveDtArr = [];
            _SaveDtArr.push(GetSpriteData(PN_BtlItemTxt + 0));
            _SaveDtArr.push(GetSpriteData(PN_BtlItemTxt + 1));
            _SaveDtArr.push(GetSpriteData(PN_BtlItemTxt + 2));
            this.SetBtlItemBtnArr(_DNo, _SaveDtArr);
        }
        let _noSelectFlg = false;
        for (let i = 0; i < $gameSystem.AdSysCT.length; i++) {
            if ($gameSystem.AdSysCT[i].ct > 0 && _DNo == $gameSystem.AdSysCT[i].id)
                _noSelectFlg = true;
        }
        if (TouchInput.isTriggered() && !_noSelectFlg) {
            btlItemUseItemCnt.push(btlItemBtnArr[ckNo]._No);
            this.BtlItemBtnUse(btlItemBtnArr[ckNo]._No); 
            if (!this.IsPlayerメタル化()) this.SetSpineAnime(PN_CharacterPL, "Item", false);
            if (!this.IsPlayerメタル化()) this.AddSpineAnime(PN_CharacterPL,"Idl",true,0,100);
            this.BtlItemBtnDraw();
        }
        if (!btlItem_SetuDrawFlg) {
            let _AdWinPos = new Pos2D(btlItemBtnPos._x - (ckNo * 110), btlItemBtnPos._y + 90); 
            this.SetSpriteC(PN_BtlItemWin, BtlPicPath + "Setu_FreeWin", _AdWinPos._x, _AdWinPos._y);
            D_Text_Cng_font = "Makinas"; 
            btlItem_SetuDrawFlg = true;
            for (let j = 0; j <= btlItemDatas.length - 1; j++) {
                if (_DNo == btlItemDatas[j]._No) {
                    var viewStr = btlItemDatas[j]._name;
                    var memo = MetaChecker($dataItems[_DNo] , "CT" , false);
                    if (memo != false) {
                        viewStr += "：クールタイム" + memo;
                    }
                    this.SpriteStr(PN_BtlItemTxt + 0, viewStr, 20, _AdWinPos._x - 200, _AdWinPos._y - 40);
                    this.SpriteStr(PN_BtlItemTxt + 1, btlItemDatas[j]._Setu1, 18, _AdWinPos._x - 200, _AdWinPos._y - 15);
                    this.SpriteStr(PN_BtlItemTxt + 2, btlItemDatas[j]._Setu2, 18, _AdWinPos._x - 200, _AdWinPos._y + 10);
                    break;
                }
            }
            D_Text_Cng_font = ""; 
        }
    } else {
        btlItem_SetuDrawFlg = false;
        Alpha0SpriteArr([PN_BtlItemWin, PN_BtlItemTxt + 0, PN_BtlItemTxt + 1, PN_BtlItemTxt + 2]);
    }
}
Game_Interpreter.prototype.SetBtlItemBtnArr = function (_No, _SaveArr) {
    for (let i = 0; i <= btlItemBtn_DataArr.length - 1; i++) {
        if (btlItemBtn_DataArr[i]._No == _No) {
            return;
        }
    }
    let _SetAdData = new BtlItemBtn_Data(_No, _SaveArr);
    btlItemBtn_DataArr.push(_SetAdData);
}
Game_Interpreter.prototype.BtlItemAdd = function (_No, _Count) {
    for (let i = 0; i <= btlItemBtnArr.length - 1; i++) {
        if (btlItemBtnArr[i]._No == _No) {
            if (btlItemBtnArr[i]._Kaisu == 9) return; 
            btlItemBtnArr[i]._Kaisu += _Count; 
            return;
        }
    }
    btlItemBtnArr.push(new BtlItemBtn(_No, _Count)); 
}
let GetBtlItemCoolTime = function (_SysNo) {
    for (let i = 0; i <= $gameSystem.AdSysCT.length - 1; i++) {
        if ($gameSystem.AdSysCT[i].id == _SysNo) {
            $gameSystem.AdSysCT[i].ct = ctValue;
        }
    }
}
let VaniBonUseFlg = false; 
Game_Interpreter.prototype.BtlItemBtnUse = function (_SysNo) {
    switch (_SysNo) {
        case EnItemNo.BaniBom:
        case EnItemNo.NuiGuard:
        case EnItemNo.Kaifuku:
            break;
        default:
            let ctValue = Number(MetaChecker($dataItems[_SysNo] , "CT" , "0"));
            let _addFlg = true;
            for (let i = 0; i <= $gameSystem.AdSysCT.length - 1; i++) {
                if ($gameSystem.AdSysCT[i].id == _SysNo) {
                    $gameSystem.AdSysCT[i].ct = ctValue;
                    _addFlg = false;
                }
            }
            if (_addFlg) $gameSystem.AdSysCT.push(new AdSysCTData(_SysNo , ctValue));
            break;
    }
    let _AnimeId = 0;
    switch (_SysNo) {
        case EnItemNo.BaniBom:     
            this.BLogAdd(180, "バニラちゃんボンバー発動！！！！");
            VaniBonUseFlg = true;
            BtlItemFlame = 30;    
            for (let i = 0; i <= NPlayer.length - 1; i++) {
                NPlayer[i]._hp = 1; 
            }
            for (let i = 0; i <= NEnemy.length - 1; i++) {
                if (NEnemy[i]._hp > 0) {
                    NEnemy[i]._hp = 1;
                }
            }
            _AnimeId = 3;       
            this.PlayAnime(_AnimeId, NPlayer[0]._screenX, NPlayer[0]._screenY);
            this.PlayAnimeEnemyAll(_AnimeId);
            this.BtlLive2DParamSet_State(); 
            break;
        case EnItemNo.NuiGuard:    
            this.BLogAdd(180, "ヌイガーーーーード！！！");
            BtlItemFlame = 30;    
            this.PlayAnime(GardAnimeId, NPlayer[0]._screenX, NPlayer[0]._screenY);
            StateAddPlayerFlg = true;
            AddNState(NPlayer[0]._NState, 15, 99); 
            $gameActors.actor(1).addState(15);
            break;
        case EnItemNo.Itm301: 
            this.PlayPtcPic("Jenimi", NPlayer[0]._screenX, NPlayer[0]._screenY);
            this.MovePict(PN_CharacterPL, true, true, 30, 0, plSpineScaleX, plSpineScaleY);
            L2dAutoFadeOut(MdlRomashaBattle, 15);
            BtlEndLive2D_FadeOut();
            BtlEscapeFlg = true;
            this.ChangePhase_EndBtl();
            _PLステート解除(En_StNo.ジャミング);
            _PLステート解除(En_StNo.ジャミング_2);
            break;
        case EnItemNo.Itm302: 
            NPlayer[0]._hp = 1; 
            this.SetBtlItemState("PowUp_2" , -1 , 27,2);
            this.SetBtlItemState("PowUp_2" , -1 , 54,2);
            break;
        case EnItemNo.Itm303: 
            let rp303Value = Math.round(NPlayer[0].mhp * 0.1);
            this.EffectBtlItem回復("リペアキットを使用！" , rp303Value);
            break;
        case EnItemNo.Itm304: 
            let rp304Value = Math.round(NPlayer[0].mhp * 0.2);
            this.EffectBtlItem回復("リペアキット改を使用！" , rp304Value);
            break;
        case EnItemNo.Itm305: 
            this.SetBtlItemState("PowUp_2" , -1 , 78,5);
            break;
        case EnItemNo.Itm306: 
            this.MPKaihuku(2);
            BtlItemFlame = 30;    
            this.PlayPtcPic("PowUp_3", NPlayer[0]._screenX, NPlayer[0]._screenY);
            break;
        case EnItemNo.Itm307: 
            this.SetBtlItemState("PowUp_2" , -1 , 27,1);
            break;
        case EnItemNo.Itm308: 
            this.SetBtlItemState("Dfence" , -1 , 200,1);
            break;
        case EnItemNo.Itm309: 
            this.SetBtlItemState("Dfence" , -1 , 87,3);
            break;
        case EnItemNo.Itm310: 
            this.NPtcComboSet("DrowKEff", Ptc_CType.Pic, [NPlayer[0]._screenX, NPlayer[0]._screenY]);
            for (let i = 0; i <= 2 - 1; i++) {
                if (CardData.length < BtlStatic._手札最大枚数) { 
                    AddCardDrawStac();
                }
            }
            this.HandCardPicSort(-1); 
            this.CardDrawMove(); 
            break;
        case EnItemNo.Itm311: 
                for (let i = 0; i <= NEnemy.length - 1; i++) { 
                    if (NEnemy[i]._hp > 0) this.TCShift_ENo(i, 1, 999);
                }
                this.PlayPtcPic("ClockWise", NPlayer[0]._screenX, NPlayer[0]._screenY);
            break;
        case EnItemNo.Itm312: 
            this.PlayPtcPic("CostDown", NPlayer[0]._screenX, NPlayer[0]._screenY);
            this.HandCardCost_Change(-1);
            this.CardDrawMove();
            break
        case EnItemNo.Itm313: //リセットウェポン：敵全体クリア効果(バフ消し)
            EnforceCardUseNo = 633; 
            EnforceCostZeroFlg = true; 
            break;
        case EnItemNo.Itm314: 
            wait_TurnEndBtnUIUpdate = 15;
            this.PlayPtcPic("Reload", NPlayer[0]._screenX, NPlayer[0]._screenY);
            this.AllCardTrash_Move();
            let drawCount = CardData.length;
            for (let j = 0; j <= CardData.length - 1; j++) {
                CardData.splice(j, 1); j--;
            }
            SetEnemyDmgStac(DType.Draw, -1, 1, drawCount);
            break;
        case EnItemNo.Kaifuku:
            this.BtlItem回復(_SysNo);
            break;
        //     let _距離順Arr = GetTargetArr_Enemy距離();
        //     this.PlayAnime(_AnimeId, NEnemy[_単対象No]._screenX, NEnemy[_単対象No]._screenY - 64);
    }
}
Game_Interpreter.prototype.SetBtlItemState = function (_パーティクル名 , _対象ENo , _ステートId , _付与ターン) {
    this.AddState_ENo(_対象ENo, _ステートId, _付与ターン); 
    BtlItemFlame = 30; 
    this.PlayPtcPic(_パーティクル名, NPlayer[0]._screenX, NPlayer[0]._screenY); 
}
Game_Interpreter.prototype.BtlItemステート付与 = function (_SysNo) {
    let _setPtcStr = "";
    switch (_SysNo) {
        case EnItemNo.Itm305: 
            _setPtcStr = "PowUp_2";
            this.AddState_ENo(-1, 32, 3);
            break;
        case EnItemNo.Itm302: 
            _setPtcStr = "PowUp_2";
            this.AddState_ENo(-1, 32, 3);
            break;
        case EnItemNo.Itm303:
            _setPtcStr = "FullAtack";
            this.AddState_ENo(-1, 90, 1);
            this.AddState_ENo(-1, 100, 1);
            NPlayer[0]._hp = 1;
            break;
        case EnItemNo.Itm304:
            _setPtcStr = "Dfence";
            this.AddState_ENo(-1, 33, 5);
            break;
        case EnItemNo.Itm305:
            _setPtcStr = "Dfence";
            this.AddState_ENo(-1, 2, 30);
            break;
        case EnItemNo.Itm308:
            _setPtcStr = "Kihuku_Eff_4";
            this.AddState_ENo(-1, 25, 4);
            break;
        case EnItemNo.Itm314:
            _setPtcStr = "FormationA";
            this.AddState_ENo(-1, 86, 10);
            break;
    }
}
Game_Interpreter.prototype.EffectBtlItem回復 = function (_ログ表示1 , _回復点数) {
    this.BLogAdd(180, _ログ表示1);
    BtlItemFlame = 30;    
    _AnimeId = 41;      
    this.PlayPtcPic("Kaihuku_Eff", NPlayer[0]._screenX, NPlayer[0]._screenY);
    SetEnemyDmgStac(DType.HpRecv, -1, 0, _回復点数);  
}
Game_Interpreter.prototype.BtlItem回復 = function (_SysNo) {
    switch (_SysNo) {
        case EnItemNo.Kaifuku:
            this.BLogAdd(180, "リペアデータを使用！");
            break;
        case EnItemNo.Itm306:
            this.BLogAdd(180, "リペアキットを使用！");
            break;
        case EnItemNo.Itm307:
            this.BLogAdd(180, "リペアキット改を使用！");
            break;
    }
    BtlItemFlame = 30;    
    _AnimeId = 41;      
    this.PlayPtcPic("Kaihuku_Eff", NPlayer[0]._screenX, NPlayer[0]._screenY);
    let _Rp = 30;
    NPlayer[0]._hp += _Rp;
    if (NPlayer[0].mhp <= NPlayer[0]._hp) {
        _Rp -= NPlayer[0]._hp - NPlayer[0].mhp;
        NPlayer[0]._hp = NPlayer[0].mhp;
    }
    if (_Rp > 0) {
        this.BLogAdd(180, SCol.Grn + "ロマーシャは" + _Rp + "回復した。");
    }
}
let BtlItemFlame = -1; 
Game_Interpreter.prototype.BtlItemUseUpdate = function () {
    if (BtlItemFlame >= 0) {
        BtlItemFlame--;
        return true;
    }
    return false;
}
class SkillLog { 
    constructor(_SkillStr, _PictNo, _WinNo) {
        _WinNo = typeof _WinNo !== 'undefined' ? _WinNo : 1;
        this._SkillStr = _SkillStr; 
        this._WinNo = _WinNo; 
        this._PictNo = _PictNo; 
        this._LFlame = [0, 0, 0]; 
    }
}
let SViewNo = 0;    
let Skill_Log = []; 
let SLPos = new Pos2D(628, 183); 
Game_Interpreter.prototype.SkillLogUpdate = function () {
    for (let i = 0; i <= Skill_Log.length - 1; i++) {
        Skill_Log[i]._LFlame[i]++; 
        let _FlmCk = 0;
        for (let j = 0; j <= Skill_Log[i]._LFlame.length - 1; j++) {
            _FlmCk += Skill_Log[i]._LFlame[j];
        }
        let _PlPNo = PN_UseSWaku + Skill_Log[i]._PictNo; 
        let _PlStrPNo = PN_UseSTxt + Skill_Log[i]._PictNo; 
        if (_FlmCk < 60) {
            switch (i) {
                case 0:
                    if (Skill_Log[i]._LFlame[i] == 1) {
                        this.SetSpriteC(_PlPNo, BtlPicPath + "PN_UseWaku" + Skill_Log[i]._WinNo,
                            SLPos._x, SLPos._y + 20, 0);
                        this.MoveSprite(_PlPNo, SLPos._x, SLPos._y, 10);
                        this.SpriteStrC(_PlStrPNo, Skill_Log[i]._SkillStr, 25,
                            SLPos._x, SLPos._y + 20, 0);
                        this.MoveSprite(_PlStrPNo, SLPos._x, SLPos._y, 10);
                    }
                    break;
                case 1:
                    if (Skill_Log[i]._LFlame[i] == 1) { 
                        this.MoveSprite(_PlPNo, SLPos._x, SLPos._y - 52, 10, 150);
                        this.MoveSprite(_PlStrPNo, SLPos._x, SLPos._y - 52, 10, 150);
                    }
                    break;
                case 2:
                    if (Skill_Log[i]._LFlame[i] == 1) { 
                        this.MoveSprite(_PlPNo, true, true, 10, 0);
                        this.MoveSprite(_PlStrPNo, true, true, 10, 0);
                    }
                    break;
            }
        }
        if (_FlmCk == 60) {
            this.MoveSprite(_PlPNo, true, true, 10, 0);
            this.MoveSprite(_PlStrPNo, true, true, 10, 0);
        }
        if (_FlmCk == 70) {
            Skill_Log.pop();
        }
    }
}
Game_Interpreter.prototype.SkillLogAdd = function (_SetStr, _WinNo) {
    _WinNo = typeof _WinNo !== 'undefined' ? _WinNo : 1;
    if (_SetStr == "") return; 
    SViewNo++;
    if (SViewNo == 3) SViewNo = 0; 
    Skill_Log.unshift(new SkillLog(_SetStr, SViewNo, _WinNo)); 
    if (Skill_Log.length >= 3) Skill_Log.pop();
}
