My Enemy Damage Script not working
I've read many tutorials and tried different things but it's not quite working out for me. My enemy has a rigidbody and a box collider, my bullet prefab also has a rigidbody and the circle collider is...
View ArticleHow to access a bool of a specific clone in a collision
So I have a ship flying around and there are these enemies spawning continuously. My problem is that I wanted to make it so that the enemies are safe to fly into for a second after they spawn. The...
View ArticleMy bullet has no velocity after it is spawned.
I can instantiate my bullet but no code i put after it will give it a velocity. Addforce and transform won't work. I keep getting errors maybe because I'm using Unity 5. Please help me. I can post the...
View ArticleHow to use 1 script for multiple enemies ?
I want to make multiple enemies with 1 script, if I just duplicate the prefab with attached script, 1 die, all will die. How can I make it with just 1 script, so don't need multiple script ? My script...
View ArticleAI getting stuck on corners
Hi im new to game making and know 0 coding but "Understand" bits and pieces. I am attempting to make a chasing AI that always follows the player but when I turn a corner or in this case a hall with a...
View ArticleWhy won't my enemy ship shoot?
Hi I am adding an enemy space ship to my now finished second tutorial game. I am trying to get it to shoot and be able to control the speed at which it shoots. I tried doing a similar script to the...
View ArticleInt value only changes after I stop playing
I made buttons that when I press them. it lowers the hp of the enemy in the scene, however when I press them nothing happens until I press the play button again to stop playing. After I do this it...
View ArticleTopdown: Stop Enemy Rapid Firing
Hey basically I have a hostage rescue game whereby the player must rescue hostages whilst avoiding or eliminating enemies. I am using the A* path algorithm with radius detection for the enemies whereby...
View ArticleNearest Enemy To Team (Without Crowding!)
Hi all, I have a script to assign the nearest enemy to each of my 3 team players. However I do not want team members to crowd to the same enemies. They should distribute themselves evenly otherwise...
View ArticleAI fighting game
Hi :) I am creating a 2D fighting game, using Dragonball sprites. I don't know very well how can i make the enemy.. Someone can help me or give me some links for the Artificial Intelligence of the...
View ArticleEnemy shouldn't see you through walls
Hi folks, I am using Javascript and this is my script I have for now attached to my enemy. var Target : Transform; function Start () { Target = GameObject.FindGameObjectWithTag("Player").transform; }...
View ArticleBoss Health Bar
Okey, so basically I am trying to create a boss health bar that follows the enemy (above his head) and if player collides, it drops down from 100 to 80. The script should be c# and it's 2D. This is my...
View ArticleEnemy Sliding and Falling at the same time
Howdy again, I've been trying somethings to get my enemy to slide, that was answered [here][1]. but now, I've got a problem with getting it to slide and fall at the same time. I'm trying to get the...
View ArticleMaking Enemy Retreat
Hello! I'm trying to make an enemy retreat after so many seconds after it's spawned. I tested out the transform.position and the enemy moves straight towards, so I know that part works. However, when I...
View ArticleIs this the most efficient way to attack the closest enemy?
BLUF: Is the C# code listed below an efficient way to attack the closest enemy? Hello all, I am an experienced level designer and took the plunge into unity about five days ago. I work full time so...
View ArticleUnity how to make different enemy spawn one at a time with increased speed
Im trying to make it so when an enemy spawn a different enemy will spawn in that same spot but the next enemy will be faster (increased speed) it's like wave's if you beat the first enemy the next one...
View ArticleEnemy Pirate Ship AI
Hello, I am making a pirate game. I'm trying to achieve an enemy pirate ship AI. I've made an attempt but then scrapped it because it was terrible. Basically one idea I had was for the ship to follow...
View ArticleNeed help with enemy script (C#)(2D)
So I a script where the ufo is supposed to go the other direction when it touches a certain object, but the bool I am using to do this wont go true on the collision, here is my script for it. float...
View ArticleHow To Select Random Enemy From Array
How would I select a random enemy from an array index. So far I have made this script that spawns all enemies from the array, instead of picking one random enemy from the array. I can post more code if...
View ArticleEnemy atributes script
Hi there guys! So, im new to c# scripting, and i want to know how do i create anything similar to an reference script. To be more clear, i want to create an script like : public class EnemyAtributes:...
View Article