Announcement

Collapse
No announcement yet.

Civ3 from a programmer's perspective

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #46
    Originally posted by XPav
    Could it be that those people that aren't getting into Civ3 are just burned out in general on turn-based civ-like games? If you've been playing Civ2 (and its cousins) for a long time and were starting to get bored and expect Civ3 to make you get into the game again, well, of course you're going to be disappointed when it doesn't suck you back in.
    Your theory does have merit, but that's not the case with Civ 3.

    Yes, I _am_ tired of playing Civ 2 after all this years, and that is why I expected Civ 3 to be a NEW game, not just a re-hash of Civ 2 with a few minor tweaks. I mean, really, if I just wanted Civ 2 and SMAC all over again, I'd re-install Civ 2 and SMAC.

    No, I'm not tired of Turn Based strategy per se. In fact, I'll still play a round of Steel Panthers every now and then, just for the heck of it. I went as far as to make my own whole new sets of units and scenarios for it.

    But if you look at the other Civ games, each brought something very new. Civ 1 itself was a whole new approach to turn based strategy. Then Master of Magic was NOT just Civ 1 with phantasy units, but a whole new game by itself. Master of Orion wasn't just Civ with SF units, it was a new game. Colonization wasn't Civ just with a single continent. And so on.

    But let's even forget about Civ games. Microprose had also produced some gems of RPG gaming like Darklands or Bloodnet or The Legacy. Which again, were very new games and innovative games, not yet another lame AD&D clone and each of them different from each other. And each of them are to blame for many weeks of my life being spent in front of the monitor. They also made such stuff as F-19 as an excellent flight sim (for that time) and Railroad Tycoon as an excellent business sim. They made such inovative games as Pirates or the X-Com series. (And yes, I've played all of those. I really was a Microprose fanboy, and proud of it.)

    All of them were also very modern for that time, and given the CPU and RAM and graphics card limitations of that era.

    Briefly, when I bought a Microprose game, I KNEW it would be something NEW, and that it would be top of the line. I knew that someone had actually put a lot of design work into those games, and into every single detail, from interface to gameplay to everything. Seeing the Microprose name on the game box was more guarantee than 1000 review quotes.

    Now enter Civ 3, which is not only some lame milking a franchise, it's YEARS outdated. It keeps an interface from 5 years ago, when we've already seen better interfaces in the meantime. (See CTP2.) It actually regressed in a lot of areas, like the tech tree or the combat system. In fact, that combat system went from simple to freakin' PRIMITIVE and SIMPLISTIC. It's a sick joke, compared to some combat systems that existed for years. (E.g., see Microprose's own awesome system in Master of Magic. Or again, see CTP2.)

    Was there any actual design work on this game? Was there any testing of that design?

    Guess it's time to face the truth: Firaxis is NOT Microprose, and Civ 3 is a shame to Microprose's memory. And I don't know who designed all those great games for Microprose, but it sure as heck wasn't Sid Meier. Or not alone, anyway.

    Comment


    • #47
      Another programmer checking in. Roughly twenty years experience. Manifold languages, platforms, and applications.

      The incessant whining from the nine-year-olds has been interesting in one respect. It confirms that the science fiction version of artificial intelligence is rampant among the lay population. I've even seen Big Blue used as an example of properly implemented AI.

      Chess programs are morons. The cannot strategize above the most primative level. They cannot "see over the horizon". What they can do is calculate billions (or trillions) of positions per second and assess them in terms of tactical strength. Like blind monkeys, they look at every possible position, no matter how irrelevant the move would be. They aren't looking for good moves. They're just crunching out numbers at a phenominal rate, winning by nothing more elegant than brute force of computation.

      You call that intelligence?

      Yes, Firaxis could do the same thing. They could write a relatively simple algorithm to examine every possible contingency per turn. Of course, you'd need to purchase a RISC array for a couple hundred thousand dollars. And you would be unable to afford to make a single error. Playing perfectly, the computer would beat you every time.

      Soren has said before that the AI in Civ3 does not attempt to play the perfect game. And that's why. Chess has more possible moves than there are electrons in the universe. And Civ3 has orders of magnitude more than chess.

      Soren has attempted, it appears to me, to find the perfect balance between computation and strategic guidance of the AI. I believe that he has succeeded beyond anything I could have hoped for. He is a master programmer, and deserving of praise and recognition from his peers.

      Soren,
      "Entia non sunt multiplicanda praeter necessitatum." — William of Ockham

      Comment


      • #48
        Fanboy? I think not.

        When I first posted this thread, I did not expect much feedback; I am somewhat surprised at the indignation and name-calling that it generated. But then again, one of the things that makes America great is that everyone is entitled to state their own opinion. As for me...I still maintain that Civ3 is a programming gem.

        The claim that "The programmers have given zero attention to the efficiency of the algorithms used in the game" is an interesting one, and I am impressed that the writer is able to determine how efficient the internal algorithms are (or aren't) without having seen the source code. While I haven't seen the Civ3 source code either, I have spent several years designing and implementing PC-based chess software, and have also ported significant portions of the FreeCiv application (www.freeciv.org) to BeOS; I believe that this allows me to at least guess intelligently about some of what goes on "under the covers".

        Talking about "map nodes" and "shortest path algorithms" sounds very impressive, but ignores the simple fact that as the game progresses, the number of cities/units increases, the number of options available to the AI increases, and this takes longer (and is more complicated) to compute. Unless the AI logic is a radical departure from standard models, it probably evaluates possible moves/actions for each unit and selects the optimal choice, based on a system of weights or scoring factors. You increase the number of units (and the number of possible tasks) and the evaluation/selection process takes longer. Basic math: managing several dozen AI cities/units is going to take longer than a handful of cities/units...this has little to do with "algorithm efficiency". And this doesn't even begin to address high-level goals, such as relationships with other civs, strategies for military conquest, or generating culture/revenue.

        As human players we have the innate ability to decide "The Indians are encroaching from the west...I'd better move some Archers to Kyoto and rush-pop the walls; the temple can wait 'till later because the rush-pop will lower the population." Designing a game system (and writing the code) to reach the same conclusion is complex. To give you a rough benchmark, the FreeCiv logic that determines where a Settler should build a city is not quite 300 lines of C code; this one function is longer than most undergraduate programming homework assignments. So instead of accusing the developers of a "very moronic design flaw", sit down and map out for yourself what data points the AI must consider, how they affect one another, and what kind of scoring criteria to use to determine the 'best move'.

        Remember that you have to meet marketing's criteria of running on a 300Mhz/32MB machine--so keep the data structures small and the code efficient. Otherwise there won't be a large enough community of potential buyers and you might not get paid for the last couple of years of work. Oh, and by the way...be sure to keep it "fun" for these potential buyers, as well.

        Fun...there's an interesting concept. It ranks right up there with "user-friendly" as something everyone understands, but nobody can explain. As a designer, I (still) shudder when I hear someone say "It has to be user-friendly!" and my usual reaction is "Pick ONE user...and I'll guarantee that he/she will find it friendly." One man's hotkey is another man's menu, and you are never going to find a style that pleases everyone. If nothing else, the Civ3 UI is consistent: there are sufficient visual cues to flyout menus or hyperlinks, and a huge amount of information is presented in a surprisingly small number of screens. (Ever counted how many different dialog boxes there are in Micro$oft Word?) The goal of the UI is to let the user interact with the underlying system, preferably with as little effort on the user's part as possible. The Civ3 UI does this adequately enough, and the fact that Firaxis allows user-customization of huge chunks of the UI graphics is an added bonus.

        So...if you're disappointed with Civ3...take it back...create a modpack...play something else. But to hurl epithets and insults at a group of developers because because Civ3 doesn't include your favorite feature from CIVx/SMAC/CTP/MOO/Quake, or doesn't happen to match your personal sense of style or interests, grow up.

        Cheers!
        Humble Programmer
        ,,,^..^,,,
        Cheers!
        Humble Programmer
        ,,,^..^,,,

        Comment


        • #49
          Those who can do.

          Those who can't whine.
          "Entia non sunt multiplicanda praeter necessitatum." — William of Ockham

          Comment


          • #50
            Re: Fanboy? I think not.

            Originally posted by HumbleProgramme
            As for me...I still maintain that Civ3 is a programming gem.
            Programming gem, maybe. Design gem, absolutely not. Proper tested, not really.

            I try not to think like a nerd, since I do that too much at work already. I think, yes, like a layman who just happened to buy the game. I don't care if the algorithms are properly optimized or not. I don't care exactly which pseudo-random number generator is inside.

            And I definitely don't care if I could write better code myself: I'm not the one selling the program, I'm the sucker who bought it. Just like when I buy a car, all I care about is whether it runs well or not. It doesn't matter if I could design a better car or not myself, nor whether I even have any idea of car mechanics.

            If I was, however to go into my list of complaints, and start trying to think like a nerd, I wouldn't need to even go into complex algorithms. They're usually a lot simpler than that.

            Originally posted by Libertarian
            The incessant whining from the nine-year-olds has been interesting in one respect. It confirms that the science fiction version of artificial intelligence is rampant among the lay population. I've even seen Big Blue used as an example of properly implemented AI.
            And the incessant fanboy tactic of concentrating only on the bad examples, and ignoring the valid complainst is getting old already.

            Most complaints with the AI don't require a super-computer, just such arcane programming techniques as the if-then-else or the for loop. I'm sure in your 20 years of experience you may have heard about those.

            E.g., "if there isn't a single freakin' free square on the map, then I can stop producing hordes of settlers." E.g., instead of having hard coded lists of offensive and defensive units, how about just doing a for through the unit list and pick the highest offense or defense it can produce? E.g., how about "if his army has 10 times the combined offense power of mine, then pick on someone else"? E.g., how about "if that square belongs to someone else AND I didn't declare war AND I don't have right of passage, then it's off limits for the pathfinder"? E.g., how about "for all the units in this city, if I have the money and resources, AND an upgrade is available AND I roll, say, 1 on a 10 sided die, upgrade that unit"?

            And so on and so forth. I'm sure none of those advanced AI techniques need a 100,000+ dollar RISC array. Just some common sense and actual testing.

            Comment


            • #51
              and I am impressed that the writer is able to determine how efficient the internal algorithms are (or aren't) without having seen the source code.
              Equally, I think many people are also surprised at how you regard Civ3 as being a "programming gem" without having access to the specifications, designs or source code...

              Basic math: managing several dozen AI cities/units is going to take longer than a handful of cities/units...this has little to do with "algorithm efficiency".
              Which if you know anything about algorithmic complexity, you'd know that is nonsense. E.g. I can write an algorithm which will search through an ordered array in linear (n) time. Also, I can write an algorithm that will search through the same array in (base 2) logarithmic time (log n) time. The second is superior (quicker) as the value of n increases yet both algorithms do the same thing. The same principle applies to larger algorithms with more complex goals (i.e. optimisation).

              An inefficient algorithm is once which scales poorly in terms of time as the size of the problem (n) increases. Sometimes this is unavoidable, sometimes it isn't. For games, most of the time, performance is quite a strong factor though.

              Again, without access to specifications or source code, I don't see how you can substiate your claim here and, unfortunately, the empirical evidence from the game seems to be against you here.

              As human players we have the innate ability to decide
              Well I don't know about you, but I actually have a thought process instead...

              this one function is longer than most undergraduate programming homework assignments.
              Sounds like a sign of poor SE to me rather than something to be proud of...

              The goal of the UI is to let the user interact with the underlying system, preferably with as little effort on the user's part as possible.
              The goal of UI is not just to provide "interaction". E.g. I can write a dialogue box that keeps popping up everytime you press OK. The user is constantly interacting with it and in the simplest way possible, so is it a good UI? Of course not, because it doesn't let the user do what they want to do.

              One of the aims of UI design is to allow the user to get done what they want with the software in an intuitive fashion, simply and efficiently. Interaction is part of that but is not the be-all-and-end-all of it.

              The underlying point here is correct though, that UI design is actually very complex and is not something which you (easily) either do right or wrong.

              Comment


              • #52
                Originally posted by rid102
                I agree. However, I said it was the "goal of design", not that it was always attained in reality. Someone else seemed to assume the converse, hence my statement.

                Originally posted by HP
                Design flaws are not only forgivable, but in many cases are an inherent part of the process. The design of Civ3 is very complex...

                Originally posted by eRAZOR
                Design flaws are an indication of a poor design hence the name.(especially after a four your development phase)

                Originally posted by eRAZOR
                The design might be indeed complex although I'm not sure what you were trying to express with the rest of this paragraph

                Originally posted by Th0mas
                You plainly did not grasp what HP was saying here. With respect to your whole post, this is probably the most important part of HP's original post.

                Basically CIV 3 is VERY COMPLEX, developers are infallable, testers are not perfect and to balance a game such as this is very difficult..bugs and design flaws. Design Flaws do not equate to poor design, Same as poor implementation does not necessary equate to poor strategy.


                rid102
                I though I might flip back a couple of hundred pages and re-confirm the origin of our discussion surrounding the issue of design flaws.

                eRazor was inferring that the errors in the implementation of the CIV III design demonstrate poor overall design. My point is that the number of 'bugs' is not necessarly a good indicator of poor design but rather poor implementation or testing. (even poor may be a little harsh...bugs are inevitable product of software development)

                So I am not sure whether you agree with me or eRazors views...it all has got a little confusing ...
                tis better to be thought stupid, than to open your mouth and remove all doubt.

                6 years lurking, 5 minutes posting

                Comment


                • #53
                  My point is that the number of 'bugs' is not necessarly a good indicator of poor design but rather poor implementation or testing.
                  Agreed. And my point is that it's very difficult to say whether a design/implementation is "good" or "bad" without knowing what the specification was in the first place.

                  Comment


                  • #54
                    Originally posted by rid102


                    Agreed. And my point is that it's very difficult to say whether a design/implementation is "good" or "bad" without knowing what the specification was in the first place.

                    Comment


                    • #55
                      Originally posted by rid102


                      Agreed. And my point is that it's very difficult to say whether a design/implementation is "good" or "bad" without knowing what the specification was in the first place.
                      aahhh technical specifications... but now we get into the relms of discussing 'line-of-sight" between customer and developer.

                      CIV III is not a simple 'please deliver based on my requirements' development project.

                      As we know technical specifications are defined from the user/customer requirements...

                      Who are the customers..Infogrames? I would imagine that most Apolytons would be shocked at that suggestion. However in terms of Project life-cycle and owning the User requirements they are the closest (they are doing the UAT).

                      Else you start getting very subjective...


                      OTOH implementation can be measured in terms of bug lists.
                      tis better to be thought stupid, than to open your mouth and remove all doubt.

                      6 years lurking, 5 minutes posting

                      Comment


                      • #56
                        Another point is the useability. Why on earth could they leave out stacked unit movement? Even if you hate CTP you got to admit that it was far superior in that department.
                        Several of you have mentioned the lack of stacked movement.

                        You know, if you read the readme file, it talks about stacked movement and how to do it. The fact that iut isn't then implemented in the game screams to me that the game was released earlier than intended.

                        I am adament that most of the problems we are seeing here - including the air superiority bug, lack of playtesting, complaints about Firaxis not noticing midgame tedium etc - can all be attributed to a simple lack of time.

                        I'll wager that they planned on releasing this much closer to Christmas, if not afterwards ... InfoGreed definately rushed this out of the door while it was under development.
                        Orange and Tangerine Juice. More mellow than an orange, more orangy than a tangerine. It's alot like me, but without all the pulp.

                        ~~ Shamelessly stolen from someone with talent.

                        Comment


                        • #57
                          Originally posted by Kolyana


                          Several of you have mentioned the lack of stacked movement.

                          You know, if you read the readme file, it talks about stacked movement and how to do it. The fact that iut isn't then implemented in the game screams to me that the game was released earlier than intended.
                          The only thing I saw in the Readme about "stack" was this :

                          * Multiple Unit Activation: If you right-click on a stack of fortified/garrisoned/holding units, you may activate multiple units by SHIFT+Left-Clicking on each one. Close the window by just Left-Clicking on a listed unit.

                          It's about activation, not movement.
                          Now I did not spent too much time in it, if I missed the part you were referring to, well then my bad, and just quote it and tell me where it is.
                          Science without conscience is the doom of the soul.

                          Comment


                          • #58
                            NO, MY bad.

                            <= Blond Bimbo

                            I read that and made an assumption that was incorrect.

                            Me = stoopid.
                            Orange and Tangerine Juice. More mellow than an orange, more orangy than a tangerine. It's alot like me, but without all the pulp.

                            ~~ Shamelessly stolen from someone with talent.

                            Comment


                            • #59
                              Originally posted by HumbleProgramme

                              The claim that "The programmers have given zero attention to the efficiency of the algorithms used in the game" is an interesting one, and I am impressed that the writer is able to determine how efficient the internal algorithms are (or aren't) without having seen the source code. "
                              There really shouldn't be much for you to be impressed with.

                              TURN1: Player makes modification to trade network. Game takes a few minutes to compute.
                              TURN2: Player makes modification to trade network. Game takes a few minutes to compute.
                              TURN... : ""
                              TURN N: Player makes modification to trade network. Game takes a few minutes to compute.

                              See a pattern there? It's not too difficult to determine from these observations that the algorithms that handle the trade network aren't very efficient.

                              Now, you may still be impressed with how I can guess what these algortihms are doing. Again, it's nothing to be impressed by.
                              Put this way: there are only so many things to calculate for the trade network. The principal one being: "Which cities are connected and which cities have access to which ressources".
                              The other one being the shortest path between two (all) tiles.
                              If you can think of anthing other calculations that modifications of the trade network can lead to, please let us know.

                              Now, for these two calculations, there are widely known algorithms that are mathematically proven to be very efficient, and like I said previously the running time of these algorithms is only dependent to the number of nodes, ie: squares.

                              Whether or not Firaxis used these algorithms, I don't know (if I could magically read the code, then that would be something for you to be impressed with), but I think it's safe for me to guess that they probably did not implement the efficient ones, or at least did not implement them in the right way. If they had, then modifications to the trade network would not bring the game to a such a slowdown.

                              Eitherway, this does not make for a programming gem.

                              Talking about "map nodes" and "shortest path algorithms" sounds very impressive, but ignores the simple fact that as the game progresses, the number of cities/units increases, the number of options available to the AI increases, and this takes longer (and is more complicated) to compute.
                              Again, the number of cities/units/options do not affect the running time of the algorithms I mentionned.

                              As for any other calculations the game makes, the algorithms used in these cases are also obviously non-efficient, since there running time seems to be increasing exponentially. (does that word impress you too?).

                              And that's just bad. Plain bad. If they couldn't find any other way to make their algorithms run in non-exponential time, then they shouldn't have implemented them and should have slightly modified the design of their game. However, odds are with a little bit more thought and slightly different design, they could have come up with some algorithms that would be much more efficient.

                              Unless the AI logic is a radical departure from standard models, it probably evaluates possible moves/actions for each unit and selects the optimal choice, based on a system of weights or scoring factors. You increase the number of units (and the number of possible tasks) and the evaluation/selection process takes longer.
                              Yes. There are more units to factor in the calculations.
                              That's what efficient algorithms are for. That's why there's an entire branch of computer science devoted to it. With a little bit of thought put in the creation of your algorithms, you can 99% of the time find an efficient way to accomplish what you need to do.
                              Note that I say 99%. There is a 1% (not necessarily 1%, but a small proportion) of algorithms for which an efficient way to make them run has not yet been found. However I strongly doubt that Firaxis needs to use any of these. And If their design forced them to, then they need to redesign.

                              Basic math: managing several dozen AI cities/units is going to take longer than a handful of cities/units...this has little to do with "algorithm efficiency".
                              Do you even understand computer science?
                              Everything is an algorithm. Any operation requires an algorithm.
                              Algortihm efficiency has everything to do with everything. The math here is anything but basic. Did you know there are algorithms that can find one record within 10 000 000 records roughly in the same time it takes to find one record within 10?
                              (that's what databases are all about...)


                              So...if you're disappointed with Civ3...take it back...create a modpack...play something else. But to hurl epithets and insults at a group of developers because because Civ3 doesn't include your favorite feature from CIVx/SMAC/CTP/MOO/Quake, or doesn't happen to match your personal sense of style or interests, grow up.
                              Proving that a "humble" programmer is talking out of his arse by stating that a flawed piece of software is a "programmig gem" is not a form of insult if you ask me (yeah, yeah, no one asked me, i'm well aware of that). If you or anyone is going to make a false statement, I will refute it. Always.

                              Comment


                              • #60
                                Chill out people! How many here are actually Game, or Game Industry programmers? Certinaily none of the critics here! Questioning the compititance of a developer is easy to do when you aren't one yourself. No one here has any idea of the internal complexities that the Civ-III AI maintians. I, for one, think that the AI is one of the best computer AIs I have seen (right up there with Age of Empires.) Performance was a low priority for Firaxis - Civ-III is not a real-time game. If you had a choice between optimizing a the AI or making it better, which would you choose?

                                And whats with this mythical 'the design spec' mumbo jumbo? The spec isn't some hard-coded thousand page document written and then followed like a religion. They are living breathing entities which evolve over the pace of a project. The spec and the application begin to merge, when this fails to happen you get a bug. Sometimes, (ok, many times), bugs are punted, or basically not fixed and become part of the spec (for the time being). Sometimes, features are killed, leaving the 'spec'. Did anyone consider, for instance, that the low number of hit points was intended so that a strong attacker (or defender) at least has to OCCASSIONALLY loose units? You know, you do take some casualties in war...

                                Comment

                                Working...
                                X