Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers AppGameKit Corner / update enemy function

Author
Message
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 31st Mar 2015 19:29
Hi.

I created a side scroll game and created function for my enemies that them move from right screen to left.

Now I want when (myenemy[i] = destroy or myenemy[i] = out of screen) load enemy function again.

Please Guide Me.

rneilg
9
Years of Service
User Offline
Joined: 18th Mar 2015
Location:
Posted: 1st Apr 2015 23:20
I created a similar game and what i did was to say that if the enemy moved passed a certain position (in my case left to right) to move it back. You could then decrease the score when the enemy went passed the pont. Also if there is a collision you could increase or decrease the score. Here is the code snippet i used. I am really new to this so I hope I havent misread your question.


Login to post a reply

Server time is: 2024-11-23 11:20:51
Your offset time is: 2024-11-23 11:20:51