- Home /
Question is off-topic or not relevant
Is unity all about Scripting?
I am new and i am trying to create a main menu, (Note: i don't know any form of Scripting) and i want the text to be highlighted to show that the cursor is hovering over it, do i need to write a script to do so?
if you're young learning very basic scripting is a really good advantage seeing as you will use computers for the foreseeable future. it doesn't actually take more than 20 $$anonymous$$ to learn a couple of lines of code for the button menu, and scripting of only 2 lines is really easy, and it just builds from that. Once you have spent a couple of weeks learning, you should be able to understand hundred different kinds of lines.
i tried YouTube but didn't find anything Series on any of the three formats...
Although not relevant to your question, here are some links I strongly suggest to all new users :
Start at the bottom and work up : http://www.unity3dstudent.com/category/modules/essential-skills/
Start at the bottom and work up : http://www.unity3dstudent.com/category/modules/beginner/
this is the YouTube link for the above as one playlist : http://www.youtube.com/watch?v=-oXYHNSmTxg&list=PL27B696FB515608D2&feature=plcp
That is good to get started. Then start with a small tutorial, this is a simple 2D space shooter : http://www.unityjumpstart.com/ProofOfConcept_1/ : click on the videos part1.mp4 part2,3,4 =]
I just found another by our own Eric : http://wiki.unity3d.com/index.php?title=2DShooter : http://forum.unity3d.com/threads/7883-2D-shooter-tutorial
By then you should be getting the hang of things and starting to have ideas of your own. When you decide what kind of game you want to make, then look at each part you'll need. For example, if you want to make some terrain then walk around it with a character : http://cgcookie.com/unity/2011/12/05/introduction-to-character-controllers/
Here's another on the same 'site but I havn't checked the difficulty : http://cgcookie.com/unity/2012/02/24/game-planning-lunar-lander-01/
Basically then just search for tutorials, there are many out there, either written or on youtube.
the Unity Wiki tutorials : http://wiki.unity3d.com/index.php/Tutorials
A big list of tutorials : http://answers.unity3d.com/questions/12321/how-can-i-start-learning-unity-fast-list-of-tutori.html
A very helpful 'site, all in C# : http://unitygems.com/
Helpful page with information on using Built-In Arrays and Lists (you'll need this later!) : http://www.unifycommunity.com/wiki/index.php?title=Which_$$anonymous$$ind_Of_Array_Or_Collection_Should_I_Use?
The unity wiki link above is very handy with lots of scripts and shaders too (just check out all the links down the left, and the tabs along the top : http://wiki.unity3d.com/index.php/Scripts )
http://answers.unity3d.com/questions/148211/list-of-frequently-asked-beginners-questions.html
http://forum.unity3d.com/threads/132628-How-to-help-the-Absolute-Beginner
If you know what kind of game you want to make, edit your question and write there what you are thinking of, then there may be a tutorial out there for that!
But just be aware, you will do lots of typing, deleting, typing, bashing head on desk, being really happy when it works and you understand how and why. I hope this helps, Happy Coding =]
Regarding scripting, there is a method I heard of but never used for arranging things without scripting, you'll have to do some research, search the Unity Asset Store for Play$$anonymous$$aker
http://www.hutonggames.com/tutorials_game_design_with_playmaker.php
Answer by smirlianos · Jan 04, 2013 at 08:00 PM
If you use a 3d text as the main menu text use this script. Put a box collider on every text and attach the script to every text! in the "play" text, check in the inspector the "play Button" box. When the mouse hovers the text, it will turn to red, and when the mouse leaves the test, it will turn to normal again. When you click it, if it is the "play" button, it will load the next scene, if it is the "quit" button, it will quit the game!
hope I helped!
var playButton : boolean;
var quitButton : boolean;
var optionsButton : boolean;
function OnMouseEnter() {
renderer.material.color = Color.red;
}
function OnMouseExit() {
renderer.material.color = Color.white;
}
function OnMouseup() {
if(playButton)
{
Application.LoadLevel(1);
}
else if(quitButton)
{
Application.Quit();
}
else if(optionsButton)
{
Applicaio.LoadLevel(2);
}
}
is this a Java Script amd i did this but i don't know how to make it that when you click the button it go to the options menu and thanks
It's javascript,
if you want to have and a third button that goes to the options scene, add another " if else" in the On$$anonymous$$ouseUp function. I edited my answer to see who it's in the complete form!
(the script works supposing that the options menu is in scene 2, and the play button goes to the scene 1)
Hope i helped!
Oh, and I forgot! There are some good tutorials on how to make a main menu at this youtube channel.
oh i undestand some and i wrote my first script base on what you have i guess the part about Transform... is this right?
var story$$anonymous$$odeButton : boolean; var more$$anonymous$$odesButoon : boolean; var optionsButton : boolean; var helpButton : boolean; var quitButton : boolean;
function On$$anonymous$$ouseEnter()
{ renderer.material.color = Color.blue; transform.localScale += Vector3(0.05,0.05,0); }
function On$$anonymous$$ouseExit()
{ renderer.material.color = Color.white; transform.localScale += Vector3(-0.05,-0.05,0); }
function On$$anonymous$$ouseup()
{
if(story$$anonymous$$odeButton);
Application.LoadLevel(1);
}
{
else if(more$$anonymous$$odesButoon);
Application.LoadLevel(2);
}
{
else if(optionsButton);
Application.LoadLevel(3);
}
{
else if(helpButton);
Application.LoadLevel(4);
}
{
else if(quitButton);
Application.Quit();
}
Good work! I wrote your script more clear
var story$$anonymous$$odeButton : boolean;
var more$$anonymous$$odesButoon : boolean;
var optionsButton : boolean;
var helpButton : boolean;
var quitButton : boolean;
function On$$anonymous$$ouseEnter() {
renderer.material.color = Color.blue;
transform.localScale += Vector3(0.05,0.05,0);
}
function On$$anonymous$$ouseExit() {
renderer.material.color = Color.white;
transform.localScale += Vector3(-0.05,-0.05,0);
}
function On$$anonymous$$ouseup() {
if(story$$anonymous$$odeButton)
{
Application.LoadLevel(1);
}
else if(more$$anonymous$$odesButoon)
{
Application.LoadLevel(2);
}
else if(optionsButton)
{
Application.LoadLevel(3);
}
else if(helpButton)
{
Application.LoadLevel(4);
}
else if(quitButton)
{
Application.Quit();
}
}
Answer by Mr.Z · Jan 04, 2013 at 07:32 PM
It certainly isn't, but it is necesary and in most cases unavoidable. As for highlighting text, check this out: http://forum.unity3d.com/threads/130424-TextField-Highlight-Color