– Touch released problem – example project included –
Hi there,
I am having problems with something. I'll try to explain it as simple as possible. I appreciatie your help.
I have a rule which has a when touch is released condition in actor 1.
- change alpha to 0
In this rule (!) there is another rule with another condition:
when game.attributeX = 1
- change alpha to 1
- change game.attributeX to 0
Then I have actor 2.
This has the following when touch is released condition:
- change game.attributeX to 1
Now when I click actor 1 it changes actor 1 alpha to 0
Great!
But, when I click on actor 2, actor 1 turns back to alpha is 1
IT SHOULDN'T because actor 1 does not get a touch released condition.
I have the file here so you can see what I mean.
If there is someone who knows an easy way around this please help me out. I need a function like this to work for a complexer set of rules.
Took me half a day to narrow my problem down to this. Pfew!
http://dl.dropbox.com/u/21686348/ReleaseBug.gameproj.zip
I am having problems with something. I'll try to explain it as simple as possible. I appreciatie your help.
I have a rule which has a when touch is released condition in actor 1.
- change alpha to 0
In this rule (!) there is another rule with another condition:
when game.attributeX = 1
- change alpha to 1
- change game.attributeX to 0
Then I have actor 2.
This has the following when touch is released condition:
- change game.attributeX to 1
Now when I click actor 1 it changes actor 1 alpha to 0
Great!
But, when I click on actor 2, actor 1 turns back to alpha is 1
IT SHOULDN'T because actor 1 does not get a touch released condition.
I have the file here so you can see what I mean.
If there is someone who knows an easy way around this please help me out. I need a function like this to work for a complexer set of rules.
Took me half a day to narrow my problem down to this. Pfew!
http://dl.dropbox.com/u/21686348/ReleaseBug.gameproj.zip
Comments
I think I have a fix.. Is this what you want: if it is.. Ill send you the fixed project file..
@Rob2 Okay, I didn't know. I thought it only counted the moment I released.
So how can I make actor 1 not change his alpha when actor 2 is released...
Thanks both!
Lump Apps and My Assets
This is my way of doing this :
In your actors make a self attribute - boolean - call it "I've been touched"
Now make a rule :
When touch is PRESSED
Change "self.I've been touched" TO true
Timer after 0.2 sec (RUN TO COMPLETION)
Change "self.I've been touched" TO false
Now another rule
When "self.I've been touched" IS true
When touch is released
BLA BLA BLA (here put everything you have in your touch released)
(Might be after the weekend though, I'm about to call it a day)
Lump Apps and My Assets
Funny thing is I've been using GS almost every day for over a year and never realized the touch release function wasn't a momentum thing but a constant state.
@P-O-M this @ thingy doesn't work on your name ;(
Lump Apps and My Assets