Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / How Would I go About Gravity collision with loads of floor tiles

Author
Message
helpfull programmer
15
Years of Service
User Offline
Joined: 30th Jul 2009
Location:
Posted: 30th Jul 2009 19:51
hello,

this is my first forum Message so i don't know what to expect.
i have been making basic 2d platform games but i wonderd how to do gravity collision on a mass of floor tiles eg. 30, i have been using 2 atm so i just did one if () function for each tile but i don't want to do 30+

thank you very much

helpfullprogrammer.
Phosphoer
16
Years of Service
User Offline
Joined: 8th Dec 2007
Location: Seattle
Posted: 31st Jul 2009 00:12
Ideally you would have an array of tile objects, which you could then loop through and check each one in the loop.

psuedo-code:


helpfull programmer
15
Years of Service
User Offline
Joined: 30th Jul 2009
Location:
Posted: 1st Aug 2009 19:30 Edited at: 1st Aug 2009 23:02
how would you use a array with Dark GDK? it just won't unwound

Login to post a reply

Server time is: 2024-10-01 08:35:36
Your offset time is: 2024-10-01 08:35:36