Playmaker Forum

PlayMaker Feedback => Action Requests => Topic started by: VectorF22 on July 21, 2013, 06:50:03 PM

Title: 'device shaking' and 'device stopped shaking'
Post by: VectorF22 on July 21, 2013, 06:50:03 PM
Hi,

I'm working on an android game and while the 'device shake event' is great, it's only good for 'one shot' events. I could really do with an action that detects the device is still shaking and to also detect when it's stopped.

Thanks!
Title: Re: 'device shaking' and 'device stopped shaking'
Post by: jeanfabre on July 28, 2013, 10:43:48 AM
Hi,

 can you test this action I attached? it works the same way as DeviceShakeEvent only that is fires the event when it's under the value. so when DeviceShakeEvent fires the event, have DeviceStillEvent on the next state to watch for when the device will be still again.

 If that works for you, I'll add it to the shared action section.

bye,

 Jean
Title: Re: 'device shaking' and 'device stopped shaking'
Post by: VectorF22 on August 02, 2013, 06:02:56 PM
Hey Jean,

I've tested it and it doesn't seem to be working... I have it rigged up so that it plays a looping itween in the 'shaking' state . The 'device still event' action is also on the shaking state, but it doesn't fire it back to the first state when the device stops shaking.

Thanks.
Title: Re: 'device shaking' and 'device stopped shaking'
Post by: jeanfabre on August 05, 2013, 03:25:23 AM
HI,

 you need to states for this to work: one that test that shaking started, and you move to the second state that watch for when the shaking pass below a certain threshold.

Have you tried like that?

bye,

 Jean
Title: Re: 'device shaking' and 'device stopped shaking'
Post by: VectorF22 on August 06, 2013, 06:50:21 PM
Hey Jean,

Yeah that's exactly how I had it set up...
Title: Re: 'device shaking' and 'device stopped shaking'
Post by: jeanfabre on August 08, 2013, 03:09:19 AM
Hi,

 bump me next week ok? I'll do a working sample. but I don't have the time right now.

bye,

 Jean