Jump to content

Dune2K - High Resolution


CCHyper

Recommended Posts

I fixed the glitches. Please give feedback if it works or not. I think it works rather perfect.

 

--------------------------------------------------------------------------------------------					QUICK README--------------------------------------------------------------------------------------------1] Put all the files from the zip in the main Dune 2000 folder.2] Overwrite the .r8 and .r16 files (MAKE SURE YOU HAVE A BACKUP!). Credits towards mvi.3] Run the .exe file.*4] Install N.Kindt patch if you haven't done already.5] Play!--------------------------------------------------------------------------------------------Note: Patch works on orginal files of Dune 2000, so have no mvi large menu patch installed!--------------------------------------------------------------------------------------------The patch will convert all background images and .uil files to the resolution of 1024 x 768.The patch makes a backup of the original .uil and .tga files. There is no backup of the .r16 and .r8 files that you have overwritten earlier.*You need the resolution patch from N.Kindt (and mvi) from:  by D2k Sardaukar (2013). Version 1.0.

 

 

For those that have Python 3 or higher installed you can just run these two scripts from within the main folder of Dune 2000:

d2k_1024_patch_v1_python.zip

 

(of course have N.Kindt and mvi patches done already, but not mvi large menu parts installed, this means only overwritten .r8 and .r16 files)

 

EXAMPLE:

or2fio.png

 

 

edit/offtopic: Sorry, but making an .exe from a python file gives not one nice .exe, but a bunch of files. If anybody knows a way to make it into one .exe, please say so.

  • Upvote 2
Link to comment
Share on other sites

Nice, N.Kindt and I will be releasing a patch together when it's finalised, would be great if we could include your scripts too, I'm sure I can bundle it all up

You're free to adjust my script to C(++) or what you are using, to keep the patch file size small. The python code is nowhere near hardcore programming and I commented the code as much as possible.

 

As far as I know there are only three remaining problems:

1 The crash when you click on the scroll (build) buttons.

2 The crash when viewing the world map.

3 The pop-up text of the menu's is not aligned with centred menu's of 1024x768.

 

Where problem three is not really a biggie.

 

You guys got a hunch at how to solve them?

Link to comment
Share on other sites

Good work D2k Sardaukar. Don't see any problems with Python executables and keeping this in Python. Usually a small script turns to around ~3 MB if compiled with CxFreeze.

 

1 The crash when you click on the scroll (build) buttons.

 

This is related to UI resources AFAIK. mvi would know more here.

 

2 The crash when viewing the world map.

 

Haven't experienced this one. How to reproduce?

 

@mvi

Minor bug: The energy bar seems to span the whole y axis down where it's only a small part of the side bar.

Link to comment
Share on other sites

Good work D2k Sardaukar. Don't see any problems with Python executables and keeping this in Python. Usually a small script turns to around ~3 MB if compiled with CxFreeze.

 

1 The crash when you click on the scroll (build) buttons.

 

This is related to UI resources AFAIK. mvi would know more here.

 

2 The crash when viewing the world map.

 

Haven't experienced this one. How to reproduce?

 

@mvi

Minor bug: The energy bar seems to span the whole y axis down where it's only a small part of the side bar.

Thanks!

 

For problem 2, start a new game (campaign) from the main menu and just keep going until you hit the world map.

Link to comment
Share on other sites

Bypassed the crash to see the stride problem coming back. Guess there is more work needed with the D2K resources. Here is how it looks like.

 

Mission select:

 

yjvuejfnmygx4765623a.png

 

Mission description:

 

xl5k0khp0p7j0hjw2dsc.png

 

First Atreides mission looks ok and playable just fine:

 

misylgkhqx6p3hj9j3je.png

 

 

  • Upvote 1
Link to comment
Share on other sites

Strange, especially that the mission description is now broken while when starting a mission from the mission selector gives no artefacts.

 

What do you think can be the cause? Most images used for the world map are just bitmap images from data/UI_GFX folder and should not be effected by resolution, right?

 

edit: I also discovered a bug in my script or something hard coded in Dune 2000. The score on the score-screen isn't centred. I'm gonna take a look if it's my script, I got a hunch.

 

edit: I'm talking about the score-screen from practice game and I got no idea what is causing it.... not my script, I can give you that. :)

Edited by D2k Sardaukar
Link to comment
Share on other sites

Haven't tested D2k Sardaukars patch yet.

 

*What do you think can be the cause? Most images used for the world map are just bitmap images from data/UI_GFX folder and should not be effected by resolution, right?*

Same problem, Dune thinks it's blitting images for 640x480 resolution (correct) into a 640x480x2 bytes of memory (incorrect). 0.6 pixels of each image line land on the same scanline showing the distorted image. To fix that the images must be resized to fit new resolution. Maybe the mission desc is different from the other one.

 

p.s. Looks like my posted images disappeared.

  • Upvote 1
Link to comment
Share on other sites

Nice, N.Kindt and I will be releasing a patch together when it's finalised, would be great if we could include your scripts too, I'm sure I can bundle it all up

make a program for dynamic resolution switching also...

World map is not working...

Dk sardaukar nice job...

Link to comment
Share on other sites

Haven't tested D2k Sardaukars patch yet.

 

*What do you think can be the cause? Most images used for the world map are just bitmap images from data/UI_GFX folder and should not be effected by resolution, right?*

Same problem, Dune thinks it's blitting images for 640x480 resolution (correct) into a 640x480x2 bytes of memory (incorrect). 0.6 pixels of each image line land on the same scanline showing the distorted image. To fix that the images must be resized to fit new resolution. Maybe the mission desc is different from the other one.

 

p.s. Looks like my posted images disappeared.

You are right, it's the image size, but what should it be. How do I need to resize the images? I got no crash by doubling width and height in header of all bmp and tga images and just adding \x00 to fill it up.

 

EDIT:

I forgot centring the second/first worldmap in my own script, fixed that and got a step closer.

Mission briefing works normal, loading, saving, everything. Only need to be able to resize bmp files... which is different than tga files...

29f6ofm.png

Edited by D2k Sardaukar
  • Upvote 2
Link to comment
Share on other sites

I love this mod! I've waited a long time for someone to make something like this! :) Nice work :)

 

Question though...Is it a possability that one day there will be a patch with 1680x1050 resolution? I would love that :)

  • Upvote 1
Link to comment
Share on other sites

The initial crash is caused by writing out of bounds. If you resize the image it will allocate a larger buffer by reading the size from the file and won't write beyond allocated memrange. I can patch it in to allocate a larger buffer but the images will look distorted as in previous post. Mvi is the right person to ask when it comes to resources. Though your screenshot sure looks better then in my post :)

 

*Only need to be able to resize bmp files... which is different than tga files...*

Windows Bitmap is not difficult to write. You can also try Pillow.

Edited by N.Kindt
Link to comment
Share on other sites

I love this mod! I've waited a long time for someone to make something like this! :) Nice work :)

 

Question though...Is it a possability that one day there will be a patch with 1680x1050 resolution? I would love that :)

Its possible, but the game is really screwy when you go higher then 1024x768

  • Upvote 2
Link to comment
Share on other sites

Yeah that's cool. I played it today with the hi-res patch, and yeah the units are pretty small at 1024x768. I got patches for Starcraft that enable me to play it at 1680x1050, and while it looks amazingly crisp, you can't see some of the zerg units almost at all! So I play that at 1280x800.

 

It looks good at 1024x768. I'm just glad that I don't have to put up with the so-old-skool res of 640x400/480 anymore. That was such a bad decision on westwood. they should've made Dune2k using an engine as flexible as the RA2 one.

Link to comment
Share on other sites

Yeah that's cool. I played it today with the hi-res patch, and yeah the units are pretty small at 1024x768. I got patches for Starcraft that enable me to play it at 1680x1050, and while it looks amazingly crisp, you can't see some of the zerg units almost at all! So I play that at 1280x800.

 

It looks good at 1024x768. I'm just glad that I don't have to put up with the so-old-skool res of 640x400/480 anymore. That was such a bad decision on westwood. they should've made Dune2k using an engine as flexible as the RA2 one.

The units are exactly the same size as the old resolution! The patch from N.Kindt makes only the battlefield window larger, it does not resize any sprite. So, a larger resolution with this hack is always beneficial, because you can see more of the battlefield. As far as I know you could get Dune 2000 in any resolution you want, as the first version of N.Kindt's hack proved. I think the hacks from mvi on the .r16 files (images) can also be ported to other resolutions, but there are still some problems with higher resolutions. One biggie is that the battlefield got tears (rips) with resolutions that don't have the same relation with width/height as the original (640/480). This limits the amount of available resolutions and a small problem is that if the resolution is larger than the map, it will crash, but perhaps that can be fixed or just a cheap work around, like not allowing smaller maps.

Edited by D2k Sardaukar
Link to comment
Share on other sites

That would look nice at that resolution N.Kindt. I love playing my old games in a higher resolution - gives them a new lease on life...Now if only someone could hack a higher resolution into Warcraft 2 Battle Net edition, I would be very happy (til then I guess I'll keep using stratagus)...

 

Keep up the good work guys, it looks great! :)

Link to comment
Share on other sites

New Python script that can patch to any resolution. Below is an example of 1920x1080. The UI needs to be cleaned up a little, it shows options button twice (second one is no button). The up/down buttons for scrolling don't give a crash strangely enough, but for 1024 they did during programming....

 

Still need to figure out the bmp files for the world map before I release the script. I looked at Pillow to edit the bmp files, but got a little confused at Python 3 support ... so I stopped working on it.

 

Example:

post-2251-0-18294300-1367245619_thumb.pn

 

N.Kindt, what is different in your 0.8.1 version and the very first version?

  • Upvote 3
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...