It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
I just noticed another bug with 1.04 that doesn’t seem to be in the defect list, at the start of a new game if you load up your constructer with 60 materials and try to build a barracks it tell you that you need 26 materials to build it at x4 speed however if you only load up your constructer with 26 materials and then try to build the barracks it will no longer let you build at x4 speed instead it will only let you build at x2 speed in order to build at x4 speed you must load up your constructer with 32 material, so clearly this is incorrect.

Something similar happens when you start researching cost, at the start of a new game to build a mine at x4 speed you need 56 materials and the job will take 5 turns. However after researching cost a couple of times it will tell you that you need 50 materials to build at x4 speed and the job will take 3 turns, but if you only load up the constructer with 50 materials and then try to build the mine the game will no longer let you build it in 3 turns instead it will now take 4 turns at a cost of 42 materials so in order to build the mine in 3 turns you still need to load up the constructer with 56 materials, curiously however if you load up the constructor with 56 materials and build the mine in 3 turns once the job is complete the builder will have 6 materials left onboard, so it does in fact only need 50 materials

Clearly something isn’t right here because this shouldn’t be happening, while its not a big issue it is kind of annoying to load up your builder with the required amount of materials that the game told you that you needed only for the game to suddenly decide that you don’t have enough materials on board to build at the desired speed/number of turns, not sure if other structures are similarly affected.
avatar
klei1984: C++17 is required mainly for its portable std::filesystem library. Soon C++20 will be required for its std::format library which was implemented finally by GCC 13 a month ago.
well i guess that answers the question as to why maxport doesn't work for xp, hummm... i wonder if the issue with getting maxport to work on xp is that the use of the std::filesystem library then would it be possible to add a full back option ?

I know that its not the same thing but in web development you can run a check to see if a given feature is supported by the browser and if not then provide a fall back so that the contents is still accessible so would it be possible to do something like that here run a check to detect the OS and if the OS is XP then run an alternative library that will work for XP.

I don't know if such a thing is possible, but the reason i ask is because Syndicate Wars Port works just fine on XP so I'm wondering what they did differently, I'm just thinking that whet ever it is that they did differently could potentially provide a solution.
The zip file contains two versions. Hopefully one of them will run. I have no physical Windows XP system to test.

https://www.udrop.com/8dBC/max.zip
only just saw the link but it seems to be dead can you upload again and I'll give it a go see if either work
I did not expect this udrop stuff to remove the files (so soon) and the udrop server / site does not even work now here. Unfortunately I do not have the hw version anymore only the software one. I am in the middle of reworking the build system so cannot reproduce the binaries i made earlier by hand as a test.

Link to the software renderer version on google.

If the screen fade effects are too slow, or the screen remains dark, change configuration in settings.ini to similar:

display_index=0
screen_mode=1
disable_ar_correction=0
scale_quality=0
window_width=640
window_height=480
dialog_center_mode=0
Post edited June 23, 2023 by klei1984
That’s fine the first step is just getting a version that will actually load and run so I can actually do some testing.

Ok so initial load test is successful was able to load the game without any errors I was able to start a new custom game and new campaign game with out any issues and I was able to load my saves from 1.04 without issue as well

The first real issue I notice is that the game seems to run very slowly though I’m guessing that this is due to the fact that the game is running in software mode so that’s to be expected.

I also noticed that when max port is printing the text before for the first campaign mission I wasn’t able to hit enter/esc to make the full text appear immediately which I can do in 1.04

When I started a new campaign game things seemed to stutter a fair bit and the mouse curser movement was jumpy also the intro video failed to play but this maybe due to the fact that you haven’t re-implemented video yet.

The sound also seemed to be off as well it seemed like the sound was simply looped this is clearly evident when clicking on the mine as you just get the start-up sound in a constant loop which is clearly not correct its also evident when clicking on units like planes for example although the different is more subtle. I’m guessing this is down to the fact that you haven’t found a way to replicate the way the original game implements sound.

Ok so first issue is that when starting a new campaign game hitting enter/esc to try and make the mission text appear immediately seems to cause things to bug the game loads immediately quits and then loads again clearly this isn’t supposed to happen though this doesn’t happen if you just wait for the text to load and then click ok, I also notice if you hit enter/esc to try and make the mission text appear immediately the curser freezes and can’t be moved anymore however once the text finishes loading it just loads into the game so clearly something is not correctly implemented here.

Additionally if you try moving the mouse curser around while the text is loading the curser movement is very jumpy and again this doesn’t happen in 1.04 though this jumpiness may be down to being in software mode, however the cursor jumpiness seemed to stop when the text finishes loading, so not sure what is going on there but clearly there is some sort of an issue so not sure if this is down to being in software mode or if this is indicating a re-implementation issue.

Ok so the first major problem the game is incredibly slow and unresponsive when I start a new campaign game and I click the car for example I have to click several times before the game will actually select it second when I try to get the menu up to load spies I again have to click several times before the menu will appear and when I get the menu to appear I again have to click several time before it will actually select the option I’m clicking on in this case load.

Once I eventually select load and click on the spies all I get is a flashing blue light bulb and they refused to do anything I timed this on a stop watch for well over 5 minuets and the game utterly refused to do anything until I moved the screen then the unit got in the car as it was supposed to evidently this isn’t the game just being slow and lagging because its in software mode this is a re-implementation issue clearly something is not working correctly because I shouldn’t have to move the screen to get the game to execute orders same thing happened when I tried to move units in this case I clicked one of the subs ordered it to move and again I just got the blue light bulb and the unit refused to move until I moved the screen.

When clicking the allocate screen for the mine the colours seem off they seem brighter than in 1.04 so not sure what’s happening there, I tried taking a screen shot with irfanview when hitting print screen failed but that didn’t work either so can’t post a side by side comparison screen shot to show you what I’m seeing.

So currently the campaign game is not playable, its just to slow and unresponsive.

Curiously when I load up my 1.04 save for a custom game that is starting at turn 1 I didn’t experience any of this lag and having to click several times to select units and get the menu up, so it seems like these issues might be confined to the campaign game from some reason

The custom game is still very slow but I suspect that this is down to being in software mode. The sound is still messed up and the colours on the mine allocation screen still seem wrong however.

In my custom game from 1.04 the AI doesn’t seem to work right either upon ending the first turn the AI did nothing its only when I end my second turn that the computer actually moved I know this because I have the [max spy] cheat on so I can see what is going on, though when I reloaded the save and tried to replicate this it didn’t happen again so something a bit funny going on there

Also on turn 4 the timer for the blue team got to 0 and it didn’t go on to the grey teams turn until I moved the screen and I’ve just had the same thing happen again on turn 2 only this time the timer for the green team is on 0 yet it doesn’t change to the blue teams turn until I move the screen and for a third time now the timer has gotten to 0 this time on the green again and wont go on to the blue teams turn till I move the screen the fact that this has happens 3 times now clearly indicates a re-implementation issue.

Additionally I notice that the radar screen is not being updated in real time and only updates when I move the screen this also happens in 1.04

Overall it seems like a custom is reasonably playable if a bit glitchy
avatar
klei1984: If the screen fade effects are too slow, or the screen remains dark, change configuration in settings.ini to similar:

display_index=0
screen_mode=1
disable_ar_correction=0
scale_quality=0
window_width=640
window_height=480
dialog_center_mode=0
would you mind explaining these settings or pointing me to where i can find said info, window width and height is pretty self explanatory but not sure what the other settings do though.
Post edited June 24, 2023 by Cursed-Ghost
What kind of computer (hardware) do you have?

In software mode, if you experience performance issues, you shall set the settings exactly as it is explained in the previous message. The relevant settings are explained on the blog https://klei1984.github.io/max/

If the game is still super slow with those settings the only thing you can do to gain performance is to set screen_mode=0 for windowed mode.

The inability to skip type writer text, the choppy mouse pointer, and all similar issues you observe are caused by insufficient CPU power. Even if you set the suggested game settings via the ini configuration file you need a decent computer. The game uses color palette animations that are CPU intensive. On MS-DOS this was done by the VGA Video Bios hardware without CPU intervention (CPU was not involved in the work at all).

MVE (cinematic) videos are not supported now. Interplay's MVE player uses self-modifying assembler program code that is not portable. Alternative existing players use copy left licenses that are not usable. The work package is documented in the roadmap which can be found on the same home page where the blog is.

Some sound effects in M.A.X. have so called loop points embedded into RIFF WAVE audio samples. SDL2's audio mixer, SDL2_mixer, does not support loop points. The original game uses HMI's SOS audio engine which supported loop points. The work package is documented in the roadmap.

The repeated reload loop at campaign start is caused by too slow event loop (low CPU performance). You press the keyboard buttons that cannot be processed by the game as the type writer logic steals the CPU due to too slow rendering speed. In this scenario mouse cursor freezes as it is also a software mouse cursor, not a hardware accelerated pointer object. When you instruct the game to skip the text flow you allocate full CPU time to type writer logic and that starves the event loop even more thus mouse movement events are not processed from the operating system.

M.A.X. is a single CPU game that implements an MS-DOS game loop in a non multitasking operating system context. This means that everything, graphics, computer player strategy, unit path finding, is executed on a single CPU core in a single thread of execution. If graphics rendering uses up all CPU time budget in every frame, 60 frames per second if you have a 60 Hz standard monitor, that means path finding will not do anything as finding paths is a time consuming activity that gets low priority from the game engine. The pending path is indicated by the bulb icon above affected units...

The mine allocation screen title background color is a defect in the original. See defect #70 here: https://klei1984.github.io/max/defects/

The game captures pcx screenshots via alt+c shortcut. Of course if keyboard event handing is starved probably that is also unresponsive...

The AI task manager runs on the same CPU time budget as path finding. No free CPU time, no computer AI.

I need to test the observed end turn behavior, never seen anything like that before.
avatar
klei1984: What kind of computer (hardware) do you have?
Currently have an Pentium i5 quad core 3.2 ghz, and 4gb ddr 3 memory and a NVIDIA GeForce GTX 550 Ti graphics card running xp home sp3 32bit

If the game only runs on a single CPU core that would explain the performance issues. I guess the only way around that would be to implement multi core support so that the game can use the full power of my CPU of course that's no small task.

Having said that this is something that is going to need to be addressed in one way or another because this is going to be a problem for anyone trying to run max port, if max port if going to be so CPU intensive and can't access the full power of peoples CPU's because these days most people are going to have multi core CPU's where like mine each core is only like 800mhz which is clearly not enough.

Although i have to wonder how much of the performance issues are down to running in software mode, and can't help but wonder if things might run more smoothly in hardware mode, having said that even in hardware more this may well still be a problem if the port can't access the full power of peoples CPU's.

Maybe there is a way to rework things so that the most intensive parts of the processing like the graphics are done by the graphics card which would help to free up the CPU and make things run more smoothly.

What i find strange is that when running max 1.04 through VDM sound i don't see any of these performance issues humm... how curious.
Post edited June 25, 2023 by Cursed-Ghost
Your computer is more than enough to run the game. I have a 2.6 GHz laptop CPU only and the game runs perfectly in hardware mode. Software mode is much slower.

hw mode video

sw mode video

Windows XP emulates 32-bit protected mode MS-DOS applications via NTVDM's DPMI server. You need VDM Sound as NTVDM's DPMI server has limited capabilities. NTVDM does low level emulation on OS level which is fast.

M.A.X. Port simulates color animations using SDL2 textures and surfaces. This means that there is Windows, on top of that the GPU driver, on top of that SDL2, on top of that M.A.X. Port color animation simulation via software color palettes and what not and on top of that runs the actual M.A.X. graphics engine/ renderer that in case of Windows XP and MS-DOS just called out to the DPMI server directly and done.

Rewriting the game engine is possible keeping the original aesthetics. Proof: https://www.researchgate.net/publication/336310827_Techniques_for_GPU-based_Color_Palette_Mapping

But will take years still...
Post edited June 25, 2023 by klei1984
MVE (cinematic) videos are not supported now. Interplay's MVE player uses self-modifying assembler program code that is not portable. Alternative existing players use copy left licenses that are not usable. The work package is documented in the roadmap which can be found on the same home page where the blog is.

Some sound effects in M.A.X. have so called loop points embedded into RIFF WAVE audio samples. SDL2's audio mixer, SDL2_mixer, does not support loop points. The original game uses HMI's SOS audio engine which supported loop points. The work package is documented in the roadmap.
Ok so I know this might sound like a bit of a dumb question but I was wondering you say that video doesn’t work because of the way the game implements video and you can’t include an alternative player due to license incompatibilities.

You also say that the audio doesn’t work properly because the library you are using doesn’t support the loop points that are necessary.

So why not as a temporary work around until such a time as you can find a more permanent solution just find an audio / video manager that would work set the port up to use it and then have the user install it after the fact that way the audio and video works as expected and you aren’t braking any license terms because you are not actually including it in the port you are merely having the end user install it after the fact.

I mean most programs these days usually require the end user to install some third party software in order for things to work properly, so I can’t imagine that there would be any issues going this route I know it’s not an ideal solution but as a stop gap measure it would at lease get the audio and video working properly.

Another possible option that occurs to me for getting the video working would be to rip the video to another format like ogg or mp4 certainly SDL2 should be capable of playing those because that's what they did for Warzone 2100 when that game was released by Pumpkin and made open source.

Talking of which why not check out Warzone 2100 because presumable they will have had to over come some of the same challenges so it might provide some inspiration to help you address some of these issues.

Warzone 2100

What i am curious about though is why on earth you would need self-modifying assembler program code to play a video file seems like over kill to me although i guess we are talking about an old DOS game from a time before stuff like ogg and mp4 excised.
Your computer is more than enough to run the game. I have a 2.6 GHz laptop CPU only and the game runs perfectly in hardware mode. Software mode is much slower.
I figured as much although i can't say i saw much in the way of difference between the videos, certainly nothing like what i was seeing on my end but then when i checked on task manager it was only using 25% of my CPU's full power since it was just running on a single core, and that was pretty much maxed out 95% of the time which would explain the slow choppy performance guess I'll have to wait till you finished reworking the build system and i can try out the hardware version see if that runs a bit better for me.
Rewriting the game engine is possible keeping the original aesthetics. Proof: https://www.researchgate.net/publication/336310827_Techniques_for_GPU-based_Color_Palette_Mapping

But will take years still…
To be honest all of that stuff is way over my head, I only have a minimal understanding of programming while I’ve done a bit of programming it only really covered the basics it’s enough for me to be able to write scripts and get the often simple functionality that I need working when I’m building a web page but my skill and knowledge is no where near good enough to do anything more complicated.

Having said that once you can program in one language you can program in any language because they all work more or less the same way the only real difference is the grammar and syntax guess its like they say a loop is a loop is a loop it doesn’t matter what language its in, although in my case its enough of a headache just trying to learn JavaScript though I’m getting better.
Post edited June 26, 2023 by Cursed-Ghost
This is the hardware mode version.

I tested it on Windows 10 at least where it works as expected. The executable has no dependencies to any third party dlls, just stock Windows ones. On virtual Windows XP this version does not work as it cannot find a compatible video driver...
Hi

Just gave the hardware mode version a go and it crashes as soon as i try to start it thinking it was maybe an issues with the settings I opened up the settings.ini in notepad and got this

https://i.postimg.cc/SK2dSss4/untitled.png

so it seem that the issue may be that the maxport.exe can't read the file.

The fix however is simple just open up settings.ini in wordpad select all and copy then close wordpad then open settings.ini in notepad select all and paste then save this eliminates what ever it is that stops maxport.exe from reading the file so to avoid issues in future I'd do this for all of the ini files and then if you need to make changes to the ini files I'd do so in notepad.

Ok so now that i've fixed that problem when i load up the hardware version of maxport for some reason I’m getting a blank command prompt window? Question why is the command prompt is being invoked that’s kind of strange, also when I tried to close said window I got the following crash.

https://i.postimg.cc/4NtBWFCX/crash.png

Now at first I though this might have something to do with vdm sound because I get the same sort of command prompt window when running 1.04 but then I did a fresh install of max to its own folder rather then just copying my pre-existing install and it still appeared so obviously this is coming from maxport for some reason ???

Second the speed of the hardware version is crazy fast perhaps a little to fast so much so that there isn’t enough time for sequences of events to occur properly for example when attacking with a tank say, both shots happen so fast that they are almost simultaneous which doesn’t leave enough time for the fire sound to play properly so might be an idea to slow things down a touch perhaps add something to the ini file which would let players adjust the game speed.

Also as previously mentioned the sound is messed up but obviously as you already explained this is due to the lack of support for the loop points that are necessary to make the sound work properly so evidently you haven’t found a solution for that just yet.

Another issue with the sound is the volume, there seems to be some weird dynamic sound thing going on and the volume keeps changing one minute its really loud the next its really quiet which makes it tough to set the volume to an appropriate level.

As previously mentioned the colours on the allocation screen seem to be off here are a couple of screen shots to show what I’m seeing the first is 1.04 the second is maxport as you will see the back ground colour for the overlaid text is wrong.

https://i.postimg.cc/QdvNjt4Q/screenshot1.png
https://i.postimg.cc/GmTrgRLH/screenshot2.png

Now I know that you said that this is due to a defect getting fixed but what I would perhaps suggest is to make the game use the higher quality sample as per the fix but adjust it slightly and make it darker so that it matches the original aesthetic.

Also if you flick back and forth between the 2 screen shots you will notice that the text on the left and at the top seems to be slightly misaligned in 1.04 all the text is centred but on maxport the centring is off

Both minor issues I’ll grant you but the little details like that still matter and neither should be difficult to fix

if you try to move a ground unit on to a tile that is occupied by an aircraft the game misbehaves and gives you the wrong cursor and wont let said ground unit move onto that tile, clearly this is incorrect behaviour.

The same thing happen when trying to move an aircraft on to a tile occupied by a ground unit or structure again the cursor misbehaves and wont let you move there, evidently this defect hasn't been fixed yet.

Trying out the campaign game and when trying to steal the computers units if the infiltrator fails, the infiltration unsuccessful sound doesn’t seem to play, this may be related to the fact that the game is running to quickly and therefore sequences of events don’t have time to happen properly or it could be a coding error.

After a sub engages in an attack if you only fire 1 shot and have movement points left and you then move away out of detection range the sub doesn’t submerge like it should.

Talking of attacking in 1.04 they change the way attacks work so that when you select to attack a target the unit will keep firing until either the unit runs out of shots or the target is destroyed, it would be nice to have the option to have attacks work like they do in 1.03 where you click on a target once and the unit fires once only.

similarly spies incorrectly remain visible for the rest of the turn after attacking or otherwise being detected even when there are no infantry around this is incorrect behaviour if there are no infantry around and the spy moves after attacking or otherwise being detected the spy should become invisible again.

The troop carrier also has a similar issue when transitioning from ground to the water the troop carrier isn’t submerging like it should be this also happens in 1.04

When using full screen mode if you alt tab back to the desktop there is some rather nasty bad behaviour the screen flickers like crazy and the desktop is unresponsive, if you open up task manage and try to end task on max nothing happens, if you try to call up the start menu its immediately closed again if you try to open the menus on task manager they wont open or if they do there instantly closed again.

if using screen mode 2 and you try to alt tab back to the desktop the game doesn’t minimise like it should, which of course makes life difficult when I’m trying to document glitches and I can’t get the game to minimise correctly.

Not sure what’s going on but something isn’t working right, because regardless of the screen mode when I alt tab back to the desktop the game should be minimised as expected and the desktop should be fully functional.

Just tried to reload and got the following error and then the game crashed when I hit debug

https://i.postimg.cc/CL3Lg56j/crash2.png

Since I have gotten this error multiple times now and since the game crashes every time I hit the debug button then it might be helpful to have the game create a crash log when it does crash as this would aid in finding and eradicating bugs

The rational behind is that if you have the game dump everything to a text file upon a crash I could then post the crash log and this would help you more easily figure out what it is that’s misbehaving and causing the crash and therefore make it easier to find and eradicate the source of the problem.

I’ve also observed what appears to be some odd decision making by the computer, on 1.04 normally the computer wont come anywhere near my base due to the fact that I have applied the [maxsuper] cheat to all of my units to discourage rush attacks by enhanced scouts which is kind of cowardly and incredibly frustrating when you keep getting taken out within the first 4 or 5 turns every time you start a new game since there simply is no way to defend against that, but on maxport even though the computers scouts don’t stand a chance against my scouts all of which have the [maxsuper] cheat applied the computers scouts are still trying it on and getting instantly destroyed which indicates something in the computers logic isn’t working right because if the computers units don’t stand a chance against me they shouldn’t come anywhere near me if I’m understanding how the computer calculates no go areas due to damage level being to high.

so I'm not convinced that defect 155 is in fact properly fixed if its causing the AI to make decisions that it shouldn't make so for example In this screen shot

https://i.postimg.cc/gjDT1nvR/screenshot1.png

you see the 2 blast marks where 2 of the green computers scouts tried to attack me the one on the left going after my builder the other going after my surveyor neither attack ever had any chance of succeeding because the one going after my surveyor didn’t have enough movement points and the one going after my builder was never going to get anywhere close due to the fact the its protected therefore neither attack should have been attempted if the AI logic was working right, so not sure why the computer is doing that but something is off.
Post edited July 22, 2023 by Cursed-Ghost
Another glitch I just noticed is that auto allocation doesn’t seem to work right.

In my current game I can make a total 23 fuel per turn however since I didn’t need that much and have no fuel silos I had it set to just 8 enough to power 1 power plant and 1 generator I then built a second power plant and a research centre I then tried to turn the research centre on and got the following errors

Can’t turn research centre on insufficient power.
Can’t turn power station on insufficient fuel.

However since I’m capable of making 23 fuel and 13 power per turn these errors should not happen.

What should happen in this case is that when I try to turn on the research centre the power station should be switched on automatically, the power generator should be switched off and fuel production should be increased from 8 to 12, so clearly something isn't working right, and as a consequence I now have to deal with this manually which is kind of irritating.

What's even more irritating is that if I increase my fuel production to 12 turn the power station and research centre on and turn the generate off on the next turn the computer will revert those changes and it will turn the power station and research centre off and turn the generator back on and it is doing this every turn, and unfortunately removing the generator doesn’t help it still keeps turning the power station off which shuts down my research centres and factories.

so now not only do I have to handle this manually but I have to do so every turn because my own command and control system is actively working against me talk about frustrating.

Another glitch I notice is that the when you click on a research centre and look at total this is displaying incorrectly at the moment I have 2 habitats which make 6 personnel however when I click on my research centres total is only displaying 2 when it should be displaying 6, and yes both habitats are connected to the complex.

The allocation screen seems to be displaying the wrong cost for spies.

By default the cost of a spy is 9 materials if you don’t have any cost reduction, however if you shut down all your production until your usage on the allocation screen is 0 and then start training a spy and then check the allocation screen again you will see that it says usage 1 which is incorrect it should say 9 so there is something funny going on there because if the cost of a spy was truly only 1 then they wouldn’t take 9 turns to train they only take 1 turn like infantry. This also happens on 1.04

So I don't know if the allocation screen is simply showing the wrong cost for spies or if spies are supposed to have a cost of 1 and take 1 turn to train like infantry and it is the training school build screen that is wrong but I suspect it is most likely the allocation screen that is wrong.

Another glitch I just noticed after capturing one of the alien fighter bombers and destroying one of the gray teams missile crawlers, it didn’t leave a patch of debris now I know this can happen when attacking targets such as scouts that are on coastal tiles but since missile crawlers can’t move on to coastal tiles since they are unable to traverse water then destroying a missile crawler should always leave a patch of debris.

Upon further examination I’ve noticed this glitch happening all over the place on inland ties where it shouldn't happen so whatever is causing this issue it seems to be error with maxport because I can’t say I recall seeing this behavior on the Sanctuary map in 1.04

The tile marked in this screen shot however seems to be defective in 1.04 and maxport and for some reason it is in-passable even though there is nothing there and I should be able to move a unit on to it

https://i.postimg.cc/MT64p7Yv/screenshot2.png

When alien units upgrade the wrong message is being display as you can see in this screen shot

https://i.postimg.cc/SR99R7Mc/screenshot1.png

funny i didn't know gold refineries where combat units that could increase in experience lol.

another glitch I've noticed is that when i press Alt Gr + L to do a quick reload it doesn't work, however in 1.04 it doesn't matter which alt key you use both Alt + L and Alt Gr + L work and will quick reload the last save file that was saved / loaded

Another glitch i just noticed for some reason the computer isn’t doing a collision check when trying to build and is therefore able to built in places where it shouldn't be able to notice how the computer dock is built on top of the alien gunboat this shouldn't be possible, I've seen this happen in 1.04 also

https://i.postimg.cc/mgJt1ckY/screenshot1.png

Another glitch i just noticed is that cost reductions are not being applied correctly

As I have mention previously 1.04 had an issue with cost reduction not be applied properly and I’m seeing the same issue in maxport. For example by default the cost to build a mine at x4 speed is 56 materials with a build time of 5 turns. After researching cost reduction once (10% reduction) the cost to build a mine at x4 speed is 50 materials with a build time of 5 turns

However if you actually want to build said mine in 5 turns you have to load up the builder with 56 materials even though the cost is now only 50 materials clearly, this is incorrect behavior, if the cost is 50 materials and the build time is 5 turns then should only have to load up the builder with 50 materials to build in 5 turns.

An additional problem I'm noticing with maxport in relation to this issue is that there seems to be some sort of corruption happening in my current game I’m at turn 90 and I have 20% cost reduction however if for example I try to build a mine at x4 speed the game is telling me the cost is 56 materials and 3 turns to build which is clearly incorrect while the number of turns as been reduced the cost has not.

Yet in that same game if I load an earlier save when I had only 10% reduction and I try to build a mine the cost is 50 materials and the build time is 5 turns, so clearly something is wrong here, because the cost with a 20% reduction applied should only be 45 materials
Post edited July 22, 2023 by Cursed-Ghost
There seems to be a glitch with the mini map in that it doesn’t appear to be updating in real time properly, this is most evident on the first turn.

In order to investigate this issue I started a new custom game with 4 computers and enabled the [max spy] cheat so that I could see the other computer players

On the first turn in particular the mini map is not updated until either you move the screen or turn 2 begins the mini map does appear to update in real time for the player and there units and it does appear to update in real time for computer units that are within the radar range of the player however if the computer units are not within the radar range of the player then there positions are not updated in real time on the mini map unless the player moves the screen or the next turn begins

I don’t know if this is a bug or deliberate design in order to save resources but either way on modern computers regardless of whether the computer is within your radar range or not the mini-map should always be updated in real-time for all teams.

Another issue I’m noticing is that the something is off with the scaling because when I increase the resolution from 640x480 to 800x600 which is what I usually use for older games since I only have a small 16" monitor and anything above that makes things to small on screen the map isn’t being stretched to the edge of the window as you can see in this screen shot.

https://i.postimg.cc/rmRGrjQB/screenshot1.png

The same thing happens when I increase the resolution from 640 x 480 to 1024 x 768 so clearly this is not correct the map should cover the entire window like it does when the resolution is set to the default 640x480

Additionally something is off with

Scale quality: 0 - Nearest neighbor (crisp, looks good on CRT monitors)

Because when displayed on an actual CRT monitor the image quality is in fact absolute garbage it’s really blocky and pixelated I did try to screen shot it but the screen shots failed to show what I’m seeing so instead I created a short 20 second video clip

The link should be good for 30 days if you don't see it before it gets deleted just ask and i can make another clip.

https://ufile.io/46jl84d0

as you will see the image quality when displayed on an actually CRT monitor is in fact pretty poor it might look good on a laptop LCD display but it doesn’t on an actual CRT monitor.

Scale quality 2 - Best (whatever that is in SDL2)

On the other hand is way better and is really sharp and crisp on a CRT monitor and actually looks a little better then the original game the difference is subtle but there is a slight but definite improvement to the image quality like the images are being upscale.
Post edited July 26, 2023 by Cursed-Ghost
Hello, sorry for the long response delay.

avatar
Cursed-Ghost: it was maybe an issues with the settings I opened up the settings.ini in notepad and got this ...
For some unknown reason I packed an ini file with unix line termination. The packages made by GitHub are correct. So starting from the next release, there will be a Windows XP 32-bit package on the Download page.

avatar
Cursed-Ghost: I’m getting a blank command prompt window? Question why is the command prompt is being invoked that’s kind of strange, also when I tried to close said window I got the following crash.
To get standard output and standed error output we need that black window. What is standard output? When we quit the original game it prints a farwell message "Thanks for playing M.A.X.!" or something similar. That message is printed on standard output which we do not have in Windows windowed applications anymore. The SDL library uses that window to print various error and normal messages or logs. Just ignore it. If you close the terminal window you terminate the entire application too abruptly... That message window is much better for the time being then a text file would be as the window is real-time, while the text file is not.

avatar
Cursed-Ghost: Second the speed of the hardware version is crazy fast perhaps a little too fast so much so that there isn’t enough time for sequences of events to occur properly for example when attacking with a tank say, both shots happen so fast that they are almost simultaneous which doesn’t leave enough time for the fire sound to play properly so might be an idea to slow things down a touch perhaps add something to the ini file which would let players adjust the game speed.
Will look into game ticks later. First the main game loop needs to be documented and regression tests need to be added before I can make design changes. This is the hearth of the system...

avatar
Cursed-Ghost: Another issue with the sound is the volume, there seems to be some weird dynamic sound thing going on and the volume keeps changing one minute its really loud the next its really quiet which makes it tough to set the volume to an appropriate level.
Sound effects are subject to stereo panning and distance attenuation. The original game used a different sound system that is not available anymore and its behavior is simulated by SDL audio now. If behavior is different it means that SDL's sound mixer works in an unexpected way. It makes no sense to rebalance sound effects when the currently used SDL audio is any ways planned to be replaced or reworked to get the looped sound effects play correctly.

avatar
Cursed-Ghost: After a sub engages in an attack if you only fire 1 shot and have movement points left and you then move away out of detection range the sub doesn’t submerge like it should.
Original M.A.X. behavior is preserved. 1) If the stealth unit is inside enemy scan range when it fires, then it will remain revealed until it leaves the enemy scan range in the given turn. 2) A revealed stealth unit becomes hidden immediately after a single movement regardless of being in the scan range of the enemy when moved in a turn in which the stealth unit did not fire an attack.

avatar
Cursed-Ghost: It would be nice to have the option to have attacks work like they do in 1.03 where you click on a target once and the unit fires once only.
Will add it. I also think that it is useful.

avatar
Cursed-Ghost: When using full screen mode if you alt tab back to the desktop there is some rather nasty bad behaviour the screen flickers like crazy and the desktop is unresponsive, if you open up task manage and try to end task on max nothing happens, if you try to call up the start menu its immediately closed again if you try to open the menus on task manager they wont open or if they do there instantly closed again.
if using screen mode 2 and you try to alt tab back to the desktop the game doesn’t minimise like it should, which of course makes life difficult when I’m trying to document glitches and I can’t get the game to minimise correctly.
I cannot reproduce this issue. SDL manages window or screen operation modes. The game uses stock default configurations. In mode 1 the game gets exclusive rights to the screen, and desktop resolution is changed to the game resolution configured. You are not supposed to use ALT+TAB or Windows key or similar at all. I could look into it if a reliable way is found to reproduce the issue. For me it never happened. In mode 2 the game configures borderless windowed mode where you shall be able to use ALT+TAB and similar without issue. Pressing ALT+D, the minimize all hotkey on Windows minimizes the game window as it should on my system. I will look into Windows design documents to see what is expected behavior when we use the Windows key or ALT+TAB with borderless full screen and windowed mode applications. Could you try the DOSBox emulator? It uses SDL1 while I use SDL2, but if that works well, then I could look into their configuration for ideas.

avatar
Cursed-Ghost: Just tried to reload and got the following error and then the game crashed when I hit debug
If you have no debugger software attached, you are not able to debug. Based on the screenshot you found a failing assertion test. Assertion tests trap unrecoverable errors before they occur in situations that suggest corrupted application state. In your case the assertion test suggests that your saved game contains a hash map corruption. It is a known issue, we are working on it since months to triage it and resolve all root causes (there are multiple). By pushing the Debug button you provoke a crash as an exception is raised by the application that is supposed to be caught by the debugger software and as there is no such a thing the operating system catches the unhandled exception and the application terminates. If you abort this error and restore the last backup save from SAVE10.BAK, you might prevent the save game corruption. If you ignore this error, you will continue to play with the corrupted game state. This particular hash map corruption issue happened a lot of times in original M.A.X. too, this is the cause for ghost units that pop up on the map some times and cannot be interacted with.

avatar
Cursed-Ghost: The rational behind is that if you have the game dump everything to a text file upon a crash I could then post the crash log and this would help you more easily figure out what it is that’s misbehaving and causing the crash and therefore make it easier to find and eradicate the source of the problem.
The assertion test message is the only relevant information in this particular case. You can enable the task log system by pressing ALT+F3 twice. If you attach the SAVE10.BAK + tell the assertion test message, plus attach the log file it gives us sufficient context to investigate further. Minidumps are not possible to be made on Windows operating systems in a meaningful manner as Windows does not understands DWARF debug symbols and GCC compiler or GDB debugger cannot interpret the Windows PDB and Minidump formats. Developing a GCC and Windows compatible crash dump writer wrapper application is possible, but it makes not much sense without a callstack walker which is also not available on Windows in combination with the GCC compiler. If a viable library or method becomes available I will look into integrating it later. For now, the available debug services should suffice.

avatar
Cursed-Ghost: you see the 2 blast marks where 2 of the green computers scouts tried to attack me the one on the left going after my builder the other going after my surveyor neither attack ever had any chance of succeeding because the one going after my surveyor didn’t have enough movement points and the one going after my builder was never going to get anywhere close due to the fact the its protected therefore neither attack should have been attempted if the AI logic was working right, so not sure why the computer is doing that but something is off.
Hopefully we can set up a test environment to reliably reproduce the faulty decision making logic. Without that finding the root cause is highly unlikely. The Computer AI has many issues still. A single wrong conditional statement could ruin everything and there are thousands of tasks ticking away in every turn evaluating hundreds of conditions per task...