public string GetProcessedMediaPath(TimeSpan startTime, TimeSpan endTime) { IEffect effect = new CutEffect(startTime, endTime); effect.SetDataSource(this.StoryBoard.Guid, this.StoryBoard.MediaSource.SourcePath); effect.Excute(); this.StoryBoard.AddEffect(effect); return(effect.OutputPath); }
public static CutEffect Create(GameObject target) { // CombatText.Create(Vector2.zero, "TEST"); Transform cutPositionTransform = Instantiate(GameAssets.i.cutEffect, target.transform.position, Quaternion.identity); CutEffect cutPosition = cutPositionTransform.GetComponent <CutEffect>(); cutPosition.Setup(target); return(cutPosition); }
public override bool Cast() { bool wasCast = false; effectAlpha = 1f; Vector2 playerPosition = player.GetComponent <Rigidbody2D>().position; GameObject target = player.GetComponent <TargetingController>().target; Vector2 targetPosition = target.transform.position; if (Vector2.Distance(playerPosition, targetPosition) <= range) { CutEffect.Create(target); } wasCast = true; Debug.Log("Cast CutAttack"); return(wasCast); }