this is not Arduino related so i will be posting it here .
so i played a DOS game a long time ago called "Prince of persia" , and it was great . i haven't done any real programming lately so i decided to write a game similar to that one .
my problem is the drawings , i can't draw the characters and places since i don't have any computer coloring talents . that's why i decided to extract the drawings from the old game itself .
here is a link for the game :
the files that contain the images i need are (PRINCE.DAT , GUARD.DAT , MAP.DAT ... etc)
the thing is i have no clue on the format , pixel arrangement or the resolution .
is there any possible way for me to make sense of the content of these files ? thank you .
Best bet would be to look at the code that displays those and see what it does. That would tell you how the data is arranged. That might be hard. Your other option is to make a guess and try it. If it makes the picture you expect then awesome you're done. If not then make a new guess.
Delta_G:
Best bet would be to look at the code that displays those and see what it does. That would tell you how the data is arranged. That might be hard. Your other option is to make a guess and try it. If it makes the picture you expect then awesome you're done. If not then make a new guess.
thank you very much that's actually a good idea . i did attempt to do it with processing ,but i always get an intelligible image , the problem is that i don't know the pixel depth either nor the distribution of bits for colors . i will continue trying though .
extracting the code is too hard though , since the game is "relatively" complex , so finding the right code would be hard .
Robin2:
What happens if you try to open those files with a good image editing program? It may be able to figure out the encoding.
I would expect the data to be in a format that requires very little calculation in order to display the images.
...R
thank you Robin .
yes i did attempt to do that , but those programs check the beginning of the file for the format data , if that is not found it sends an error code that the file is not an image file .
i did even attempt to insert the data into bitmap files ,but the variance in size causes the same error .
(First result for a very simple, obvious query string, of a subject I have no interest in or prior knowledge of. That's pretty bloody amazing.)
Google is indeed wonderful , but it gave me nothing .
i did search for almost 3 hours .... thank you very much for pointing that out, and it would really be interesting to know what that String was .
amine2:
Google is indeed wonderful , but it gave me nothing .
i did search for almost 3 hours .... thank you , and it would really be interesting to know what that String was .
i searched for .DAT file formats , and old game image and tile storage and graphics in DOS games for hours , the idea that the team would post a file of that specific game on the net didn't even cross my mind ...
well thank you AWOL
One thing I have learned is that if your compiler or interpreter returns a programming error it is usually useful to use the error message as a search term.
I guess the same goes for the names of game programs.
Robin2:
One thing I have learned is that if your compiler or interpreter returns a programming error it is usually useful to use the error message as a search term.
I guess the same goes for the names of game programs.
...R
for what it's worth , i am sorry Robin , for not doing the proper research .