|
Hi guys I'm running into a bit of a jam. I have a targeting system that works like I need how ever when I send messages it gets sent to all the gameobjects with that script I've pasted the scripts below and thanks for your help in advance.
(comments are locked)
|
|
Since EnemyHealth is a static var, it stays the same across all enemies. If you take out the static, I think that's what you want... So each enemy has their own health. I tried that it didn't work, but thank you
Jul 25 '12 at 04:45 AM
kangta
Are you sure? Is that what the problem is, that all enemies are having the same health? Try changing an enemy's health via the inspector..
Jul 25 '12 at 04:51 AM
Seth Bergman
Im an idiot I was changing it in the wrong script. Thank you so much for your speedy help.
Jul 25 '12 at 04:54 AM
kangta
glad to help!
Jul 25 '12 at 04:56 AM
Seth Bergman
(comments are locked)
|

What do mean when you "send messages" it goes to all? The F and G keys? Can you be more specific about the problem?
Owen thanks for your reply, however Seth has already point out my error and my code is working fine. but again thank you.