public Vector3 GetBone(BoneAnchorType bone_type) { switch (bone_type) { case BoneAnchorType.None: return(this.self.mTransform.position); case BoneAnchorType.Center: return(this.self.mTransform.position + new Vector3(0f, this.GetHeight() / 2f, 0f)); case BoneAnchorType.Top: return(this.self.mTransform.position + new Vector3(0f, this.GetHeight(), 0f)); case BoneAnchorType.FootStep: case BoneAnchorType.Chest: case BoneAnchorType.Head: case BoneAnchorType.LeftHand: case BoneAnchorType.RightHand: case BoneAnchorType.Weapon: case BoneAnchorType.LeftFoot: case BoneAnchorType.RightFoot: case BoneAnchorType.LeftForearm: case BoneAnchorType.RightForearm: case BoneAnchorType.Spine: case BoneAnchorType.Neck: case BoneAnchorType.Weapon2: case BoneAnchorType.Duang: if (this.self.bones != null && bone_type < (BoneAnchorType)this.self.bones.Length && this.self.bones[(int)bone_type] != null) { return(this.self.bones[(int)bone_type].position); } break; } return(Vector3.zero); }
protected override bool doAction() { base.CreateNode(NodeType.SkillNode, this.performId); this.mLinkType = (LinkType)this.data.effectParam1; this.mBoneType = (BoneAnchorType)this.data.effectParam2; this.effect_time = this.data.config.effect_time + this.data.config.effect_delay; this.AddAction(ActionManager.PlayAnim(this.performId, base.unit, true)); string arg_A5_0 = this.performId; Units arg_A5_1 = base.unit; Vector3?vector = this.targetPosition; this.effectAction = ActionManager.PlayEffect(arg_A5_0, arg_A5_1, new Vector3?(vector.Value), null, true, string.Empty, this.CasterUnit); this.AddAction(this.effectAction); if (this.useCollider) { } this.isActive = true; base.mCoroutineManager.StartCoroutine(this.Link_Coroutine(this.targetUnits), true); return(true); }
protected override bool doAction() { base.CreateNode(NodeType.SkillNode, this.performId); this.AddAction(ActionManager.PlayAnim(this.performId, base.unit, true)); string arg_5A_0 = this.performId; Units arg_5A_1 = base.unit; Vector3?vector = this.targetPosition; this.effectAction = ActionManager.PlayEffect(arg_5A_0, arg_5A_1, new Vector3?(vector.Value), null, true, string.Empty, this.CasterUnit); string arg_98_0 = "TufuS1_1"; Units arg_98_1 = base.unit; Vector3?vector2 = this.targetPosition; this.HookObj = ActionManager.PlayEffect(arg_98_0, arg_98_1, new Vector3?(vector2.Value), null, true, string.Empty, this.CasterUnit); this.SetPosition(); this.sourcePosition = base.unit.trans.position; this.cacheTran = base.transform; this.AddAction(this.effectAction); this.AddAction(this.HookObj); this.ResetLineRender(); this.isActive = true; this.isHookMan = false; this.isForward = true; this.skill = base.unit.getSkillOrAttackById(this.skillData.skillId); Skill expr_11F = this.skill; expr_11F.OnTargetHitCallback = (Callback <List <Units> >)Delegate.Combine(expr_11F.OnTargetHitCallback, new Callback <List <Units> >(this.OnTargetHit)); this.mBoneType = (BoneAnchorType)this.data.effectParam1; this.flyDistance = this.data.effectParam2; this.minSpeed = this.data.config.effect_speed / 2f; Skill expr_185 = this.skill; expr_185.DestroyAction = (Callback <string, int>)Delegate.Combine(expr_185.DestroyAction, new Callback <string, int>(this.ExternDestroy)); this.hookBackDelay = 0f; base.mCoroutineManager.StartCoroutine(this.Link_Coroutine(), true); return(true); }
public override void Start(string performID, EditorUnit unit, List <EditorUnit> targets, Vector3?pos, EditorSkill skill) { base.Start(performID, unit, targets, pos, skill); this.mLinkType = (LinkType)this.data.effectParam1; this.mBoneType = (BoneAnchorType)this.data.effectParam2; }