Quantcast
Channel: Latest Questions by areFranz
Browsing all 50 articles
Browse latest View live

Rotate camera with easeout

Hello! I've a script that rotates my camera the more fast the more the mouse reaches the screen boders. float xMouse = Input.mousePosition.x; float x1 = Screen.width * 30 / 100; float x2 = Screen.width...

View Article



Problems with nested coroutines: while loop freezes

Hi, I have a problem with nested coroutines... I have a cube that contains other cubes instantiated by a class. I want to 1- translate up the scene 2- empty the cube 3- translate down the cube 4-...

View Article

Bullet Shoot with RayCast don't destroy onCollisionEnter

Hi All! I've making an FPS Game and i have a charachter controller width attached a spawn object with attached the script for shooting. if (curWeapon == "Sniper") { if (Input.GetButtonDown ("Fire1")) {...

View Article

GameManager class doesn't accept GameObject.Find()

Hi All! I'm makeing a little game in a 3D village with 2D interior scenes (one for each building)... I'm starting with a GameManager componnent to manage the global members and methods like...

View Article

Why the "Detonator Explosion Framework" from AssetStore don't render in...

Hi All! I have imported the free "Detonator Explosion Framework" from the AssetStore and i applied it to a prefab that is instantiate before object deletion. In the game mode in unity it's all right!...

View Article


Shuriken OnParticleCollision SendCollisionMessage doesn't work completely

Hi, I have a Shuriken LASER ParticleSystem with the collision and the SendCollisionMessages enabled. So I need to shoot this laser towards asteroids (Rigidbodies) thet every 4 shoots ere destroyed. I...

View Article

Add an aim to a space ship simulator

Hi All! I have a big problem: i need to add an aim that really point to objects in a 3d space attached to my spaceship. The scene is composed by: - GameObject "SpaceShip" with attached script...

View Article

How to move a ship inside a pipeline

Hi All! I'm developing a pipeline racing game in which a ship moves inside a pipe. I need that the movement is smooth and the ship os always touching the internal surface of the pipeline, and it...

View Article


Game Menus WIth Keyboard Input Control

Hi All! I have a race game with various tracks and vehicles and i'm making the menu for it. I need a menu that has the ability to be controlled by the arrow keys of the keyboard. I have a "MainMenu"...

View Article


How to convert timer to minutes, seconds and cents

Hi All! I have a timer that calculate the time of a lap in a race game. I have the minutes and the seconds: int curMin = Mathf.FloorToInt (lapTime / 60F); int curSec = Mathf.FloorToInt (lapTime -...

View Article

3D camera smooth rotation and mouse wheel zoom

Hi All! I have a problem with a project: a cube in which a camera moves around in the three axis with the mouse. The XY axes are controlled by mouse X and mouse Y, and the zoom (not FOV) with the Mouse...

View Article

Error with nested coroutines

Hi All! I have a problem with a nested coroutine. I have a FileasAndFolders class that crates in the 3D scene a empty game object witch contains a series of icons for files and folders of the desktop...

View Article

Unity 5 and Multiple AudioListeners

Hi All! I have a project in which there are a vehicle with an AudioListener attached to the child camera and an AudioListener attached to an empty object that has the role of playing the countdown...

View Article


How to detect if a raycast ray stop hitting an object

Hi, I need a way to understand in c# when a ray stop hitting an object. RaycastHit boostHit; Vector3 bottom = transform.TransformDirection (Vector3.down); bool prevFinishLane = finishLane; if...

View Article

Unity 5 prefab with FBX and camera as child renders in black

I have a prefab with an FBX model with as child a camera and some particle systems. It's a ship that runs in a pipe. The pipe and the GUI shows correct but the ship renders totally black! How can i...

View Article


How to calculate ship position and rotation in a pipeline with raycasts

I'm developing a little game in which a spaceship navigate in a pipeline, and I need to push the ship down (with a little release and a floating effect) and let it turn and go forward in any direction....

View Article

Boost a vehicle with Input.GetKey with reload delay

I'm already here... I solved the boost on Input.GetKey but now i would like to fit a reload timer before the boost is full again... Here is some code: // MANUAL BOOST if (control && boostKey ==...

View Article


Avoid obstacles with nested coroutines

Hi! I'm making the AI for a race game in a pip and i need to know the way of doing something like: 1. Raycast forward 2. if tag enemy 3. if distance

View Article

How to fire gui button on mouse right release

Hi, I have a menu that shows on right clock and i need that when i release (mouseup) the right mouse button, it fires a gui button (used to change weapons). Here is the actual code: using UnityEngine;...

View Article

Click to move C# with animations and sounds

HI, I'm making a little fantasy game in which tha player moves around on a plane (ground) targeted by a clik (right click). I used the script of Unify Community ["Click to Move C#"][1]. My problem is...

View Article
Browsing all 50 articles
Browse latest View live




Latest Images