How do I play sound when system pick nearest

Get help using Construct 2

Post » Wed Jan 25, 2017 3:04 pm

How fix this event?
https://www.dropbox.com/s/pvtrfu0cwbmqc ... 6.png?dl=0

Expected result
Every time when arrow jump to nearest meteor audio should play sound
B
25
S
8
Posts: 219
Reputation: 2,181

Post » Thu Jan 26, 2017 12:24 am

You'd have to keep track of which meteor was jumped to last and then play the sound if the value changes. For example, store the UID in a global (LastUID):
if( meteor.UID <> LastUID)
-> set LastUID = meteor.UID
->Play sound
ImageImageImage
B
71
S
22
G
257
Posts: 3,790
Reputation: 142,696


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 6 guests