maint: various clean up, movement tweaks, and smoothing fixes

This commit is contained in:
Chris
2025-09-29 21:10:22 -04:00
parent 535aa1797d
commit 8f3ea1a491
22 changed files with 56677 additions and 1661 deletions

View File

@@ -29,11 +29,14 @@ namespace Reset.Units {
//This is called once each time the task is enabled.
//Call EndAction() to mark the action as finished, either in success or failure.
//EndAction can be called from anywhere.
protected override void OnExecute() {
agent.SetNewDirection(newDirection.value, relativity.value, absolute.value, relativeTo.value.ToVector2());
protected override void OnExecute(){
// Vector2 outputDir = agent.transform.InverseTransformDirection(newDirection.value).ToVector2();
// outputDir = newDirection.value;
agent.SetNewDirection(newDirection.value.normalized, relativity.value, absolute.value, relativeTo.value.ToVector2());
if (setRawAsWell.value) {
agent.SetNewRawDirection(newDirection.value, relativity.value, absolute.value, relativeTo.value.ToVector2());
agent.SetNewRawDirection(newDirection.value.normalized, relativity.value, absolute.value, relativeTo.value.ToVector2());
}
EndAction(true);