I tested in VMWare. I don't have plain Windows 10, so I just put several virtual machines including Windows 10 in one virtual network. That way I was able to play several turns of NETWORK TCP/IP game between three virtual machines. Directly without using Hamachi.Good work.Your test was using Hamachi or directly IP,Network game or Internet game?
OK,thank you for the response and try.Unfortunately,now multiplayer using different computers works just with Hamachi,Evolve,maybe other gaming networks,I tested in Tunngle,a Civ III room.When I will have a partner using VB with Windows 10 will write here the result,if we can play.I tested in VMWare. I don't have plain Windows 10, so I just put several virtual machines including Windows 10 in one virtual network. That way I was able to play several turns of NETWORK TCP/IP game between three virtual machines. Directly without using Hamachi.
Thanks for adding the CPU throttling feature, good luck with sorting out multiplayer.
Thx! This is awesome! Are you on Steam? If so please add me! My nickname on Steam is also: DaringPaw.
I have set up a group in honor for Civ 2 MGE and your great effort that made it only possible! Please join there as guest of honor.
If you have a paypal or patreon please tell me your details, so I can send some money to you. This is just great!
Thank you!
Can you tell me how you exctly changed or set the AI attitude/hostility? There are 2 approaches at least.
What did you change in regards to the population money and map size limits?
Are there changes to overall unit limits too? Upper limit of total and individual civ's number of units can be an issue in multiplayer games, too.
And could you finally explain what this buffer value prevented or does, so a layman can understand, please?
For me that was actually the most important change and intersts me the most, since multiplayer is the best mode in this game for me. Thank you so much!
This is so freaking awesome! You are just great!
We will make some stresstest in some serious games soon and will let you know how your awesome programm works.
That was easy to copy. Thanks to deeves and his open-source civ2patch project.Thanks for adding the CPU throttling feature, good luck with sorting out multiplayer.
Hey Fox, thanks for your reply!
Will donate something soon. Thx.
I also made you member of honor in our small group. Thx for joining!
Thx for your explanations! I always thought it would be because of Win 8 + 10 network adapter settings, but this was a wrong assumption. Didnt think that the problem would be inherent to Civ 2 code. Great that this is solved!
@AI attitude/hostility: For some or even a lot of players this was an issue, because ai seemed to be somewhat irrational or its behavior seemed to be absurd to some degree. Hence the community developed basically TWO different options/patches to solve this issue:
(1) The one by Deeves, which you just mentioned.
- https://forums.civfanatics.com/threads/mge-civ-2-patch-project.570939/
- https://github.com/vinceho/civ2patch
(2) The other one by Skyer1, which is mentioned here: https://forums.civfanatics.com/threads/ai-attitude-change.154251/
> https://forums.civfanatics.com/threads/how-to-get-maps-from-ai.346089/page-2#post-9738897
> I think this could be found here in the past, though the link doesnt work anymore: http://patchesgames.blogspot.de/2009/06/civilization-2-mge-ai-no-hostility.html
> I think I have this attitude.exe on some mirror somewhere, if you want it.
(3) Several links to both options/patches are also mentioned here: https://forums.civfanatics.com/threads/mge-diplomacy-ai-attitude-patch.573000/
I think I tied and used both of them, and one was actually slightly better than the other. One was too friendly or the ai attitude just didnt change by any means, which is not plausible either. I think the one by Skyer actually was slightly better, because he aimed for an ai attitude similar to Civ 1 and the ai attittude was more flexible than with the Deeves patch.
Could you check and compare both patches again maybe? And implement the Skyer1 ai attitude modification as an option as well. Like either no change to ai attitude (vanilla version), Deeves ai attitude changes or Skyer1 ai attitude changes? If you need it and cannot find it, I can also send you the Skyer1 ai attitude patch via email. Just let me know. Would be great to see this being implemented as well Thanks a lot!
Good news:I played with a friend from Russia using Tunngle 3 hours,no crashes.
Hi FoxAhead, I just allowed myself to send you an email at your hotmail address included in your paypal link. I hope this is ok and it worked. Please let me know. I think thats the last inspiration I have for you concerning this project, since all the patches I know to this date of must be covered by your previous work, our forum
messages and finally by this email. I think, if you go throu these few patches and see if there is anything new and maybe integrate it into your launcher, everything patch that already existed would be covered and contained by your launcher patch - which would be so awesome! Ok thank you once more for your great work! Keep it up! Cheers!
And as for my small donation: You are highly welcome and deserve even more of it!
Finally, we managed to forward files.Ok. I just gave it another try. Please tell me, if you received anything. If not, I will find another solution. Thanks.
I play GOTM197 using your patch and attitude changes are available,like in Civ II Classic 200 turns AI non hostile,to 1750 AD.So,it works.I'm glad that my fix helped you to launch multiplayer on Win10!
If you want to donate then try this link:
https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=FoxAhead@hotmail.com
I never received any donations and didn't plan to become rich with that, but that would be an interesting experience.
Regarding details about different patches.
Can't tell any details about AI hostility because I just copied what deeves did in civ2patch project hoping it will work. All I can tell that this fix just prevents call of some function that receives 3 parameters. This function likely changes attitude and its parameters could be named something like that: CivilizationA, CivilizationB, DeltaAttitude. So it seems that this call was redundant. For example because of wrong DeltaAttitude parameter. And that call caused degradation of relationships every turn.
Also I can say that I did not investigate this code deeply because I do not consider the hostile attitude of computer as a mistake. I played a lot on King difficulty and get used to that. May be on Deity difficulty it really becomes ridiculous.
About limits.
Money has default limit of 30000. It is checked and clamped each turn. But it is stored in 4-byte signed variable so theoretically it could be up to 2147483647 (0x7FFFFFFF). I set it to half of that just in case. But you can change it in Options of launcher.
The same applies to population. The default limit is 32000 tens of thousands i.e. 320 millions. But again it is stored in 4-byte signed variable so theoretically it could be up to 2147483647 tens of thousands or 21 474 836 470 000. I set it to half of that just in case (changeable in Options). But in contrast to money, population is just a calculated value based on city sizes. Population is only displayed in some screens and no more. So this fix is just for esthetics reasons.
Map size by default is limited to 10000 tiles but is stored in 2-byte signed variable, so theoretical limit is 32767 (0x7FFF). Dimensions has default limit of 250 and could also be extended to 32767. But when you create such map which is too wide or too tall (for example 2*15000) it causes the game to crash mainly because of errors in little world map in the top right corner. So I put reasonable values of 511 and again you can experiment with them in Options.
Total units limit is another story. It is associated with memory allocation. Extending this limit will cause rewriting save/load procedures and would mean incompatibility of enhanced saves with the original game. That is what was done in ToTPP - Test Of Time Patch Project. That was really big masterpiece which gave almost new standard of playing ToT! Unfortunately the source code of that project is not open.
Finally about socket buffers in multiplayer. All network part of the game resides in a separate library XDaemon.dll. That library uses Windows Sockets API (wsock32.dll) for organizing multiplayer game. Socket is endpoint for sending/receiving data. Socket has a lot of options and two of them are SO_RCVBUF and SO_SNDBUF. That is as MS online help states "The total per-socket buffer space reserved for receives/sends."
When opening socket with socket function all its options are initialized with defaults. It seems that for many years default values for SO_RCVBUF and SO_SNDBUF were no more than 0x2000 bytes. So programmers of XDaemon.dll didn't bothered about setting those options explicitly with setsockopt function hoping that it would be always the same. Also later in code they used getsockopt function to read SO_RCVBUF option and store it in 2-bytes variable for using later in data-receive loops.
But in Windows 8 and 10 the default value became 0x10000. And it doesn't fit in 2-bytes variable causing it to be zero and no data receved at some point.
What I did is just added explicit call of setsockopt function for setting correct buffer sizes right after opening socket. I choose value of 0x2000 as it seems like game is somehow bound to this value.
That was easy to copy. Thanks to deeves and his open-source civ2patch project.
Regarding multiplayer, it seems like it working. Still no bugs reported.
Also there's the issue with city names. If I restart the game without closing the program, it doesn't start from the first name again, but kinda go on from where it left off last time. This doesn't present in vanilla either.
Spoiler Before :
Spoiler After :
How come MGE introduced these new glitches? (And is it easy to fix? =d)