|
Post by eRat on Jan 5, 2005 19:41:34 GMT -5
Another iso tryout in making.
How to make game preload all rooms next to players room so that you keep walking and there's no visible room change. Character just walks from room to another and game loads all rooms next to character's room and adds them on board.
Probably can't be done by rooms, rather by loading background sprites etc, but it should work so that also code of the 'room' was loaded in memory similar fashion to rooms so that only code next to player's room would be preloaded.
If you didn't understand a word of that mess try this: Check your keypad. Think the player's room as button number 5. The game would load room 5 and all the rooms next to it, which means it would load all numbers (rooms) from 1 to 9. If character moved to north-west he would end in room number 7. When he was in room 7 game would reload rooms 4,5,7,8. num lock, / and 3 rooms (buttons) left from keypad number 7.
How would I start coding this kind of room preloading system?
- eRat
|
|
|
Post by IsmAvatar on Jan 6, 2005 17:08:45 GMT -5
Check out the more recent posts in this topic: ismavatar.proboards15.com/index.cgi?board=qanda&action=display&thread=1092960491It is not easily obtainable, and to be true, of all the things I've done in my coding days, I've only barely attempted it, but never really went the whole way through with it. It's very difficult to obtain. So far the best method I've seen is just to have 1 huge room. Deactivate instances outside of the screen to prevent slowdown (reactivate them when they enter the screen region).
|
|
|
Post by megamushroom on Jan 6, 2005 18:19:58 GMT -5
as far as I know, only one room can be loaded at once?
And the only way I can think of doing it, is like Ism's idea. Deactivating instances and re activating them at key points. Something which isnt too hard to do, once you set up a good system of doin it. (arrays will help)
|
|
|
Post by weckar on Mar 13, 2005 8:13:40 GMT -5
what if rooms are identical at the edges?
|
|
|
Post by RiChArDfLoOd on Jun 20, 2005 16:21:49 GMT -5
even if they are identical at the edges the new room would have to load and it would look sloppy. the best way is to activate and re-activate instances as said earlier.
|
|
|
Post by ss32 on Jun 27, 2005 8:08:30 GMT -5
you have to put a peice of the other room inside the current room, and make sure it is enough so that the view will never leave the room.
|
|