Enemy Health AS@

Subscribe to Enemy Health AS@ 4 posts

avatar for vettinari2 vettinari2 1 post
Flag Post

Hi there everyone !

I have problem with enemy health. those are the scripts

Enemy health part

onClipEvent(enterFrame)) { if (this.hitTest(_root.bullet)) { _root.live -= 1; if (_root.live = 0) {

this.removeMovieClip();
}

} }


Variable on first frame of enemy

var live = 3 ;

Anyone have any ideas ?

 
avatar for JWBSoftware JWBSoftware 106 posts
Flag Post

(_root.live = 0)

should probably be

(_root.live == 0)

 
avatar for draganviper draganviper 1043 posts
Flag Post

^ Why do so many people fail programming 101 lately?

 
avatar for Danishdragon Danishdragon 367 posts
Flag Post

I guess they could use a more beginner friendly IDE.