PDA

View Full Version : Unity Help Thread



Cyberninja
21-11-2010, 06:41 PM
Hey guys. Seeing that many people here are making the move to Unity, I thought it would be a good idea to have a dedicated thread for Unity discussion, questions and answers. I've included a list of resources to help with the learning process. I'll be updating this thread as time goes on. In the meantime, please feel free to post all questions that relate to Unity game development here.


What is Unity?

Unity is a development tool that has been designed to let you focus on creating amazing games.


Where can I find it?

http://unity3d.com/unity/


Tutorials and Resources:

Unity: Questions and Answers (http://answers.unity3d.com/)
Unity: Documentation (http://unity3d.com/support/documentation/)
Unity: Resources (http://unity3d.com/support/resources/)
Unity: Community (http://unity3d.com/support/community)
Unity: Wiki (http://www.unifycommunity.com/wiki/index.php?title=Main_Page)
Unity: Forums (http://forum.unity3d.com/)

http://infiniteunity3d.com/unity-3d-video-tutorials/
http://www.unityscript.com/
http://www.unitymagic.com/shop/
http://gameprefabs.com/
http://gameassets.net/
http://www.gamergfo.com/site/index.html
http://www.theunityartist.com/forum/index.php
http://www.3dbuzz.com/vbforum/showthread.php?181409-Over-7-hours-of-Unity-Training-Videos-Download-them-now
http://www.unitylabs.net/tutorials
http://www.anbsoft.com/middleware/
http://www.ennanzus.com/developer/GUIX/buy.htm
http://www.thecareergamer.com/braaaains-zombieville-usa-tech-review/
http://angryant.com/
http://www.design3.com/unity
http://learnunity3d.com/tag/video-tutorials
http://www.unity3dstudent.com/

http://walkerboystudio.com/html/unity_training___free__.html
http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-1/

(NEW) A starter guide on how to create a Canabalt-style game. Includes the full Unity Project:

http://www.stevegargolinski.com/runjumpshoot-a-free-canabalt-style-jump-start-for-unity/

(NEW) A starter guide on how to create a game like Evac-City. The links for the resources and project files can be found in the guide:

http://www.rebelplanetcreations.com/downloads/Other/Tutorials/HowToMakeAGameInUnity3D.pdf

The guys at Rocket 5 Studios have completed their 2D tutorial series. Here are all the links:

http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-1/
http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-2/
http://www.rocket5studios.com/tutorials/2d-or-not-2d-creating-2d-games-with-unity3d-part-3/
http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-4/


http://www.youtube.com/user/TornadoTwins
http://www.youtube.com/user/Unity3D#p/u
http://www.vimeo.com/unity3d/videos


Commercial Resources:

VTC: Introduction to Game Development Using Unity 3D (http://www.vtc.com/products/Introduction-to-Game-Development-Using-Unity-3D-Tutorials.htm)
VTC: Game Development for iPhone/iPad Using Unity iPhone (http://www.vtc.com/products/Game-Development-for-iPhone-iPad-Using-Unity-iPhone-Tutorials.htm)
Unity Game Development Essentials (http://www.amazon.com/Unity-Game-Development-Essentials-Goldstone/dp/184719818X/ref=sr_1_2?s=books&ie=UTF8&qid=1290353070&sr=1-2)
Unity 3D Game Development by Example Beginner's Guide (http://www.amazon.com/Unity-Development-Example-Beginners-Guide/dp/1849690545/ref=sr_1_3?s=books&ie=UTF8&qid=1290353191&sr=1-3)
Creating 3D Game Art for the iPhone with Unity (http://www.amazon.com/Creating-Game-Art-iPhone-Unity/dp/0240815637/ref=sr_1_1?s=books&ie=UTF8&qid=1290353286&sr=1-1)
http://www.3dattack.us/3DAttack/Magazine.html

3rd-Person Platformer Game - Part 1:

http://www.3dbuzz.com/vbforum/showthread.php?188331

Custom 3rd-Person Character and Camera System with C#:

http://www.3dbuzz.com/vbforum/content.php?212

Unity 3 Fundamentals:

http://www.3dbuzz.com/vbforum/content.php?176


NB: If you know of any other Unity tutorials/websites, that aren't listed here, let me know and I'll add them to the list.

Fengol
22-11-2010, 07:17 AM
http://answers.unity3d.com/ is probably the most important link on your list and should be promoted above the other tutorials and resources.

edg3
22-11-2010, 07:42 AM
I can also give some help to people using Unity if it is needed. (Im not entirely sure that every single game engine needs a thread though ;) ) Perhaps the Game Maker help thread needs to have a facelift to be a general game dev help thread?

Cyberninja
22-11-2010, 08:15 AM
http://answers.unity3d.com/ is probably the most important link on your list and should be promoted above the other tutorials and resources.

Done. List updated. Added two new links, as well.


Perhaps the Game Maker help thread needs to have a facelift to be a general game dev help thread?

That sounds like a really good idea, actually.

FuzzYspo0N
22-11-2010, 09:12 AM
That sounds like a really good idea, actually.

Don't think so. Its pages and pages of game maker stuff.
Why not make one for unity that can be as awesome, cos that one is awesome.

Cyberninja
22-11-2010, 09:40 AM
Don't think so. Its pages and pages of game maker stuff.
Why not make one for unity that can be as awesome, cos that one is awesome.

That's actually one of the reasons why I created a separate thread. :P I didn't want it to get lost in the shuffle. I've spoken to Dis and he's agreed to see how this thread progresses. If it proves useful, then he may decide to Sticky it.

BlackShipsFillt
22-11-2010, 11:10 AM
Oooh Oooh! I vote that this thread become a sticky as well! (If that is the thing we're voting on)

dislekcia
22-11-2010, 01:01 PM
Experimenting with Unity 3.1 today. So far things have been relatively painless, apart from Unity removing old versions when it installs (yay for multiple machines) and MonoDevelop doing who knows what while trying to get the much-touted debugging working.

At least you can still use VS, although does anyone know why Unity opens an explorer window after I hit the "sync MonoDevelop Project" option?

nix
25-11-2010, 08:06 AM
At least you can still use VS, although does anyone know why Unity opens an explorer window after I hit the "sync MonoDevelop Project" option?

@dislekcia It's not something you need to do often, updates you make are auto-sync'd. I'm running 3.1 pro and it seems to launch MonoDevelop for me. Have you made any changes to your Unity preferences - In particular the External Script Editor field?

MonoDevelop Takes some getting used to - I don't recall doing anything special to get the debugging working, just make sure Unity is closed and hit the debug button in MD. This should launch Unity, open the project and break on the first break point encountered.

@Anyone interested - My brother has written a duplicate line/selection plug-in for MD which is invaluable to those who have come to rely on the functionality. If anyone cares to use it just shout and we'll make it available. Since dis is a VC man I don't think he'll miss it ;P

dislekcia
25-11-2010, 04:34 PM
@dislekcia It's not something you need to do often, updates you make are auto-sync'd. I'm running 3.1 pro and it seems to launch MonoDevelop for me. Have you made any changes to your Unity preferences - In particular the External Script Editor field?

MonoDevelop Takes some getting used to - I don't recall doing anything special to get the debugging working, just make sure Unity is closed and hit the debug button in MD. This should launch Unity, open the project and break on the first break point encountered.

@Anyone interested - My brother has written a duplicate line/selection plug-in for MD which is invaluable to those who have come to rely on the functionality. If anyone cares to use it just shout and we'll make it available. Since dis is a VC man I don't think he'll miss it ;P

Yeah, I'd set up MonoDevelop as the default instead of that horrid SciTe editor. Didn't know that Unity needed to be closed. I was running it with Unity open, will give that a go later ;)

We used the sync project option a lot in Unity 2.6 because there 3 of us all making changes and adding code via SVN, so we'd have to sync after every get latest that added a new class - otherwise it wouldn't show up in VS.

nix
25-11-2010, 08:57 PM
We also collaborate between 3 people via svn, but we tend to close unity between check in/updates. We found that some changes aren't saved if unity stays open so changes aren't merged properly. Doing this has the added benefit that I hardly ever have to sync the project files.

Would be interesting to hear how other teams share their Unity projects.

dislekcia
25-11-2010, 09:55 PM
We also collaborate between 3 people via svn, but we tend to close unity between check in/updates. We found that some changes aren't saved if unity stays open so changes aren't merged properly. Doing this has the added benefit that I hardly ever have to sync the project files.

Would be interesting to hear how other teams share their Unity projects.

Not many do, apparently. We got a lot of questions after writing a really brief tale of Unity + SVN on our site.

I'm keen to see how Unity Pro plays with SVN, to be dead honest. We've got some odd graphics bugs (imprecision on meshes only on my machine) that I'd like to be able to isolate to either graphics card or Library issues. These days I can't imagine working without a good repository, especially one that's mirrored on the net. I really can work anywhere ;)

BlackShipsFillt
26-11-2010, 12:07 PM
We're on Asset Server... It has its pitfalls but for the most part we're aware of them and our sharing is pretty smooth...

I wouldn't mind graduating to a proper bullet proof versioning system if the workflow is reasonable, it is a bit scary being able to so easily lose work (even if it is only ever lost through carelessness, carelessness is an unavoidable part of development)

dislekcia
26-11-2010, 07:05 PM
Aaargh... I've spend a fair chunk of today trying to figure out why my desktop's rendering is wonko and every other machine in the office isn't. Bascially we use quads as sprites, when these are ingame tiles, they're 1x1 in Unity units (whatever those are). For some crazy reason, not every single quad appears as exactly 1x1 on my desktop machine, sometimes tiles are ever so slightly squished, producing these horrid 1 pixel gaps.

Only happens after the switch to Unity 3. Haven't been able to figure out what's causing it. Slowly going insane :(

nix
27-11-2010, 06:17 AM
! Unity unit is considered a meter in the game world (in physics terms)

With regard to your squish, are you seeing this in the game view, editor view or both?
I've noticed that screen dimensions and aspect are reported incorrectly during edit mode. The game view camera reports the edit view camera's dimensions. Try making the two views vastly different (one short and the other tall) and look at the game view camera's frustum in the edit view.

It would also help to know if this is a ortho camera, or a specific shader in play or if you've been using the GL classes.
Kind of a wide net you're casting there :P

dislekcia
27-11-2010, 05:13 PM
! Unity unit is considered a meter in the game world (in physics terms)

With regard to your squish, are you seeing this in the game view, editor view or both?
I've noticed that screen dimensions and aspect are reported incorrectly during edit mode. The game view camera reports the edit view camera's dimensions. Try making the two views vastly different (one short and the other tall) and look at the game view camera's frustum in the edit view.

It would also help to know if this is a ortho camera, or a specific shader in play or if you've been using the GL classes.
Kind of a wide net you're casting there :P

On my machine we're seeing the squish in both editor cam and game cam. Game cam is an ortho camera (we're using it for 2D, after all) and we're using standard shaders AFAIK, no GL classes (don't even know what those are?). Like I said, only happens on my Win 7 ATI desktop. Been poking the camera settings a little, by jiggling the frustum, I can get the game cam in the editor not to have seams between tiles (which mathematically don't exist at all, BTW) but they're still there at our target res when I build standalone. If I get some time later I'll post screenshots.

FuzzYspo0N
27-11-2010, 08:46 PM
ATI don't like NPOT textures. Maybe that?

Luke
27-11-2010, 10:18 PM
ATI don't like NPOT textures. Maybe that?

HULK SMASH NPOT TEXTURES!!!

dislekcia
27-11-2010, 10:50 PM
ATI don't like NPOT textures. Maybe that?


HULK SMASH NPOT TEXTURES!!!

Nope, all textures are POT. Appears to be vertex calculation related... (happens even with no textures, just base diffuse colouring) I really wish debugging worked properly :(

Necrolis
28-11-2010, 01:28 PM
Nope, all textures are POT. Appears to be vertex calculation related... (happens even with no textures, just base diffuse colouring) I really wish debugging worked properly :(sounds very much like a gfx card/driver issue to me, does this happen in other games on your system? Cause on the laptop i'm currently using I have the exact same problem with any type of rendering(2d or 3d, but not gdi based apps), that leaves horrid gaps between everything.

nix
29-11-2010, 08:19 AM
You have quite a curious case there!

Odd that your debugging doesn't work. Here's the basic steps you should be following.
1. Open monodevelop & project (make sure unity is closed)
2. Run debug mode - this should launch unity (make sure you've set the location of the unity exe in the options)
3. Set a breakpoint somewhere in your code (I've found breaking in initialisation hangs my machine)
4. Press play in unity to launch game.

Gl Classes is a pro only feature - http://unity3d.com/support/documentation/ScriptReference/GL.html

Screenshots will help, if you're still stuck we can try IM.

herman.tulleken
14-12-2010, 04:47 PM
Anyone have any idea how to draw a fullscreen quad fast (on Android)? In our project, this is causing a frame rate drop of 10 FPS (from 40 average to 30 average)... is this normal? I'm not a graphics optimisation guru, so I might be doing something stupid.

Cyberninja
10-01-2011, 10:59 PM
Walker Boys Studio have released +100 video tutorials for Unity. You can find them here:

http://walkerboystudio.com/html/unity_training___free__.html

Bonezmann
11-01-2011, 07:03 PM
Thanks for the link CyberNinja, ever since the TornadoTwins started charging for their content, I've been looking for a new place to learn Unity stuff.

Cyberninja
06-04-2011, 08:25 PM
Walker Boys Studios have finally released their 2D SideScroller video tutorials. It goes through the process of building a 2D Mario clone. The project files are also available:

http://walkerboystudio.com/html/unity_training___free__.html#unity3game3

Edit: The videos are currently for private users, only. I will update the thread, when they are available for the public.

dislekcia
07-04-2011, 02:48 AM
Edit: The videos are currently for private users, only. I will update the thread, when they are available for the public.

Totally crossing my fingers on this. I want to see how other people do 2D in Unity so bad!

Cyberninja
07-04-2011, 09:42 PM
Yeah. As well. I've emailed the guys at Walker Boys Studios, concerning the videos above. Just waiting for a reply. 3d Buzz have also released some new video tutorials. Links below:

3rd-Person Platformer Game - Part 1:

http://www.3dbuzz.com/vbforum/showthread.php?188331

Custom 3rd-Person Character and Camera System with C#:

http://www.3dbuzz.com/vbforum/content.php?212

Unity 3 Fundamentals:

http://www.3dbuzz.com/vbforum/content.php?176

Cyberninja
08-04-2011, 03:10 PM
I received a reply from Chad Walker. He said the password protected videos are designed so that you work through the lab training, and complete the "required" exams. After successful completion of each project, you will be given passwords for the next set of lab videos/tutorials. More info can be found here:

http://www.walkerboystudio.com/html/unity_course_start_here__free_.html

Bonezmann
11-04-2011, 03:43 PM
I seem to have a little problem, I recently installed Unity3D Pro's trial edition. Now my trial has expired and I can't use it. Pressing the "Renew" button doesn't do anything. Anyone have any help?

Fengol
11-04-2011, 04:02 PM
There's Trial and Pro Trial. If I remember correctly, when you go to the registration page it's the top option

StevenMcD
19-04-2011, 02:09 PM
Thanks so much for this list of links! I came here looking for resources on Unity and its one of the first threads I see :) bookmarked and will be making use of these links.

Cyberninja
09-05-2011, 09:45 PM
A starter guide on how to create a Canabalt-style game. Includes the full Unity Project:

http://www.stevegargolinski.com/runjumpshoot-a-free-canabalt-style-jump-start-for-unity/

A starter guide on how to create a Top-Down game like Evac-City. The links for the resources and project files can be found in the guide:

http://www.rebelplanetcreations.com/downloads/Other/Tutorials/HowToMakeAGameInUnity3D.pdf

The guys at Rocket 5 Studios have completed their 2D tutorial series. Here are all the links:

http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-1/
http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-2/
http://www.rocket5studios.com/tutorials/2d-or-not-2d-creating-2d-games-with-unity3d-part-3/
http://www.rocket5studios.com/tutorials/creating-2d-games-with-unity3d-part-4/

Higushi
08-06-2011, 11:05 AM
Thanks Cyberninja, these resources are great.

I've just started using Unity and loving it! Been a while since I've done some game dev, but Unity is so powerful and makes it so easy... its difficult to resist getting back into it again. :) Its like Game Maker, but just way more powerful and with awesome 3D capabilities!

I'm a little surprised this thread isn't a sticky? Is Unity not as popular as I assume it to be? Suppose the price could have something to do with that...

herman.tulleken
09-06-2011, 10:24 AM
I think Unity is very popular, but other resources like Unity.Answers is generally more helpful.

Bonezmann
13-07-2011, 02:13 PM
Hey guys, I want to move my main character object when you press the arrow keys, BUT I want it to keep moving in that direction until it hits another object, it also shouldn't accept any other input commands while moving.

Any ideas on how I would go about this?

dislekcia
14-07-2011, 02:01 AM
Hey guys, I want to move my main character object when you press the arrow keys, BUT I want it to keep moving in that direction until it hits another object, it also shouldn't accept any other input commands while moving.

Any ideas on how I would go about this?

Time to start with the variables.

First, you'd need to set up a state for your player object, either it's moving or it's waiting for input after it's hit something. That could be a simple boolean yes or no variable. Then you'd need to store the velocity it should move at, if you set that up as a vector3, you can store the direction it should move in too, so you'd end up with code that looked something like this:

In your update event (the one that's called every frame), you'd first check to see if it was moving. Then if it was, you'd add the movementVelocity * how much time has passed to the translate.position variable, moving the object every frame.

When a key was pressed, you'd check to see if it was moving again. If it wasn't you'd set the movementVelocity to whatever you wanted it to be and set moving to true, to stop other key presses messing with your current motion.

Finally, when it hit collided with something and "stopped", you'd set moving to false and your movementVelocity back to zero. (Although, if you understand this logic, you should be able to tell me why it doesn't matter if you reset movementVelocity or not)

Bonezmann
14-07-2011, 10:48 PM
Awesome, thought it might be something along those lines. Thanks Dis. :)

edit: I'll have to study you post some more before I'm going to understand that logic. :P

Bonezmann
15-07-2011, 12:44 PM
Okay so I got this:


var moveVelocity : Vector3;
var moving = false;
var truev = 1;
var trueh = 1;


function Update ()
{

var h = Input.GetAxis("Horizontal");
var v = Input.GetAxis("Vertical");

if (Input.GetAxis("Horizontal"))
var moving = trueh;

if (Input.GetAxis("Vertical"))
moving = truev;

if (moving == truev)
transform.Translate(v*4,0,0);

if (moving == trueh)
transform.Translate(v*4,0,0);

}

I made two states trueh and truev for horizontal and vertical axis and it works but still only while I press the buttons, as soon as I let the buttons go it stops moving.

What am I doing wrong here?

edit: tried changing it to this, still not working :(


var moveVelocity : Vector3;
var moving = false;
var truev = true;
var trueh = true;


function Update ()
{

var h = Input.GetAxis("Horizontal");
var v = Input.GetAxis("Vertical");

if (Input.GetAxis("Horizontal"))
moving = trueh;

if (Input.GetAxis("Vertical"))
moving = truev;

if (moving == truev)
transform.Translate(v*4,0,0);

if (moving == trueh)
transform.Translate(v*4,0,0);

}

SkinkLizzard
15-07-2011, 07:59 PM
logic order should be:


check the moving boolean
if it's false
{
check the input axes thing
if you have a key/whatever pressed
{
set movevelocity to some value based on which direction you need to move.
set moving to true
}
}
if it's true
{
transform.Translate(movevelocity*time_elapsed)
}

on collision with other block
set moving to false.

Edit: actually just try replacing your transfrom.translate(v*4,0,0) with transform.translate(moveVelocity)
and assign the moveVelocity variable based on the input.

Elyaradine
20-07-2011, 02:28 PM
Experimenting with Unity 3.1 today. So far things have been relatively painless, apart from Unity removing old versions when it installs (yay for multiple machines) and MonoDevelop doing who knows what while trying to get the much-touted debugging working.

Out of interest, I've had success installing updates to separate folders. It only removes the old Unity installation if it already exists in the path you're installing to.

Of course, if you're opening the same project in significantly different versions, it's possible that the newer version will require you to upgrade the project, in which case the old version won't be able to open it any more.

Cyberninja
11-08-2011, 12:45 PM
I've been doing some research on game design and came across a really fantastic website. The site is called Pixel Prospector. It has numerous links that deal with different aspects of game design. It's definitely worth checking out, if you have an interest in game development. I've been going through some of the articles (they even have links to Dev.Mag articles) and it's proving to be very educational. Check it out:

Link: http://www.pixelprospector.com/the-big-list-of-game-design/

Cyberninja
13-12-2011, 01:13 PM
Hey guys. The videos for the 2D Mario Clone, by Walker Boys Studios, can now be accessed by the public. The videos cover various components that are used in games (power-ups, items, camera movement, character animation set-up...etc) You can find the videos here:

http://www.walkerboystudio.com/html/unity_course_lab_4.html

Higushi
16-12-2011, 04:45 PM
Thanks Cyber, I'm going through the Mario Clone tutorial now.