Hello.
I need to make something like the lockpicking from thief simulator and i have a few questions.
Is there any easier way to disable all input (like moving or camera rotating) without putting something like “if (!isInMinigame)” everywhere, but allowing player interact with the minigame itself?
I was thinking creating a new scene for it, but i’m planning on making a lot of minigames, so i don’t want to create 20 scenes. I also need to interact with the scripts from main scene, so i dont see this as an option.
Also, how to put the minigame canvas on top of everything else? I have few 3d objects inside of one minigame, and they are in texture of other objects in the scene.
Also, i dont want some camera switching when entering/exiting minigames. Ideally just blurring the background a little.
I know this is very complex question, but im really lost and dont know what to do.
SImply, I would disable your player controller and camera controller components.
Why not? Making 20 scenes is easy. You can load an additional scene with your main scene still loaded, so you can have scripts from both scenes running, no problem.
I don’t know how your scene is set-up but it could be as simple as setting the canvas sorting order. Outside of that you could disable any canvases that you’re not using
If you are disabling your normal play-mode camera controller, then you can enable any alternate camera controller you want. Your minigame scene could have a camera controller where it just places the camera at right place and direction. You could think along the lines of how Cinemachine is implemented- you have one single camera but multiple camera controllers for different situations (or you could just actually use Cinemachine).