Quantcast
Channel: Answers by "Dreamblur"
Browsing all 56 articles
Browse latest View live
↧

Answer by Dreamblur

Quaternion.SetLookRotation

View Article


Answer by Dreamblur

Backslash. EDIT: UA used my backslash. XD Hold on. `"\""`

View Article


Answer by Dreamblur

Your LateUpdate method isn't closed. The method is OnControllerColliderHit, not OnControllerHit. You have that if(dead) line floating there doing nothing. The last block of code does not belong to any...

View Article

Answer by Dreamblur

Play the sound in the same method that spawns the player. So assuming that there's an AudioSource attached to the game object where the respawn script is attached, just call: audio.Play(); right after...

View Article

Answer by Dreamblur

When you run this line: gameObject.SetActiveRecursively(false); you are deactivating your game object, which means this script, being attached to the game object that was deactivated, will stop running...

View Article


Answer by Dreamblur

if(whatever) { score += x; bonusCheck += x; if(bonusCheck >= scoreToGiveBonus) { // perform bonus function (bonusCheck / scoreToGiveBonus) times bonusCheck %= scoreToGiveBonus; } }

View Article

Answer by Dreamblur

Application.platform returns an enum-type value representing the platform the build is currently running on.

View Article

Answer by Dreamblur

While answering a forum post, I realized what the actual issue was. A static rigidbody would technically be sleeping, and since collision events with character controllers aren't detected by a sleeping...

View Article


Answer by Dreamblur

"active" is not a member of MonoBehaviour. Use "enabled". Change the type declaration of "wire" to your script's class.

View Article


Answer by Dreamblur

The error is telling you exactly what's wrong with your code. There is no overload for the method using those parameters. The method requires an AudioSource and a Vector3 as parameters (and an optional...

View Article

Answer by Dreamblur

[Sort][1] [Sort][2] [1]: http://msdn.microsoft.com/en-us/library/w56d4y5z.aspx [2]: http://msdn.microsoft.com/en-us/library/234b841s.aspx

View Article

Answer by Dreamblur

Once you attach an audio clip to a game object, you'll have access to the AudioSource members. With the game object which the audio clip is attached to currently selected, click on the fold-out option...

View Article

Answer by Dreamblur

Assuming that: Transform house; Transform plane; then either: house.rotation = plane.rotation; or: house.eulerAngles = plane.eulerAngles; should do exactly what you want.

View Article


Answer by Dreamblur

That's fine, as long as no money is made off of such activities.

View Article

Answer by Dreamblur

Game engines generally use tris and not polys.

View Article


Answer by Dreamblur

I haven't tested it in UnityScript yet, but it shouldn't be possible to invoke a coroutine. You're using yield in your function which makes it a coroutine.

View Article
Browsing all 56 articles
Browse latest View live