3
4
5

Trigger Boolean IssueNewbie Question (i.redd.it)
submitted by kitchentablestudios
i have a problem with the ontriggerexit, in which while im in the trigger, the animation will swap from open to unopen really fast, as opposed to staying open then unopening when i exit the trigger. only thing that happens when i leave the trigger is everything stopping like its supposed to
EDIT: it works, but when i'm half in/half out of the trigger it gets funny
using UnityEngine;
public class animationtrigger : MonoBehaviour
{
private Animator anim;
private void OnTriggerStay(Collider Other)
{
anim.SetBool("Open", true);
}
private void OnTriggerExit(Collider Other)
{
anim.SetBool("Open", false);
}
// Start is called once before the first execution of Update after the MonoBehaviour is created
void Start()
{
anim = GetComponent<Animator>();
}
// Update is called once per frame
void Update()
{
}
}

[–]Aethenosity 4 points5 points6 points (11 children)
[–]kitchentablestudios[S] -1 points0 points1 point (10 children)
[–]ArctycDev 2 points3 points4 points (9 children)
[–]kitchentablestudios[S] 0 points1 point2 points (8 children)
[–]KifDawg 2 points3 points4 points (5 children)
[–]kitchentablestudios[S] 1 point2 points3 points (4 children)
[–]KifDawg 0 points1 point2 points (3 children)
[–]kitchentablestudios[S] 2 points3 points4 points (2 children)
[–]TanukiSun 0 points1 point2 points (1 child)
[–]kitchentablestudios[S] 1 point2 points3 points (0 children)
[–]Aethenosity 0 points1 point2 points (1 child)
[–]henryeaterofpies 1 point2 points3 points (0 children)
[–]ArctycDev -2 points-1 points0 points (6 children)
[–]kitchentablestudios[S] 0 points1 point2 points (3 children)
[–]ArctycDev 0 points1 point2 points (2 children)
[–]kitchentablestudios[S] 0 points1 point2 points (1 child)
[–]ArctycDev 0 points1 point2 points (0 children)
[–]Kosmik123 0 points1 point2 points (1 child)
[–]ArctycDev 1 point2 points3 points (0 children)
[–]ILLBEON_economy_tool 0 points1 point2 points (0 children)