I'm now developing games in Unity for 2,5 years.
And in that time I used a lot of tutorials, and now I want to return that favor.
First of all, sorry for my bad english skills (i'm still trying to improve that)
Currently I have a few other unity tutorials also (every week on monday I try to upload a new tutorial).
The comming parts we are going to create a building system like Rust.
Some parts of this system will be changed later on in the tutorial.
So don't directly panic if something isn't like Rust!
Also I didn't player a minute in my life Rust, so some controls are maybe different. But I think the most important parts are exactly the same as in Rust.
But this is the first part and we start with showing the preview of the object!
So I hope you guys like it!
(all the scripts witch I'm reffering to are here)
Unlit alpha shader script:
The script I coppied:
currentpos -= Vector3.one * offset;
currentpos /= gridSize;
currentpos = new Vector3(Mathf.Round(currentpos.x), Mathf.Round(currentpos.y), Mathf.Round(currentpos.z));
currentpos *= gridSize;
currentpos += Vector3.one * offset;
currentpreview.position = currentpos;
Last edited by Gamad on Mon Jul 11, 2016 9:14 am; edited 4 times in total