Hi there! This is my first time posting here, but I'm really confused and could use some help:
My code is a Tower Defense style game where enemies come through and are shot by the player placing troops. I was trying to ensure that the troops hit their target each time, but everything I try only seems to apply to one troop. The problem is that the opponents are clones of one sprite, so I have to use UID's to figure out which one to track. I thought I figured it out, but for some reason the code only applies to the first troop I place?
Here is the code that I am using; I think it's the only code that affects bullet direction, but I will also include my .C3p to be sure.
BsicTroop.UIDbullet is the bullet's UID, given to the Basic troop it was fired from.
BsicTroop.Turret.TargetUID is the UID of the target the turret is aiming at.
ENemies is a group of all of my Enemies including my basic enemy.
:( Like I said, this method seems to work for the first one I place, but not for the second, which simply uses the turret's angle to shoot, which doesn't work since the bullet is coming from an img point.
My file: 1drv.ms/u/s!AhvNCTqQh6yBjksNn5Oiolms3vSR