Quantcast
Channel: Latest Questions on Unity Answers
Browsing all 171066 articles
Browse latest View live
↧

Particle System Instantiate's With Original Rotation - C#

I created a particle system that emits sparks when a Raycast hits a collider. It works, and instantiates properly, except for the rotation of the particle system always keeps its original setting. It...

View Article


Will finished Unity games be ready for distrubtion?

If I were to complete a game in Unity, would I need to take additional steps to make it compatible with Steam specifically. Possibly other websites. Thanks.

View Article


c# list help!

I have a database of cards that I'm trying to make copies of the cards and add them to a new decklist but I keep getting an out of range error when using a list from one script in another script. When...

View Article

Having trouble with simple 2D movement

Hello Everybody, I'm quite a noob at scripting, and for days i've been working on this script to make my character move and jump (2D platformer game). After long hours of understanding the errors i...

View Article

C# Error:Expression denotes a `type', where a `variable', `value' or `method...

So im converting this script from Java, running into some errors error CS0119: Expression denotes a `type', where a `variable', `value' or `method group' was expected Im getting it twice Heres my code...

View Article


Zombie Round Script Help

I have a small problem with my zombie round script I've been tweaking. I've fixed 5 errors I've gotten with the script but I can't figure out what is causing an "expecting ), found :". But I've changed...

View Article

how to adjust the height of the camera to the terrain

hi guys. I am currently working an rts game.as of now my camera moves when the mouse pointer is scrolling but the problem is that the environment that i am using is a dessert in which the ground is...

View Article

Can't run Third Person MMO Controller demo project

I am trying to run the Third Person MMO Controller demo project from the Asset Store... https://www.assetstore.unity3d.com/#/content/917 I clicked the "Open in Unity" button and then "Download and...

View Article


Convert GameObject in CarControl

I have a script where I have a variable of type: var Cars: CarControl; And I have one GameObject in the Hierarchy called "PickupRed" which possesses the "CarControl" Active scripting. How do I put the...

View Article


Tween between two Mathf.Sin oscillations??

I'm stumped. I'm using a simple formula to smoothly oscillate a game object up and down. I can, say, make it have a large range and move slowly, like this... void Update() { transform.position = new...

View Article

Text display after a certain time after the entry into trigger.

I wrote this script: private var enter : boolean; //var off: boolean = false; function Start() { enter = false; } function OnTriggerEnter (other : Collider){ if (other.gameObject.tag == "Player") {...

View Article

I need help converting this script to tou

I am trying to develop a JavaScript that will allow me to rotate the character in z axis by swiping left and right android // Smoothly tilts a transform towards a target rotation. var smooth = 2.0; var...

View Article

Curving bullets

I've been programming for a bit over a week now. I'm working on a 2D-scrolling shooter with 3D visuals. The idea is for the game area to fly around the 3D world. Hence, everything that happens...

View Article


Only assignment, call, increment, decrement, and new object expressions can...

Hi there, I have been this [tutorial][1] and seeing as I have never used C# before I have just been copying it exactly but I run into 2 errors in this code: `for(int i = 0; i < sizeX; i+) { for(int...

View Article

Synchronously loading a texture from an asset bundle

Hi! I used to have some code that loaded textures from the Resources file. Something like this: myTexture = Resources.Load(pathToTexture) as Texture; Unfortunately, the file has grown so big that I was...

View Article


Can I convert numeric types in a Shader?

I have two textures I need to process in a shader (depth maps). One is float, the other is short (integer). Can I do some kind of type conversion? Or are shaders able to compare floats and ints?

View Article

Best way to ignore y component for certain collisions?

I have a sort of top-down shooter game I'm working on, so for the bullets' collision I only want to check for x and z positions and ignore the y. An obvious way to do this would be to make all the...

View Article


I have a problem. Log : Couldn't set project path to ...

I have a issue now. I installed unity 3D and loaded sample(RenderingPluginExample42) but I stuck in problem that show 'Couldn't set project path to: C:\...\...' in the log dialog after I pushed the...

View Article

(C#)Accessing a GameObject from a class, inside another class. On collision...

Hello whoever might be reading this. First off, i'd like to apologize for any bad grammar that might occur. English is not my main Language. So, my problem is so : I got a script(lets call it scriptA),...

View Article

Moving the camera with mouse not working

Basically I'm very new to C# and despite being able to move my player (cube) forward,back,left and right, I can't work out why I can't rotate the camera with my mouse which is attached to the cube....

View Article
Browsing all 171066 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>