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.

Newcomers DBPro Corner / Need Advice On My First Program (DBP)

Author
Message
Hoose
18
Years of Service
User Offline
Joined: 15th Feb 2006
Location: Lost in the corners of my Mind!
Posted: 6th Mar 2006 09:00 Edited at: 10th Mar 2006 07:56
I'm trying figuire out something that I just can't seem to wrap my head around. First off, ***** I'm not planning on remaking Ultima 4 ***** but it was a good example of the data I will be working with.

The way the data is set up is that there is a world data file that outlines where all the tiles are in the world and each hex value translates to a tile image. The main world is made up of 65536 tiles (64 sections (8x8) comprised of 1024 tiles (32x32).

World
|00|01|02|03|04|05|06|07|
|08|09|10|11|12|13|14|15|
|16|17|18|19|20|21|22|23|
|24|25|26|27|28|29|30|31|
|32|33|34|35|36|37|38|39|
|40|41|42|43|44|45|46|47|
|48|49|50|51|52|53|54|55|
|56|57|58|59|60|61|62|64|

Sections 00 & 01
|00|01|02|...|31|32|||1024|1025|...
|33|34|...

That would be all fine and good if all the values worked straight across, but within each section it reads 32 across and then drops down to the next line (32 rows, 32 columns, 1024 bytes) then moves up to the top of the next zone.

OK, now that you have the big picture. HOW would you go about making the tiles display as you move in that direction. Just like if you were playing an RPG and were traveling the countryside. Because when you hit those lines where two sections line up your data would be 1024 bytes off. Attached is the code and data files.

I may be making this harder than it should be, but just can't seem to decipher it right now. I thought I was doing pretty good to figuire out how to convert the data over...

Thanks!
Hoose

[/b][b][/b][b][u][/u]

Attachments

Login to view attachments
Hoose
18
Years of Service
User Offline
Joined: 15th Feb 2006
Location: Lost in the corners of my Mind!
Posted: 6th Mar 2006 15:31 Edited at: 10th Mar 2006 07:44
Deleted duplicate post:
Grog Grueslayer
Valued Member
19
Years of Service
User Offline
Joined: 30th May 2005
Playing: Green Hell
Posted: 6th Mar 2006 20:17
To save you some work... somebody has already remade Ultima 4 using Darkbasic Classic. They even have the source code available for download.

http://www.wizardportal.com/optimaiv/


Hoose
18
Years of Service
User Offline
Joined: 15th Feb 2006
Location: Lost in the corners of my Mind!
Posted: 7th Mar 2006 01:26
Well I appreciate that your trying to help, but I DON'T want to remake Ultima 4. I was just trying to figuire out how you could handle data presented in that form.

I have seen the remake of Ultima 4 (made in DBC, which is great), but he doesn't reuse the original data files. For that I could just create a new data file from scratch like he did.

BTW - Sorry for the previous double post, but apparently newbies aren't even allowed to edit their own posts. How long are you considered a newbie anyway, shesh!

Hoose
Hoose
18
Years of Service
User Offline
Joined: 15th Feb 2006
Location: Lost in the corners of my Mind!
Posted: 9th Mar 2006 01:38
Wow, no real response at all? Did I stump everyone? The data was originally accessed in this manner so there must be some way.

Hoose84

Login to post a reply

Server time is: 2024-09-24 17:40:34
Your offset time is: 2024-09-24 17:40:34