Game Development Community

making sceneWindow draggable.

by rennie moffat · in iTorque 2D · 01/11/2011 (6:54 pm) · 3 replies

I am wondering how I would best make the sceneWindow draggable. I want to make something like Angry Birds, Levels Selection Scene where by the user can drag across the screen to reveal the levels. In this I have considered many approaches but the easiest in theory would be to attach a mouse draggable behavior to the scenegraph but that seems a little iffy.

Any help in this would be appreciated.
Thanks.

About the author

My thanks to Garage Games and the Garage Games Community combined with owned determination I got one game up, Temple Racer and I am looking to build more interesting, fun games for the mass market of the iOS app store.


#1
01/11/2011 (7:26 pm)
No. Don't do that. Have input move the camera, not the entire scene.
#2
01/11/2011 (7:37 pm)
Right, so I am thinking how best to do that.


Have an object that is mounted to camera, then have it draggable?

Hmm, testing indeed.
#3
01/11/2011 (8:13 pm)
Gather the input, interpolate the difference between the current touch and last touch (or gesture), apply the difference to the camera's transform (thus changing its position).