Quantcast
Channel: Questions in topic: "follow"
Browsing all 536 articles
Browse latest View live

Mouse follow help

I have a 2D object with the camera following from above, my issue is I want the object's (a spaceship) nose to follow the position of the mouse while the right mouse button is held down. I cannot for...

View Article


Homing projectile

alright so new to programming sure its something simple so I have my enemy like character looking at the player and shooting but I want to bullet to homing onto player also so trying to use the method...

View Article


2D Object following the cursor without glitchyness at the center

I lack the technical know-how to ask this question in the title... I have a 2D square that follows the mouse cursor. The red line connects the player and the mouse. I then extend this line for...

View Article

I can't get a "victim" (can be seen as enemy) to follow the player within a...

I recently started working for an IT company and I need to develop a 2D game that allows people to practice what to do in case of a fire. Now one of the things is the player having to get a victim...

View Article

Homing Missiles that target where you were

I have a code that is on a prefab of a missile that is created by a separate object. Its position is then controlled by this code. I'd like the missile to lock onto the player's position when the...

View Article


How to link a follow script to the existing ThirdPersonCharacter animator

I'm trying to link a character's follow script to the existing ThirdPersonCharacter (Ethan) animator, but the animation doesn't play. I get no errors. Here is the current script, I used part of a...

View Article

How do I find another prefab based off a numerical variable? [2D, C#]

Hey, So I have a 2D scene where you can control a ball and make it jump, etc. I want to have 5 other balls trailing it in a line (like a snake), evenly spaced, and when you stop, the trailing balls, I...

View Article

Question about having a Rigidbody follow another GameObject via forces.

_disclaimer_: I'm extremely new to Unity (second week) Hey guys, as an intro to the physics system of Unity, i'm making a sword fighting game. I've got most systems i'm trying to build working, but i'm...

View Article


How to make player go to and eat all food objects on the screen

I've been trying to make a 2D game recently where the player moves around the screen and eat all the food objects that appear. This means he moves to the closest food object, eats it, and then move on...

View Article


Enemy AI script for 2D platformer

Hello! I'm trying to make a 2D platformer game and I wish to add an AI function to the game. The problem is that I don't really know how to make it work. The AI is supposed to have the same functions...

View Article

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 Article

object 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 Article

Model 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 Article


I 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 Article

Object 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 Article


Moving 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 Article

Follow 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 Article


How 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 Article

How 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 Article

Rigidbody.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 Article
Browsing all 536 articles
Browse latest View live


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