Cannot control the gravity with device tilt in an iBook on an iPad

#1 (36.8 KB)

Hi. I’ve made a one page prototype of a spelling game. I want the letters to drop when each block that comprises the ceiling is tapped. When the letter is in free fall I want the user to guide the letter into the correct slot by controlling the gravity with the device tilt. Everything works in the preview on my iMac (blocks move; letters drop; except of course the tilt control can’t be used). I’ve embedded the widget in an iBook and downloaded it onto an iPad at our teaching centre (not sure what OS version they’re using). The blocks animate open but no letters drop.

If anyone has any ideas to help me get the project moving forward, I’d greatly appreciate it.


Control gravity with device tilt not working
(Lucky) #2

You’ve got tilt enabled so when someone holds them they’re going off screen since there are no borders around the letters outside.
I did one for the U

And i played with the scene gravity and physics a bit, sadly you can’t dynamically change those variables but on this setting it always drops on my iPad. If you’ve got hype reflect you can test it out on your iPad if you’ve got one.
Hope that helps
word_drop_Minotaur (39.7 KB)


Thanks for the suggestion Lucky. I’ll take any solution that gets results.

But for the sake of bettering my understanding the program I’ll just throw this out there… I’m pretty sure you can dynamically change the Physics (body type) variables of a component (and so the container construct shouldn’t be necessary).

If anyone is casually reading this thread, I’ll just describe the setup briefly. Feel free to weigh in.

When a ceiling tile is tapped, a new timeline is started. The timeline has 3 animated properties:

  1. the tile ‘opens’ (resized)
  2. the tile fades (opacity)
  3. the physics (body type) of the letter directly above it changes from static to dynamic

This works in preview. The change from static to dynamic works very well and the letters go into free fall when the tile is tapped (I moved everything into view to test it). But it did not work on the iPad even when holding it up at 90 degrees (to eliminate the possibility that they are sliding off to the side after becoming dynamic).

I don’t have an iPad so my testing process involves the unfortunate routine of heading into the teaching centre early and signing one out from resources. I’ll try a demo with the letters moved down into view to see what they are doing.

Any comments or suggestions most welcome.



I just thought of something.

When holding the iPad in the landscape orientation perhaps I should have set the Scene Physics Gravity for 90 degrees. I had it at 180 degrees after using the ‘Physics Master’ demo as a model. It was perhaps designed perhaps for the portrait orientation though.

90 degrees* = straight down in landscape?

(*in preview this sends the letters off to the right though)

(Jonathan Deutsch) #5

You are correct that the issue is landscape vs. portrait. Right now the “control gravity with device tilt” does not take into account the landscape/portrait-ness orientation and always has 180° represent falling to the bottom when in portrait mode. We’ve gotten several reports that this isn’t expected, so I may change this in the future.

For your document if you want items to fall into the slots cleanly though I’d probably disable the control gravity with device tilt setting.

Your other comments on using timelines to animate the changing of a property from static to dynamic are correct and your usage of this is intended!


The order of the letters is scrambled and so the slot directly beneath each letter is likely not the correct placement. The idea is to guide each letter, one at a time, into the correct slot using the ‘control gravity using device tilt.’

I’ve booked an iPad from resources for this afternoon so will be able to see if a change in gravity direction solves the problem.

Thanks for the response.


7 posts were split to a new topic: Workaround for Physics gravity direction not adjusting when rotating device