0
votes
1answer
135 views

Could you explain this calculation of tiling and offset?

I don't understand why we add +colNumber when we calculate the offset = Vector2 ((uIndex+colNumber) * size.x, which gives us x=3 for the index 13, which is the square located at the coordinates x:1, ...
0
votes
0answers
124 views

Dynamic load and unload material

For targeting multiple display resolution, I focus on using MultiPlatform Toolkit usage. In which I found following statement in tutorial section for dynamically handling materials. "Just remember ...
1
vote
1answer
592 views

Create sprite renderer using custom material

I have done following thing. Create Material Attach sprite with texture type as Texture Add sprite renderer component to game object Assign material to it that I create in last steps There is no ...
1
vote
1answer
179 views

Depth write and depth test in Unity

Scenario: several objects (o1, o2,.., on) have to be rendered with the z test disable, but the z values must be written to the depth buffer. In another pass, some other objects (t1, t2,..., tm) need ...
0
votes
1answer
197 views

Set alpha cutoff value Unity3d

I am continuing my previous question( link ). Now its working as per this demo. and the coding written to set cutoff is here : function Update () { renderer.material.SetFloat("_Cutoff", ...
0
votes
0answers
225 views

Importing materials along with terrain from Bryce

I've created bunch of terrain in Bryce, and I've managed to import the most basic part of it without any fuss. However, anything more complex (mountains, etc) cannot be imported without the material ...
6
votes
2answers
489 views

Detecting Light Intensity Around Characters

Later Edit Since there seemed to be a bit of confusion: I am asking this for purely didactic reasons, I'm not searching for the most efficient solution. Reformulated question: I'm working under ...