Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 04-20-2011, 07:35 PM   #1 (permalink)
Registered Member
 
Join Date: Sep 2010
Posts: 139
sumosumo84 is on a distinguished road
Default Infinite view, and camera following.

Hi I am making a little game. The reason I am putting it in the iphone sdk dev topic is because it doesnt have to do with gameplay, but more normal coding that someone might know how to do.

My game is going to have an object falling, for any distance, so thats why i need infinite distance. Is there away to have infinite distance? and how?

My second question is how to make the camera follow the object?

I know that there is no "camera" but you, the reader hopefully know what I am talking about.

Thanks - sumosumo84
sumosumo84 is offline   Reply With Quote
Old 04-21-2011, 02:50 AM   #2 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

maybe you should consider to use cocos2d, a objective-c framework for game development. In this for example already exist a camera object


If you want not use it, you should provide more details (what are you using, what you want to do exactly, etc..), an object falling can be simulated also moving the other objects and keeping it stopped, so that seem that it is falling down.
__________________
dany_dev is offline   Reply With Quote
Old 04-21-2011, 07:17 AM   #3 (permalink)
Registered Member
 
Join Date: Sep 2010
Posts: 139
sumosumo84 is on a distinguished road
Default

Ok, here are a few more details.
1) It will be a ragdoll falling, with ragdoll physics of course.
2) In the way I programmed the ragdoll, it has to be falling, I can't have the objects moving around it with the ragdoll stationary.
3) the objects it is falling through will be random.

I was thinking that maybe I could have a 4000 by 4000 scroll view, and have it autoscroll in proportion to where one of the ragdoll's points are. I would then have the random objects dissapear after they left the view, so when the ragdoll hit, say >3800 it would instantly go back to the top, and create more random objects. Tell me if this would work.
Thanks - sumosumo84
sumosumo84 is offline   Reply With Quote
Old 04-21-2011, 09:26 AM   #4 (permalink)
Senior Member
iPhone Dev SDK Supporter
 
Join Date: Aug 2008
Location: Memphis, TN, USA
Age: 24
Posts: 3,983
smithdale87 is on a distinguished road
Send a message via AIM to smithdale87
Default

Seems like it would be much less confusing to do what dany_dev suggested - ragdoll stationary and everything else around it is moving. This will give the same "falling" effect. The user wouldn't know the difference. Additionally, your view now can be a fixed size and you dont have to worry about placing the doll back at the "top" whenever it reaches the bottom.
smithdale87 is offline   Reply With Quote
Reply

Bookmarks

Tags
camera, distance, infinite, ragdoll, view

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 345
13 members and 332 guests
dansparrow, dre, iOS.Lover, LezB44, lorrettaui53, Nobbsy, Objective Zero, oztemel, pbart, samdanielblr, sledzeppelin, thephotographer, Trickphotostudios
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,663
Threads: 94,119
Posts: 402,896
Top Poster: BrianSlick (7,990)
Welcome to our newest member, LezB44
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 01:50 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0