public bool AdjustMovePosByCollision(Nr3DCharBase kChar, ref Vector2 vMovePos, bool bAlly) { if (Battle.BATTLE.m_bOnlyServerMove) { return(false); } if (kChar.GetCharController() == null) { return(false); } Vector2 b = Vector2.zero; bool result = false; for (int i = 1; i < 120; i++) { NkBattleChar nkBattleChar = this.m_arChar[i]; if (nkBattleChar != null) { Nr3DCharBase nr3DCharBase = nkBattleChar.Get3DChar(); if (!(nr3DCharBase.GetCharController() == null)) { if (nr3DCharBase.GetID() != kChar.GetID()) { if (bAlly || nr3DCharBase.GetParentBattleChar().Ally != kChar.GetParentBattleChar().Ally) { b = vMovePos - new Vector2(nr3DCharBase.GetParentBattleChar().GetCharPos().x, nr3DCharBase.GetParentBattleChar().GetCharPos().z); float num = Vector2.Distance(Vector2.zero, b); float num2 = kChar.GetParentBattleChar().GetCharHalfBound() + nr3DCharBase.GetParentBattleChar().GetCharHalfBound() - num; if (num2 >= 0f) { this.GetTurningPos(kChar, nr3DCharBase, ref vMovePos); result = true; } } } } } } return(result); }
public bool Destroy3DChar(Nr3DCharBase k3DCharInst) { return(this.Destroy3DChar(k3DCharInst.GetID())); }