![]() |
Best (CD Bootable?) Linux Distro for Dominions?
In an attempt to alleviate the crossplatform bugs that keep Windoze / Linux players from seeing the actual battle playbacks when the game is hosted on the other platform, I spent this afternoon downloading and getting Knoppix to run.
With Knoppix, it's enough of a pain that I kept some notes on a step-by-step way to get D2 running, thinking I might post a faq, or pass one on to one of the D2-related sites. Having finally gotten Knoppix to run (limp?), and gotten Dominions installed under Linux, I find it's unplayable. Now - I know (well, I suspect) it's a driver issue : updated drivers from Nvidia may, and even should, alleviate the performance so it gets more than 0.3 frames per second on minimum detail. http://forum.shrapnelgames.com/images/icons/icon12.gif However, since Knoppix boots from the CD (an ISO image burned to one), it's .... "Difficult" to figure out how one could install the updated video drivers (for Nvidia, or whomever). It'd be possible to do a full RedHat or SuSE install to harddisk and install video drivers, Dominions, etc, on top of that, but.... I'm actually trying to figure out the best, lowest pain way for non-UNIX geeks to be able to run Linux D2 from their Windoze boxes. Telling them to install Linux onto a hard disk partition isn't a good solution. http://forum.shrapnelgames.com/images/icons/icon12.gif (I say this because getting a dual-boot system not infrequently involves screwing up drive partitions and having to rebuild everything, with commensurate loss of data if everything wasn't backed up. (And almost no one does proper home backups anymore, not in a day of 60-180 gig drives. Plus, with Windoze, you're -still- likely to lose everything.)) Telling them they can burn a Linux CD, boot from that, and properly enjoy multiplayer, multiplatform, D2 games seems like it would be a Very Good thing. And I know there's many (more than a few) people playing from Linux platforms here. So - any of you have information on which CD-bootable Linux distros would work well for Dominions? Knoppix, Gnoppix, Feather, etc? Tips for getting updated video drivers working with them? Or should I scratch the idea, and figure that any such FAQ should simply say "You're going to have to build a Linux partition on your hard disk. If you don't know what that entails, or aren't a unix sysadmin, don't try."? Regards, Cainehill |
Re: Best (CD Bootable?) Linux Distro for Dominions?
The Devs use RedHat. In the early days of Dom1 I had trouble getting it to run on my Debian linux and the answers I received were RedHat answers which I had to translate. Not the answer you wanted but for the most support in future changes Id say RedHat would have some advantage.
[ March 25, 2004, 02:27: Message edited by: Gandalf Parker ] |
Re: Best (CD Bootable?) Linux Distro for Dominions?
This is a bit OT, but how do you like Knoppix? It should be arriving tomorrow. Im getting it to kill an evil Linux partition Fdisk refuses to handle.
More specificially, QTPartition http://forum.shrapnelgames.com/images/icons/icon7.gif . |
Re: Best (CD Bootable?) Linux Distro for Dominions?
I use Mandrake 9.2 for my Dom2 games at "work" at it work fine (I have noticed that under linux, with the same hardware, I got less efficeny in graphical details ... but it could be that I'm using a workstation not really configured well for graphics but just only for calculations) ... a way could be to install dominions 2 in a Linux box running into Vmware but I must admit I never tried yet ... I have one vmware running a Linux Mandrake 9.2 at home (on windows XP pro) ... i could try to install dom2 and post here a report.
good play Liga |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Debian Users should dist-upgrade to Sarge and all should be well. I use Sarge's own Nvidia drivers, not the newest Nvidia ones. (Yes, Sarge is still technically "testing", but it's very stable now.)
I don't mean to be rude, but isn't finding a solution enabling people to play Dom2 from a bootable Linux CD kind of missing the point about it being multi-platform? Wouldn't it be better to fix the bugs which prevent players on different platforms viewing battles? (Muchos apols if this has already been done to death.) CC |
Re: Best (CD Bootable?) Linux Distro for Dominions?
This bug has been fixed in the next patch. So hopefully you'll soon be able to mix OSes and still get correct battle replays.
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
I like Knoppix in general, but tend to keep my games on my lingering Windows partition. I did test the Doms 1 demo on linux (Mandrake 9.2) and found it to be surprisingly slow - way slower than on windows on the same, admittedly old, machine.
This seemed odd as it has always been the other way around for me - programs that ran on both platforms were generally way faster on Linux than on Windows. But Tuxracer also crawled when I tried it, which makes me wonder in Mandrake haven't messed up the graphics drivers somehow?? Anyway, we'll never get linux geeks to agree on the 'best' distribution. At least we can all agree that vi is the One True Text Editor. |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
I shortly tried to get Knoppix to work, but wasn't very successful. Mostly, all my machines(*) are either dual-boot from the day I start using them, or Linux only. Repartitioning a mostly empty drive for dual boot isn't too hard, and only bothers you the very first time you have to do it.
But I'm not sure how you'd go about getting Knoppix to write your game data to a real partition... does it do it transparently? (*) Two office desktops (one in each of my 2 offices), one office laptop, my home PC, my girlfriend's home PC, and my old personal laptop, though this one's mostly dead; yes, I qualify as a geek. |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
Now, if you could give us a (prospective) date for this marvelous patch... |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
That said - it did do an admirable job of detecting and automatically working with video cards, USB devices (albeit my USB mouse was very slow & jerky), onboard ethernet, router, etc. Quite painless to be back Online after booting. For my own purposes, though, I went ahead and downloaded RH's Fedora iso's overnight and will look at doing a proper Linux install on a newly empty partition. Hopefully it won't trash the other partitions on that drive. http://forum.shrapnelgames.com/images/icons/icon12.gif |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
I then went from bash into csh, set the HOME environmental to where I wanted to place the install, and ran the unix_install script from the directory I'd copied the CD contents to. (This was necessary because my sole CD drive on the machine is my burner - with 2 CD drives, you could boot from Knoppix and still install from CD.) After this, you have Dominions installed on your hard disk, but would need to mount & toggle the readwrite status on that partition each time you booted Knoppix, so Dominions2 can write out the data files. Happily, come the Inquisition, I mean, when the new patch arrives, this won't be necessary anymore. http://forum.shrapnelgames.com/images/icons/icon7.gif |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Personally I prefer to use WinXP to play from. And I prefer Linux (in a completely non-GUI mode) to host from. I think the new switches for things like AI setting, preexec, and if they can get the "create game and quit" mode to work we will have all the command-line switches to make a really good web-based management for multiple games. Game settings selection, maps selection, sign-up, start game, and upload/download turns.
I will wait until thats all working before I start asking the devs for better export of data so the games webpage can reflect game progression. http://forum.shrapnelgames.com/images/icons/icon6.gif |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
The source of the bug has been discussed in another thread. It's called battle inconsistency.... something. Anyway it was a compiler inconsistency.
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
Not everything is Microsoft's fault, after all. |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
Not everything is Microsoft's fault, after all. I agree. I use Windows most of the time and consider it great for some things. I didnt say it did it wrong, I just said it did it differently than the multi-OS compilers did. [ March 25, 2004, 22:12: Message edited by: Gandalf Parker ] |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
[quote] alexti:
[QB]I'm curious. Is it possible to fix Johan's problem with just grouping by parenthesises? How would you rewrite the expression for that? [\qb] Well, if "It was something about the windows compiler not doing math formulas in quite the same order as generic open OS compilers" then odds are that the use of parathensises, and breaking the formula down into discrete lines of code, would take care of it. Hard to say how to rewrite the expression without seeing the source code and expression, but the complex multiline statements often used to express formulas are a common source of problems. The C++ standard left a few too many things (like order of evaluation) undefined, meaning that even on the same platform, different compilers give different results. This is even without accounting for compiler inadequacies, where there is currently only one (Comeau / EDG) available that is approximately 100% compliant with the standard. (Last I knew, Comeau didn't support "export" on templates, but then, no one does.) Another likely culprit, though, would be automatic promotion of floats to doubles - different compilers handle it differently, leading to some wildly disparate results. Again, often best handled through explicit casting, and breaking long statements into short ones, such that intermediate results aren't left to compiler whims. Anyways - use of parenthesises, and breaking complex lines of code (especially calculation heavy code) down into shorter, simpler, statements makes multiplatform life _much_ easier. Cainehill (whose Last job involved a lot of graphics, GUIs, and modeling & simulation with the same source on different hardware platforms and OSs) |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
random1().LT.random2();//Let's mix FORTRAN and C because of the HTML rules on the board! http://forum.shrapnelgames.com/images/icons/icon7.gif Was evaluated in the opposite order under VC++ (right to left) than GCC (left to right). That kind of statement appeared in the MR checking code, so as soon as a MR check happened, the whole rest of the battle was out of whack. |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
</font><blockquote><font size="1" face="sans-serif, arial, verdana">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;"> if (n + d6() < m + d6())</pre><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">and different compilers evaluated left and right subexpressions in a different order. There was some thread a while ago, where programming contest was suggested. Now we have a good problem: - how to make the expression produce consistent results (independent on compiler), according to the specified order of function d6 invocation (from left to right or from right to left)? - can it be done without modifying the expression? |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Hmm... after thinking a bit, I believe the following will do:
</font><blockquote><font size="1" face="sans-serif, arial, verdana">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;">class d6 { public: static bool left_to_right; static int next_id; int id; int value; bool is_random; d6() { id = next_id++; value = 0; is_random = true; } d6(const d6& y) { *this = y; } int realize() const { if (is_random) return value + original_d6(); return value; } bool operator<(const d6& y) const { int x1, y1; if ((id < y.id) == left_to_right) { x1 = realize(); y1 = y.realize(); } else { y1 = y.realize(); x1 = realize(); } return (x1 < y1); } }; int d6::next_id = 0; bool d6::left_to_right = true; d6 operator+(int x, const d6& y) { d6 result(y); result.value += x; return result; } d6 operator+(const d6& y, int x) { return x + y; }</pre><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">Not that I'm recommending it though http://forum.shrapnelgames.com/images/icons/icon12.gif |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
</font><blockquote><font size="1" face="sans-serif, arial, verdana">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;"> if (n + d6() < m + d6())</pre><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">and different compilers evaluated left and right subexpressions in a different order. </font><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">Ah - Graeme is right, parenthesis's wouldn't do it, but it wouldn't be 100% necessary to use discrete lines of code either: </font><blockquote><font size="1" face="sans-serif, arial, verdana">code:</font><hr /><pre style="font-size:x-small; font-family: monospace;"> if ((int left = n + d6()) && (int right = m + d6()) && (left < right))</pre><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">Still not pretty, but each '&&' introduces a sequence point, and the short-circuit boolean rules means that the ones to the right are only executed if the previous one was true. Presuming that d6() returns a value between 1 and 6 (and that n and m are unsigned or otherwise always non-negative values), the first two are true, and the final, real, test is whether left is less than right. Somewhat ugly, but not as counter-intuitive as using non-stochastic dice rolls. http://forum.shrapnelgames.com/images/icons/icon12.gif [ March 27, 2004, 13:54: Message edited by: Cainehill ] |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
Still, that shouldn't matter for the purposes of the solution: Declaring them at the top would still allow the code in question to work. [ March 27, 2004, 18:10: Message edited by: Norfleet ] |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
</font><hr /></blockquote><font size="2" face="sans-serif, arial, verdana">Eh. The benefit of declaring them inside the if statement (or for statement) is that they go out of scope as soon as the if or for is exitted. Keeps you from polluting the namespace with what is, after all, throwaway variables that are only used for a helpful side effect. And you get better locality of reference by declaring variables when used, rather than at the top of a function, unless the variables are relevant through most of the function. Oh, another reason for not declaring them inside the if or for is that Microsoft's compilers don't give the proper lifetime/scope with the default compiler switches; with the switches set to force proper behavior, you can no longer compile Microsoft's header files. (This may be fixed with the latest .Net compilers.) |
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
Re: Best (CD Bootable?) Linux Distro for Dominions?
Quote:
|
All times are GMT -4. The time now is 12:33 PM. |
Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.