Sign in to follow this  

scripting and unity3D

This topic is 1469 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi again people!

So yesterday I've asked here some informations about physics engines and how to write a game engine. After some research, I understood that for now it would be best to learn a bit how an engine works before trying to write my own engine. So, I've tried two engines: cryengine and unity3D. I didn't like cryengine, so I'll stick with U3D. I've understood some of the basic things and such, but now I'm stuck. I guess that to do all those fancy videogames stuff (like , I don't know, programming the AI?) You need always scripts, am I right? Well, my question is, where do I learn to use those scripts? Give that I can't use C# (but I know C++), is there a manual or something? Because while I'm able to code, I don't know how to make a script for unity. Any book or online tutorials on that? The more detailed the better. 

 

edit: should I try UDK ? Which is more simple? Which is more beginner-like?

Edited by GarrettTheThief

Share this post


Link to post
Share on other sites

The projects on the unity page are quite nice to work through. The first one touches on some of the basic concepts and the third one goes into more advanced coding techniques. 

 

http://unity3d.com/learn/tutorials/projects

 

There is also a manual that explains the theory behind unity concepts and a reference guide that can be used to check functions and search for a specific behavior etc.

 

http://unity3d.com/learn/documentation

Share this post


Link to post
Share on other sites

Thank you! I don't know why I did not find that before. It also contains a stealth game tutorial! Perfect!
 

edit: may also ask: do I need to learn C#? Or is C++ enough?

Edited by GarrettTheThief

Share this post


Link to post
Share on other sites

Well, when I started with Unity I also only knew C++. You'll find that the syntax is almost exactly like C++. So instead of learning C#, do the tutorials and get familiar with the syntax but focus your efforts towards understanding the Unity API. Because the majority of your programming will be based on functions/variables that already exist within Unity.

 

Goodluck smile.png

Edited by PragmaOnce

Share this post


Link to post
Share on other sites

Given your username and your excitement about the tutorials having a stealth project, I think I can guess what kind of project you'll be working on, taffer...

Share this post


Link to post
Share on other sites

Given your username and your excitement about the tutorials having a stealth project, I think I can guess what kind of project you'll be working on, taffer...

Oh yes you can!

Share this post


Link to post
Share on other sites

There is also the Unity Youtube Chanel, wich contains a lot of video tutorials for both scripting and learning to work with the editor.

I suggest for you to watch some of the videos to learn the basic workflow for the engine.

 

Hope that helps.

Share this post


Link to post
Share on other sites

Unity is more beginner-like than UDK (by far, in my opinion) and gives you a cleaner way to get code into your game.

 

All you need is to get good with C# and programming in general, and learn the Unity classes (GameObject and Transform are important).  All you've gotta do is write a script and drop it on something in the game to get the code running.

 

I would suggest using Visual Studio C# Express or MonoDevelop to write your code.  They have convenient features that will help you in the future.

 

Bookmark/favorite these pages, they're very useful to have around for when you need them:

  • This one for the search bar; it lets you search any class in Unity and see all of the methods and variables inside it
  • This one to find information about specific components and how to use them (such as colliders, rigidbodies, lights, etc.)
  • This one for whenever you need to configure your colliders/rigidbodies; it's helpful because at the bottom of the page it gives you a chart of which kinds of colliders will collide with others
  • This one for all you need to know about C# syntax

 

Also, since I believe you're programming a 3D game, you should know how Vector3's work if you don't already.

Share this post


Link to post
Share on other sites

Thank you guys! It really sucks that it isn't c++ compatible, though.

Yeah. The only c++ engines i've seen are cryengine and leadwerks (between those 2, leadwerks even though it isn't free but it's cheaper than unity pro, last time i checked)

Share this post


Link to post
Share on other sites

If you are interested in the art side of this, then perhaps you can use the Thief III engine to create your game. There have been a few decent mods so far and the original developers have also provided the Thief 3 Editor (a modified udk 2.x editor). I think it even provides basic scripting facilities.

 

If you are interested primarily in the technical stuff and want to develop an engine with realtime shadows etc... for your game, then personally I wouldnt bother with products like Unity and suggest you go directly to OpenGL (or DirectX if you want to sacrifice portability). Not only will you find this more flexible, but you also can avoid some of the bagage required by Unity and other generic engines. ( .NET, Proprietary, etc...)

Edited by Karsten_

Share this post


Link to post
Share on other sites

This topic is 1469 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this