private void OnDesideRepair() { App.OnlyController = key; RepairMng.StartRepair(RepairMng.GetDockIndexFromDock(repairDockModel), FocusBanner.ShipModel.MemId, use_repairkit: false); UpdateView(SingletonMonoBehaviour <AppInformation> .Instance.CurrentDeck); StrategyTopTaskManager.Instance.TileManager.UpdateAllAreaDockIcons(); if (FocusBanner.ShipModel.TaikyuRate > 50.0) { ShipUtils.PlayShipVoice(FocusBanner.ShipModel, 11); } else { ShipUtils.PlayShipVoice(FocusBanner.ShipModel, 12); } ModeProcessor.ChangeMode(0); }
public void nyukyogo(int dock, ShipModel ship, bool _isRepairKit) { Debug.Log("入渠します Dock:" + dock + " MemId:" + ship.MemId + " 高速:" + _isRepairKit + " 耐久度率:" + ship.TaikyuRate); if (_isRepairKit) { StartCoroutine(WaitAndSpeak(ship, 26, 1.5f)); } else if (ship.TaikyuRate >= 50.0) { StartCoroutine(WaitAndSpeak(ship, 11, 1.5f)); } else { StartCoroutine(WaitAndSpeak(ship, 12, 1.5f)); } _clsRepair.StartRepair(dock, ship.MemId, _isRepairKit); GameObject gameObject = GameObject.Find("board1_top/board/Grid/0" + dock.ToString()); if (_isRepairKit) { bd1.set_HS_anime(dock, stat: true); GameObject.Find("board1_top/board").GetComponent <board>().set_rnow_enable(dock, a: true); GameObject.Find("board1_top/board").GetComponent <board>().set_stk_enable(dock, a: false); dg = GameObject.Find("dialog").GetComponent <dialog>(); int num = dock; tex = GameObject.Find("board/Grid/0" + num.ToString() + "/repair_now/ship_banner").GetComponent <UITexture>(); if (ship.DamageStatus == DamageState.Taiha) { tex.mainTexture = SingletonMonoBehaviour <ResourceManager> .Instance.ShipTexture.Load(ship.MstId, 2); } else if (ship.DamageStatus == DamageState.Tyuuha) { tex.mainTexture = SingletonMonoBehaviour <ResourceManager> .Instance.ShipTexture.Load(ship.MstId, 2); } else { tex.mainTexture = SingletonMonoBehaviour <ResourceManager> .Instance.ShipTexture.Load(ship.MstId, 1); } int num2 = dock; lab = GameObject.Find("board/Grid/0" + num2.ToString() + "/repair_now/text_ship_name").GetComponent <UILabel>(); lab.text = ship.Name; int num3 = dock; lab = GameObject.Find("board/Grid/0" + num3.ToString() + "/repair_now/text_level").GetComponent <UILabel>(); lab.text = string.Empty + ship.Level; int num4 = dock; lab = GameObject.Find("board/Grid/0" + num4.ToString() + "/repair_now/text_hp").GetComponent <UILabel>(); lab.text = dg.GetBeforeHp() + "/" + ship.MaxHp; bd1.set_dock_MaxHP(dock, ship.MaxHp); int num5 = dock; sprite = GameObject.Find("board/Grid/0" + num5.ToString() + "/repair_now/HP_Gauge/panel/HP_bar_meter").GetComponent <UISprite>(); sprite.width = (int)((float)dg.GetBeforeHp() * 210f / (float)ship.MaxHp); sprite.color = Util.HpGaugeColor2(ship.MaxHp, dg.GetBeforeHp()); int num6 = dock; sprite = GameObject.Find("board/Grid/0" + num6.ToString() + "/repair_now/HP_Gauge/panel/HP_bar_meter2").GetComponent <UISprite>(); sprite.width = (int)((float)dg.GetBeforeHp() * 210f / (float)ship.MaxHp); sprite.color = Util.HpGaugeColor2(ship.MaxHp, dg.GetBeforeHp()); int num7 = dock; lab = GameObject.Find("board/Grid/0" + num7.ToString() + "/repair_now/text_least_time").GetComponent <UILabel>(); lab.text = string.Empty + ship.RepairTime; int num8 = dock; GameObject.Find("board/Grid/0" + num8.ToString() + "/repair_now/btn_high_repair").GetComponent <UIButton>().isEnabled = false; crane_anime component = GameObject.Find("board/Grid/0" + dock.ToString() + "/Anime").GetComponent <crane_anime>(); component.high_repair_anime(dock, _low_anime: false); } else { iTween.MoveTo(gameObject.gameObject, iTween.Hash("islocal", true, "x", 1000f, "time", 0.1f)); } bd2.UpdateList(); update_portframe(); SingletonMonoBehaviour <UIPortFrame> .Instance.UpdateHeaderInfo(_clsRepair); }