Quantcast
Channel: Answers by "IJM"
Browsing latest articles
Browse All 90 View Live

Answer by IJM

You can use "OnMoseOver" that is something like "Update" but it's called only when the pointer is over the object:function OnMouseOver () { if(Input.GetMouseButtonDown(0)) Debug.Log("Left click on this...

View Article



Answer by IJM

In C# you can do that like this:public float[] MyArray = { 1, 2, 3, 4, 5, 6 };

View Article

Answer by IJM

Yes you can use Unity free if you/your companie had a turnover in excess under one hundred thousand U.S. dollars in the last fiscal year. Which means that, if you earn $100k by the end of the 2010. you...

View Article

Answer by IJM

This is not the right place to ask that type of question, if you want to know why isn't there a Unity player for Linxu you can send e-mail directly to Unity team:http://unity3d.com/company/contact

View Article

Answer by IJM

You actualy need to use physics engine to get any cld working:http://unity3d.com/support/documentation/Components/comp-DynamicsGroup.html

View Article


Answer by IJM

To do something like that you can use ScreenToWorldPoint: http://unity3d.com/support/documentation/ScriptReference/Camera.ScreenToWorldPoint.html

View Article

Answer by IJM

2) Jumping animation is combination of animation and object movement. In every frame the center of the mesh should be on x0,y0,z0. and you shoud move the GameObjec on the y axis and not the mesh it...

View Article

Answer by IJM

I think that this will work: for (var state : AnimationState in animation) { state.speed = -1; }

View Article


Answer by IJM

You can do something like this:public class Ball : MonoBehavior { Vector3 _startPosition; Quaternion _startRotation; void Start() { _startPosition = transform.position; _startRotation =...

View Article


Answer by IJM

var curTransform : ParticleEmitter; curParticleEmitter = gameObject.GetComponent(ParticleEmitter); curParticleEmitter.minEnergy = 8;

View Article

Answer by IJM

I recomend using 32bit bitmaps with alpha channel. In general 24bit bitmpas (Something like Windows BMP or JPG) have Red,Gren and Blue (aka RGB) per each pixel, wich means that they can only suport...

View Article

Answer by IJM

This will help you: http://unity3d.com/support/documentation/Manual/Video%20Files.html

View Article

Answer by IJM

You can do something like this:uvOffset += 1/LinesNumber;Assuming that every line is the same height.

View Article


Answer by IJM

You need to have a collider on the ground (mesh collider for example), and on the object (box collider for example).

View Article

Answer by IJM

Yes, you can do taht. I recommand contacting support@unity3d.com for help. You will need to inform Unity team that you will uninstall Unity from your machine. (Since the license key can be used only...

View Article


Answer by IJM

The error is in the Water.cs (c# script) on the line 182. If you remove that file from your project it will work fine.

View Article

Answer by IJM

Try something like this:gameObject.GetComponent<Rigidbody>().AddForce(Vector3.up * fForce);

View Article


Answer by IJM

Google for "Graphics Gems" books.

View Article

Answer by IJM

Crate an folder named "Resources" in your assets.(If you don't have one) Put your texture in that folder. (For example "TextureName.png") And call this on the trigger:renderer.material.mainTexture =...

View Article

Answer by IJM

Did you call this, to destroy your GameObject:Destroy(gameObject);

View Article

Answer by IJM

Create a new folder in your Assets and name it "Resources", put a white texture of any size (32x32 for example) inside and name it WhiteTexture (It can be BMP, TGA, PNG, JPEG...) and do something like...

View Article


Answer by IJM

You can use this to check for click: var rect = Rect (0, 0, 150, 150); // Rect around your circle if (rect.Contains(Input.mousePosition)) if(Input.GetMouseButtonDown(0)) //Do something on left click To...

View Article


Answer by IJM

You can rotate GUI elements, if that's your question. Take a look at this: [RotateAroundPivot][1] [1]: http://unity3d.com/support/documentation/ScriptReference/GUIUtility.RotateAroundPivot.html

View Article

Answer by IJM

That method looks something like this: return t - Mathf.Floor(t/length) * length; Example: Mathf.Repeat(253.22f, 250f) = 3.22f // You can fit one 250 in 253.22f, and the rest is 3.22f...

View Article

Answer by IJM

By calling a method from a Unity Start() event you are blocking Unity's main thread, until that method is finished. (Your game is frozen) You want to do it in the background, so that you can still...

View Article


Answer by IJM

With animation events. [Click here to learn more :)][1] [1]: https://docs.unity3d.com/Manual/AnimationEventsOnImportedClips.html

View Article

Answer by IJM

This looks like a bug with Unity rendering engine. You have an older GPU, so that might be a problem. (Your GPU supports DX10, but the Unity Editor requires DX11) Try switching Unity Editor to OpenGL....

View Article

Answer by IJM

You can't use UnityEditor in your builds. - How to solve this problem? Create a class that inherits MonoBehavior, that has a public GameObject array, add it to an object as a component. Use your Editor...

View Article

Answer by IJM

Here is an example from the top of my head: //Buffer data private struct BufferData { public int ValueA; public float ValueB; public float DeltaT; } //Buffer private List _buffer = new List(); private...

View Article



Answer by IJM

velocity is a Vactor2, and x is a float. float doesn't have a magnitude property, like Vector2 has. Solution, however, is very simple. You don't need magnitude for one dimension. It is already a...

View Article
Browsing latest articles
Browse All 90 View Live




Latest Images