void SetTakeAwayTarget(DamageParam damageParam, bool bIsMonster) { if (bIsMonster) { if (damageParam.behitActor != null) { ActorObj actor = damageParam.behitActor; if (actor != null && actor.IsDeath() == false && actor.IsGod == false && actor.CanKnock == 0) { //只能被带走一次 if (actor.BeTakenAway == false) { if (!m_TakeAwayGameObjectMap.ContainsKey(actor.entityid)) { m_TakeAwayGameObjectMap.Add(actor.entityid, damageParam.behitActor.gameObject); actor.CanotCurveMove(); actor.BeTakenAway = true; actor.BeTakenAwayOwner = gameObject; //带走的时候是否不能动 if (m_param.bCanNotMoveWhenTakenAway) { actor.IgnoredGravityMotion = true; //需要打断技能 StateParameter stateParm = new StateParameter(); stateParm.state = ACTOR_STATE.AS_BEHIT; stateParm.AttackActor = actor; actor.m_AttackState.BreakSkill(stateParm); //能否切换到被击状态 actor.RequestChangeState(stateParm); actor.StopAll(); actor.PlayAction("hit011", false); } } } } } } }