Can you Shake the iPod to produce sound?

butterbeanbutterbean Member Posts: 4,315
edited November -1 in Working with GS (Mac)
Just wondering, I did a search but couldn't find if this is enabled yet?

Comments

  • EastboundEastbound Member, BASIC Posts: 1,074
    Seems like you would just need 1 attribute named prev_y.

    Every .1 seconds, check if the accelerometer Y is .5 (or whatever amount you choose) away from prev_y, and then set prev_y to accelerometer Y.

    So there's no function for shaking, but it seems like you could check for sudden jumps in the accelerometer to determine shaking.
  • butterbeanbutterbean Member Posts: 4,315
    Thanks guys I'll test this out later :)
  • ORBZORBZ Member Posts: 1,304
    The play sound behavior has a pitch attribute. Bind that to accelerometer data. :)
Sign In or Register to comment.