You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

36 lines
1.1 KiB

using System;
using GAS.Runtime;
using Sog;
namespace CoreGame.Logic
{
[Serializable]
public class TaskAddRandomCastPos : InstantAbilityTask
{
public float randomRange;
public override void OnExecute(in TaskSpec self)
{
var ctx = self.abilitySpec.ctx;
// var targetPos = GetTargetPos(ctx);
var newPos = Fixed64Vector2.right;
// ctx.castPos.Clear();
// ctx.castTarget.Clear();
// ctx.castPos.Add(newPos);
}
// private Vector2 GetTargetPos(GameAbilityContext ctx)
// {
// if (ctx.castTarget.Count > 0)
// {
// var ent = Contexts.Combat.GetEntity(ctx.castTarget[0]);
// if (ent.IsValid() && ent.hasTransformProxy)
// {
// return ent.transformProxy.position;
// }
// }
// return ctx.castPos.Count > 0
// ? ctx.castPos[0]
// : ctx.ownerEnt.transformProxy.position + ctx.ownerEnt.transformProxy.direction * 2;
// }
}
}