Destroying a character with multiple clicks!! URGENT HELP PLEASE COLLEGE DEADLINE!!!!
DesignsByJames
Member Posts: 4
I am working on a concept for a game and I need to make it so that when battling the boss you must click the character 10 times before she destroys.
So far I have set my Rule to:
(ClickCount)
Actor receives event Mouse Button is Down
Actor receives event mouse position is inside
Attribute game.killEnemy=0.0
-> Change Attribute game.killEnemy TO game.killEnemy+1
(DestroyMe)
Atrribute game.killEnemy=10
->Destroy Actor
----------------------------
With these rules in place the actor still destroys after the initial click, what am I doing wrong? And how can I change the rule so the actor destroys after 10 clicks not 1.
PLEASE HELP!!!! COLLEGE DEADLINE SOON APPROACHING!
So far I have set my Rule to:
(ClickCount)
Actor receives event Mouse Button is Down
Actor receives event mouse position is inside
Attribute game.killEnemy=0.0
-> Change Attribute game.killEnemy TO game.killEnemy+1
(DestroyMe)
Atrribute game.killEnemy=10
->Destroy Actor
----------------------------
With these rules in place the actor still destroys after the initial click, what am I doing wrong? And how can I change the rule so the actor destroys after 10 clicks not 1.
PLEASE HELP!!!! COLLEGE DEADLINE SOON APPROACHING!
Comments
http://jamie-cross.net/posts/ ✮ Udemy: Introduction to Mobile Games Development ✮ Learn Mobile Game Development in One Day Using Gamesalad ✮ My Patreon Page
Actor receives event mouse position is inside
Attribute game.killEnemy=0.0
-> Change Attribute game.killEnemy TO game.killEnemy+1
change this to
touch is pressed and Attribute game.killEnemy < 10.0
-> Change Attribute game.killEnemy TO game.killEnemy+1
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
SelfAttribute Int ClickCount=0
Rule
Actor receives event mouse button is down
Actor receives event mouse position is inside
Change Attribute self.ClickCount to self.ClickCount+1
Rule
Attribute self.ClickCount = 10
Destroy
You could also increment the could with the Touch is pressed. This will destroy the actor after 10 clicks/touches.