Xavi Montero
  • Member for 7 years, 5 months
  • Last seen more than a month ago
Unity UI square that fills width OR height
Accepted answer
15 votes

Finally I found a way to do it (tested in v5.0.0), in a way that: Does not need code, or conditionals to check orientation. Does not hack with scales and neither needs a reference resolution. In the ...

View answer
How do I check for collision between an ellipse and a rectangle?
Accepted answer
7 votes

I'm going to tell you how to do it with a computationally cheap way in terms of CPU usage. First, let's say that the calculation of seking if a point is "inside the ellipse or not" is not ...

View answer
Why does Unity launch Visual Studio but opens files in Notepad?
Accepted answer
3 votes

Well, it is not a matter of Unity. In fact, Unity sends the file to the Visual Studio and it is Visual Studio that re-sends it into a NotePad. Reason The reason behind is that VS does not open all ...

View answer
In Unity, why is adding a Vector2 and a Vector3 ambiguous but assigning isn't?
3 votes

Let me rename the vars (for clarity): Vector3 pos3d = new Vector3 (1f, 2f, 3f); Vector2 pos2d = new Vector2 (1f, 2f); Answer It is because of the section pos3d + pos2d of the line. This part is ...

View answer
Client-side prediction for movement?
Accepted answer
2 votes

Intro One smooth way to do this is to interpolate for a short period of time if the postions are "near enough" just for a "viewing" perspective, but still have the "proper position" in sync with the ...

View answer