Page 1 of 1

2 questions about using the Menu System

Posted: Sat Feb 26, 2022 12:16 am
by xemanon
Hi! I'm currently testing out the Menu System framework and incorporating it into my project. I ran into two questions - one is a weird bug I can't figure out.

1. When using a button to open or close the Menu (eg. Esc), a sort of "popping" animation plays. Is there a way to disable this, or to change it to a fade in/out animation for example?

2. I am also using Cinemachine, and starting a new scene from the Main Menu appears to teleport the player some distance horizontally on the x-axis. I tried this without the Main Menu framework (using a basic system of my own instead) and this did not occur. I did however notice that Cinemachine would be set to "None" for ~1 second before turning to the live cam, but still, the slight teleportation only happened using the framework. Do you have any inklings why this might be? This might be a fault of my own, but I'm not sure.
Edit for #2: I've found this only occurs when loading a previously saved scene. This is a gif of it happening for context

Re: 2 questions about using the Menu System

Posted: Sat Feb 26, 2022 9:42 am
by Tony Li
Hi,
xemanon wrote: Sat Feb 26, 2022 12:16 am1. When using a button to open or close the Menu (eg. Esc), a sort of "popping" animation plays. Is there a way to disable this, or to change it to a fade in/out animation for example?
Yes. The Menu System prefab's PausePanel has an Animator component. It also has a UIPanel component with show Animation Trigger and Hide Animation Trigger fields. When the PausePanel opens, it sets the Show Animation Trigger on the Animator.

If you assign the "Canvas Group Animator Controller" to the PausePanel's Animator, it will fade in/out. (This animator controller also has Show and Hide triggers, like the MenuPanelAnimatorController that's assigned by default, but they fade instead of popping.) Or you can assign your own animator controller, or even remove the Animator entirely if you want the menu to instantly appear/disappear.
xemanon wrote: Sat Feb 26, 2022 12:16 am2. I am also using Cinemachine, and starting a new scene from the Main Menu appears to teleport the player some distance horizontally on the x-axis. I tried this without the Main Menu framework (using a basic system of my own instead) and this did not occur. I did however notice that Cinemachine would be set to "None" for ~1 second before turning to the live cam, but still, the slight teleportation only happened using the framework. Do you have any inklings why this might be? This might be a fault of my own, but I'm not sure.
Edit for #2: I've found this only occurs when loading a previously saved scene. This is a gif of it happening for context
I may need more info. Try setting the Save System component's Frames To Wait Before Apply Data to zero. If that doesn't address the issue, can you send a reproduction project to tony (at) pixelcrushers.com?

Re: 2 questions about using the Menu System

Posted: Sat Feb 26, 2022 3:21 pm
by Tony Li
Hi,

Thanks for sending the repro project. I replied to your email.