Looking for help with orbit/follow player script vector math calculations
So basically I have an object, a 3D menu, attach itself to a game object when that object is selected. The camera is a first person camera (actually this is for a HoloLens app), so the player can walk...
View Articleobject follow mouse on x-z plane with angled camera
hi, i have 3 cameras placed on the scene and user can switch between them. in each of cameras user can drag a wall and place it somewhere that he/she wants. now the problem is i want the object (wall)...
View ArticleModel wont follow gun
Hi all. I have a animated model downloaded from Unity Asset Store and I'm trying to add a muzzle flash on it that gets activated when enemy shoots. Well everything is working fine so far, until enemy...
View ArticleI need help with 4 characters following a line order script
Hello guys, Here is what i'm trying to do: I have 4 characters. I need them to always return to the initial position between them after 1 second. I mean, I have 4 characters, the first in the line, the...
View ArticleObject heading towards mouse click/ touch position, script improvement.
Hi all, Just so it is clear, I am quite new to the programming. I am learning by creating my first game for android , it is a simple ** Breakthrough/ Arkanoid** clone. I got my script for the paddle...
View ArticleMoving behavior of following gameobjects
Hi, I’m trying to clone this arrow game from ketchapp which I don’t intend to publish, I’m only doing it for learning purposes so don’t hate me for that. Anyway I’m using Unity and I’ve programmed the...
View ArticleFollow Game Object? (keeping set distance)
Hey gang, I've been looking around and trying to find away to make a trail of objects following a leader, (like of the old shooter games) I have my ship moving and looking at its "Leader" how do I keep...
View ArticleHow do I create AI with a good side and evil side?
Basically the script I have takes uses a trigger. when something with the tag player, GoodGuy, or Enemy collides with the trigger, the AI with the collider should follow the collidee. The problem is,...
View ArticleHow to make two characters to go to the direction of an touched item on a...
Hi everyone, I'm doing a 2D platformer with two players on a single screen with input touch to mobile. The two players are on the same screen, each one has its own side, and they move to where I tapped...
View ArticleRigidbody.MovePosition doesn't look smooth
My plan is that a gameobject with a rigidbody attached to it should follow a target object. In my script the gameobject does follow the target but it doesn't look smooth. Is there any other way to make...
View ArticleNavmesh follow and stop at a distance
Hi so what im trying to create is. the play can right click on an enemy and he will follow at a certain distance. which is working fine. but what i want it to also do is stop at that distance too....
View ArticlePlayer follows mouse, but I need only Y
Hi everyone! as you can read in the title I have this script that follows the mouse in X and Y axis, but I only want it to move in Y axis. I'm a total noob so I have no idea how to do it, here's my...
View ArticleUnsmooth vehicle-following camera
Hello, I have written a smooth vehicle-following camera, but for some reason, it is shaky, like it was not updated often enough. I've read several questions about this. Some people suggest to use...
View ArticleFinding name of gameobject that entered a trigger
I'm trying to create a script that has a game object follow another game object that enters the collider. In order to do so, I've tried referring to the object that entered the trigger as...
View Articlehow to make the camera follow the player only in one axis (the z axis)
im making an endless runner game and i want that the camera follow the player only in z axis im using the simple "roll a ball" unity tutorial camera script using System.Collections; using...
View Article(C#) Follow target (script) transform target PREFAB
![alt text][1] ![alt text][2] [1]: /storage/temp/96204-follow-target.png [2]: /storage/temp/96205-prefab.png Hi everyone! I want to use the script "follow target" with a prefab but I don't arrive to...
View ArticleHaving Trouble animating camera at start of game
I am trying to have it so that when the game starts my camera starts facing the player character then animates to the top down perspective. This is a top down endless runner type game. At the start the...
View ArticleArrow follows nearest target please help
Hi, How to make the arrow follow object with "Enemy" tag Here is the script : #pragma strict var Speed : float = 20; var relativeDirection = Vector3.forward; var duration : float = 1.0; var shooterTag...
View ArticleSame script execution order issue
Basically I want to know about script execution logic. At present same script added into 5 different game object but script is not executing in sequence though object exist in game in sequential order....
View Articlehow i can make player 2 go to follow my player again
i have a game that i want player 2 follow player1 and shoot to our same enemy and it works but after the enemy has died it doesnot follow player again it state is follow player and it go to the follow...
View Article