First of all I want to thank Unity for providing a free yet wonderful application for creating apps.
I am a graduating IT student who is creating a game for my thesis. I am completely new to game development but I am very eager to learn and dedicate lots of hours per day to create and finish my thesis. By the way I am from the Philippines.
My proposed thesis is a Philippine Inspired 3d adventure educational game. I have been trying to learn the basics for two weeks now and had great progress.
My questions would be
How can I make mini-games inside my 3rd person game? like jigsaw picture puzzle and answer the questions?
How can I trigger them?
How can i make a portal for like ex from stage 1 up to stage 2?
Can you explain in a bit more detail exactly what you want to achieve?
You can trigger “mini-games” however you want to.
If you shoot me some more details of exactly what you want, I might be able to give a pointer or two.
I want to build a game where users can create and publish game. I will provide and actions they just need to put them together. When they publish others can play.
@Plaban: That’s a tad bit too different to cover under this topic. I’d suggest asking in the scripting section, but it would consist of making your own in-game editor, defining “game” and the limits of the editor, serializing the data properly, a bit of networking for publishing (depending on how you aim to share the data), and more. Possible but quite a bit of work.
@krisian: If you want to, say, approach a box and press e, it would take a few steps. First, I’m about to assume these things will be needed:
Need to approach a set distance of the box, will assume don’t need to look at it for simplicity
The mini-game will not have its own scene- for simplicity for getting right back into the 3D world.
There are many ways to do this, but the way I would do this is the following
Place a script on the box to check for player in a set distance
If player is in a set distance, give prompt to press certain button to start the game
If button is pressed, the player’s movement/controls and anything associated with the “3D” main world is disabled
Either the main camera is disabled and another is reenabled, or the current player camera position would be saved and the main camera would be moved to the mini game location
Here’s the trick for simplicity: the mini-game would exist in the current scene. I’d put it below ground, use a second camera pointing at the mini-game, and switch between the cameras. Just in case, if I’m not really using layers much, I’d set the entire minigame on its own layer and set the main camera through culling options to ignore that layer and the second camera to only see that layer
Once the player is disabled and the camera is moved/disabled and another is reenabled, I would activate all the objects for that mini-game. Basically, either instantiate the entire thing at once (not my preference) or… (in steps)
a) Have box either already have the entire mini-game (under its own empty GameObject let’s call “MiniGame”) already in a public variable and do SetActive(false) on “MiniGame” to not start the MiniGame before hand or have it do GameObject.Find to find teh MiniGame (not my preference)
b) Have the box ACTIVATE that MiniGame one way or another. The MiniGame would have its own controls, GUI, etc for the MiniGame feel or whatever you need
c) After MiniGame is done, reactivate a function in the box to turn off the MiniGame however (Destroy, SetActive(false) again, etc), reactivate the player, move the camera back/activate the right one and turn off the second camera, etc.
You would most likely change these steps to suit your specific minigame and environment (say you want the minigame to be replayable, you may need a system to instantiate or reset the minigame while maybe keeping old scores), but this should provide a basic outline.
Good luck, and feel free to ask for clarifications!
Im doing this same thing ive gotten all the steps set up including the secondary camera and the player disable. Heres my issue all the 3d Objects are in the play space already and can only be clicked on when the new camera is activated. However i can not seem to grasp how to get a drag and drop type of situation going on the objects. I have all the colliders, triggers, sets, and mechanics set up…i just cant figure out the drag and and drop. Any Help would be awesome
You can add a minigame as a prefab with it’s own camera, then instantiate the prefab and render it on top of your 3D scene.
This is a very simple question and you should be at least be doing a few weeks of tutorials that will teach you this rather than asking people to show you how to do it.