I have 3d scene. I made a button, its Canvas visible to camera. Now I need to be able to press it. How do I do it? I spent more than 10 min on it. Official manual should cover such basic question better. Indie gamedev should be 10 min max on such basic things.
You play the game and click on it.
Seriously, it handles mouse clicks built in. You only need to tell it what to do when you do actually click on the button.
Also why did you tag this IMGUI when this is an Unity UI (or uGUI) question?
No. It doesnt show mouse coursor at all. I know how to set button action LoadScene. but I cant enable Mouse coursor. Yeah thats why official manual should be better way better. Solo indie like me doesnt know difference between imgui and gui
None of the above matters. This is software engineering. What you need to do is trivially simple, simple enough that you should be able to list in your post above, “I did this, this, this and this, which based on this official documentation is all I need.”
How to report your problem productively in the Unity3D forums:
This is the bare minimum of information to report:
- what you want
- what you tried
- what you expected to happen
- what actually happened, log output, variable values, and especially any errors you see
- links to actual Unity3D documentation you used to cross-check your work (CRITICAL!!!)
The purpose of YOU providing links is to make our job easier, while simultaneously showing us that you actually put effort into the process. If you haven’t put effort into finding the documentation, why should we bother putting effort into replying?
Try this approach: work at the problem one step at a time: start from a blank scene, get a button going. This should be within your grasp. The move onto more complex situations approaching your game situation.
Two steps to tutorials and / or example code:
- do them perfectly, to the letter (zero typos, including punctuation and capitalization)
- stop and understand each step to understand what is going on.
If you go past anything that you don’t understand, then you’re just mimicking what you saw without actually learning, essentially wasting your own time. It’s only two steps. Don’t skip either step.
Just like this guy:
Imphenzia: How Did I Learn To Make Games:
UI Buttons on World Space Canvases must have Box Collider.
Once again, manual’s are a quick reference material. Not a comprehensive step by step tutorial.
Your code must be hiding the cursor as by default it doesn’t hide when entering play mode.
You can easily change its visibility: Unity - Scripting API: Cursor
You should learn to search things like “Unity how to show mouse cursor”.
Plenty of other solo indie devs like myself don’t have issues with these run of the mill things. The issue here is your impatience.
Maybe you are ok to watch 10 tutorials videos and type code by pausing video and have critical errors. I need text with examples. Scripting reference just shows line of code with very little explanation.
Yeah ok, But still there should be better manual with examples. And stop being toxic. I am not asking on how to make a game. Is Unity indie open engine or Cryengine that was closed semi closed and if I am right manual wasnt free to download…)
I’m not being toxic. I’m simply pointing out that your expectations of getting something done in 10 minutes are not realistic if that thing takes more than 10 minutes. As Spiney points out:
Take a deep breath. It’s impossible to know how fast something will take until you’ve done it enough times, and even then, something can always go wrong.
Even something as trivial as a stray semicolon ; after an if() block has tripped me up for FAR longer than ten minutes because I failed to instantly attach the debugger and find my bug. That’s on me, not the semicolon.
If I want to learn how to do something, I am okay with doing whatever it takes for me to learn what I need to learn.
I’m curious what alternate strategy you propose to learn something new.
Ok. But u should agree that Official manual should be
- for all LTS versions and 6000. So no critical errors when copy and paste code from manual
- It should be text so people can copy and paste
- it should have normal examples. 3D game. Not some strange 2d 2.5 mobile scam. A proper 3d game idk like Gothic demo level 2024.
Most people come without knowledge of C#. Unity is promoted as indie friendly engine. Manual is supposed to cover all basic needs. I am not talking about explaining RTX lights in 1 min. Googling 3d party things (tutorials websites files from Github(thought there are some official from Unity) is not good expirience…
I also think we should have world peace and unlimited free coffee. You agree, right?
In practice the manual is simply a reference. It would be impossible to capture everything, as you can see.
Unity is a fantastic indie-friendly game engine.
Then software engineering is NOT for you. Move onto something else. Seriously. You will absolutely need to know how to be a wily clever detective and ferret out all the things you need to solve whatever your problem is.
- manuals
- articles
- blogs
- friends
- colleagues (perhaps from user groups or forums)
- trying out stuff on your own <— HUGE!!!
- example code
- complete games (such as from the asset store)
- etc. etc.
When you run into a problem, remember, NOBODY can read your mind and see your screen.
That’s why you must bring this to the table:
How to report your problem productively in the Unity3D forums:
This is the bare minimum of information to report:
- what you want
- what you tried
- what you expected to happen
- what actually happened, log output, variable values, and especially any errors you see
- links to actual Unity3D documentation you used to cross-check your work (CRITICAL!!!)
The purpose of YOU providing links is to make our job easier, while simultaneously showing us that you actually put effort into the process. If you haven’t put effort into finding the documentation, why should we bother putting effort into replying?
If you’re not doing the above, why should we bother??
Ok but me as a Costumer with no C# University Education and lots of free time is not happy.
I just started here: Junior Programmer Pathway - Unity Learn
And got about halfway through before I was comfortable enough to start doing stuff on my own. I haven’t actually watched a youtube tutorial for over two years now.
You’re not a customer as Unity haven’t made a cent off of you yet, and probably won’t ever.
And if you have tons of free time, use that time to do a proper learning course, like the free one Unity has created themselves I linked earlier.
The manual is just a reference, not a university course.
I should sue u for such toxic behavior.