I want to give my all-ready created enemys (objects) a "name" (instance variable) that is different from the others (enemy1, enemy2, enemy3 etc...) as it solves tons of problems for me later on.
I use for that a global number (EnemyName) that should increase every time the "for each" works.
The problem thats driving me mad is that it works on tests but not in the actual project!
It sets all the TileEnemys (objects) to the exactly same name (the global "enemyname"+1)
Actual Project Code:
https://ibb.co/kqBLO7
Test Code:
https://ibb.co/m4RyAn
I would check two things
1-if the Global (EnemyName) from the Actual Project Code: is by mistake Type = Txt instead of Number
or
2-if the (Txt box) where you show the debug names are calling the Right TileEnemy.TagName
example
Every Thick >> Set Txt Box >>To TileEnemy.TagName
Because this sounds weird [quote:1sb986o4]to the exactly same name (the global "enemyname"+1)
specifically this part >> "enemyname"+1
at last if it was wrong it should be "enemyname"+the total Number of Enemies >>not +1 only, all the enmies should have added 1 to the Global, still is wrong but it shows like you had only one enemy calling when is not that's why I will look on those places first