 |
|  |
 |
|
Badtz Maru
|
|
quote: Originally posted by eweast
Hey - It has nothing to do with the speed of your processor. It's poor programing. There's not enough lines of code on a huge map to slow down a PII 400. Sorry, any half @ss 3D game producess more lines of code than Civ3 does. Very very very poor programing. End of discussion.
How do i know? Let's see:
Huge map, 16 civs, late in the game
not witnesing any computer moves - takes several minutes
What do I have?
P4 1.7GHz - 256MB Ram - and, not like it matters, but Geforce 3 |
Obviously you know very little about programming.
Most 3D games have very little work for the CPU to do - all the serious number-crunching is being handled by the 3D card, not your processor, which is simply handling basic AI for a few enemies at a time and telling the 3D card 'Draw this here'. Proof? Take Max Payne, a fairly state-of-the-art action game. There is hardly any difference between playing it on a 600 Mhz processor and a 2Ghz processor, as long as you have a really good 3D card. Why? The CPU doesn't do very much. It only keeps track of what's going on close to your character, which means it's controlling at most a half-dozen or so enemies. Has Enemy1 been shot? If yes, decrement it's hit-points and play the animation of it being hit. Is Enemy2 aware of player? Run the script where it approaches player and shoots at him. Even a 3D game with very advanced AI that keeps track of what the characters are doing throughout the level and reacts in a much more complicated way than most games (SWAT 3) only devotes 10ms per second to AI at the default setting, and will run without slowdown on a relatively low-end machine, though there will be a framerate hit if it doesn't have a good 3D card.
Civ3 however has several degrees of magnitude more AI decisions and calculations to make. The AI is making decisions for hundreds of workers throughout the game, and some of the stuff it has to figure out for them is a lot more complex than what a layman would think, like when it has to figure out the best way to connect irrigation to a city that it has determined needs it urgently to grow. It is micromanaging it's production to react to dozens of variables, including what all the other civs are doing at the time. There is a LOT of number-crunching going on in Civ3.
|
|
|  |
 |
|
eweast
|
|
quote: Originally posted by Badtz Maru
Obviously you know very little about programming.
Most 3D games have very little work for the CPU to do - all the serious number-crunching is being handled by the 3D card, not your processor, which is simply handling basic AI for a few enemies at a time and telling the 3D card 'Draw this here'. Proof? Take Max Payne, a fairly state-of-the-art action game. There is hardly any difference between playing it on a 600 Mhz processor and a 2Ghz processor, as long as you have a really good 3D card. Why? The CPU doesn't do very much. It only keeps track of what's going on close to your character, which means it's controlling at most a half-dozen or so enemies. Has Enemy1 been shot? If yes, decrement it's hit-points and play the animation of it being hit. Is Enemy2 aware of player? Run the script where it approaches player and shoots at him. Even a 3D game with very advanced AI that keeps track of what the characters are doing throughout the level and reacts in a much more complicated way than most games (SWAT 3) only devotes 10ms per second to AI at the default setting, and will run without slowdown on a relatively low-end machine, though there will be a framerate hit if it doesn't have a good 3D card.
Civ3 however has several degrees of magnitude more AI decisions and calculations to make. The AI is making decisions for hundreds of workers throughout the game, and some of the stuff it has to figure out for them is a lot more complex than what a layman would think, like when it has to figure out the best way to connect irrigation to a city that it has determined needs it urgently to grow. It is micromanaging it's production to react to dozens of variables, including what all the other civs are doing at the time. There is a LOT of number-crunching going on in Civ3. |
Please don't lecture me on programming or especially graphics cards. I know darn well that my GeForce 3 does the number crunching in the graphics department. That's why they call it a GPU (Graphics Processing Unit). I'm not talking about the latest 3D games on the newest hardware. I'm talking about an Athlon 1GHz with a TNT2 chip set running Black & White. Great graphics, lots of code, care to guess who's doing the work on that system? You guessed it - the CPU. It's drawing the polygons, it's positioning them, and doing all the physics, AI, sound, and everything else at the same time. The graphics card just adds texture and various 3D effects. By the way, did I mention lighting? Oh, that's done by the CPU too.
Some other examples? Look at flight sims a few years ago. All that physics plus graphics and no GPU to relieve the processor. Especially in T&L (Transforming and lighting). And I seriously doubt Civ3 can rival those programs in complexity.
Another way to look at it, Civ3 didn’t exactly require a physics engine or anything to create. 
Also, in Civ3, if asked to calculate the winner of a battle: I'd need a pen and some paper. In Black & White, if I were asked to calculate the trajectory of that villager I just threw across the map; I'd need a calculator. 
I don't mean nor want to be combative but I just don't see how this game, even if doubled in complexity, should cause a concern for our modern day CPUs. If you agree great, if you don't that's cool too. Either way, none of us have the numbers in front of us to prove it, we can only speculate. 
|
|
|  |
 |
|
The Rook
|
 |
Florida
Oct 2001 time: 00:16
|
|
Oh God, this thread has brough out both the Programming Gods AND the Lawyer Wannabees.
The Programming Gods know all their is about programming video games. Not only that, they even know everything about whatever game it is that is being discussed, even though they don't work for the developer and got their AS degree at the local community college.
To them I say: You don't know whats going on behind the scenes. It's fine to say CIV3 is not optimized, but don't bring up another game and compare them. I guarantee you, if you replace one of the programmers on CIV3 with you, the code will not be any faster. If you want to blame someone for CIV3's speed problem, blame the money people who pushed it out the door before the code can be fully optimized. You know that's what happened.
The Lawyer Wannabees are the guys who are ready to bring everybody and his uncle into court for the slightest injustice.
To them I say: Give it up. You impress nobody with your two-bit law degree. Even if Firaxis did break some minor law somewhere, it's going to take more than you and you alone to make something of it. You'd be better off going to chase an ambulance.
The point is, lighten up. Hopefully we will see some fixes in the next patch. CIV3 is not perfect, but it's still a great addition to the CIV series, and I think after the patches are done, will be right on top as mostly everyone's favorite.
|
|
|  |
 |
|  |
 |
|
RedWhiteArcher
|
|
People, just play on standart map. The speed is ok there.
|
|
|  |
 |
|
cort
|
|
i dont think it is wise to compare runtime of civ AI routines to graphics related code and conclude that civ3 is programmed poorly.
whether it is lighting or rendering or shading, graphics related code is purely floating point arithmetic. it is true that FP arithmetic is by far the most expensive piece of code to run on any computer but
1. it is very well defined
2. there is nothing unexpected about it
3. it is so commonly required that
there are a lot of hardware based optimizations in all contemporary processors; pipelines, floating point arithmetic units, add-on 3D cards and so on that games on that genre run on any computer without any problem (provided that you have the necessary hardware, if not you cannot play at all)
civ3 AI turns on the other hand; they are unique, surely they require a number of arithmetic operations at the end but the burden of the task is to process some kind of higher level data structure they have developed to represent the world, the civs, the units.. and since it is not common, there is no hardware optimizers available for processing those structures. as far as i know even the most common data structures like trees, graphs dont get any extra benefit from underlying PC hardware.
one mid-conclusion; it is easier to program a first person shooter than to program a game like civ. because the 3D programmer has an arsenal of hardware/software optimizers on his disposal, whereas the civ3 programmer has to reinvent the wheel most of the time because he is doing something unique.. 3D programmer just develops the code using some existing libraries, he does not care (much) about optimization because he knows they are very well handled at a lower level either by OpenGl or even lower by hardware. civ programmer on the other hand; has to carefully profile & debug each piece of code he is developing.
so what can they do; they have to carefully profile their code and find out any bottlenecks if any. then; if the problem is poor coding (pray for it), they fix it. if not, i mean the algorithm is fine but it is running slowly due to its nature; the best they can do is to program it in a lower level language. in an interview, soren said they had programmed it entirely in c++, so they can re-program slowest & most used routines in machine code.. but given the complexity of civ3, i doubt they dare such an action.
just for the curious ones; for certain problems/algorithms, computer science today cannot suggest algorithms running in REASONABLE times, not because the algorithms are exteremely complex but because given the current way of THINKING & PROGRAMMING, no one yet has been able to invent a better solution.
it seems obvious to me that the real factor slowing the game down is the number of existing units at a time. on a standart map with 16 civs, game runs smootly; on huge map with 16 civs it crawls. most probably more landspace means more cities; more production; more units at the end. somehow, AI turns increase exponentionally as the number of civs & land area increases.
so what we can do is to sit down and pray its due to poor programming. if so, sooner or later they fix it in a patch. if not, we might have to wait for a couple of years in order to play smooth games on huge maps..
|
|
|  |
 |
|
Cavalier_13
|
|
Montreal
Nov 2001 time: 00:16
|
|
What I can't seem to understand is why people don't seem to know WHEN the slowdown is occuring........you all say it's during the movement of the AI, and in a way, you are all correct in your assumptions, but very wrong in your logic. Let me explain.
In the beginning, the AI turn are quicker due in minor part to the smaller amount of units, but mostly because of 2 things......TRADE NETWORK and CULTURAL INFLUENCE BORDERS (TN and CIB for short). I have tested this out extensively and I believe that my research supports my claims.
CIB is the smaller of the 2 slowdown factors in that it does not occur every turn, but rather in different cities and staggered according to the cultural rating of the city......the threshholds are 10, 100, 1000 and 10000 (as you all know). Since you will USUALLY be able to make it to the upper 100's level before you meet up with another CIV's borders with your own, the game can simply expand your borders and not need to calculate your gain vs the computer loss. But as they start to overlap, the computer must resolve the "disputed" squares and does so every turn. I don't know if anyone noticed, but a CIV may encroach in your CIB one turn, and a few turns later, you take that square back.....it is a constant back and forth........
But the REAL killer in the whole thing is TN. The trade network is the WHOLE woe of the slow speed. The TN is determined by 3 things....roads, harbours and airports. As you gain more and more cities and the TN becomes more elaborate, any modification to the TN cause the game to recalculate the TN for the WHOLE map everytime. Allow me to prouve this.....
Take for example a civ with 30 cities that builds a harbour. Ever notice that there is a HUGE delay as the harbour is done? This is the game calculating the whole TN of ALL the civs involved since all civs use the TN of other civs, regardless of traties. The only exception is war. You can't use a civ's TN that you are at work with and vice-versa. Now, destroy a road at a critical junction (a place with a 1 square choke hold or a road on a resource). When that happens, again, the whole TN is recalculated to see where civs will get their resources. I have personally seen the game take 8 minutes after one of my sea bombardment hits destroyed a harbour in a rival civ.
Now look at the loading times. The long load times are not due to the file sizes, but the fact that the computer calculates the TN when reloading. I have timed it and it takes the same time as when I destroy a harbour at that point. I tried it n several instances and the times are almost the same. If it take 1 minute to calculate the addition of a harbour to your civ, it will take about the same time to load the game. If it took 3 minutes, it would take 3 minutes to load.
Now, as far as the movement of units, you must understand that the MILLIONS of calculations per second of CPU's is MORE than enough to move the units quickly. I stole the plans of all the civs on a huge map with 16 civs and ended the turn. With unit anims off, the movement was quick and fluent.....only pausing when, you guessed it, the TN was modified or CIB was modified.
Comments welcomed, flames will be retarded. 
Cavalier
|
|
|  |
 |
|  |
 |
|
RedWhiteArcher
|
|
I want to play on huge map too, but face it, if the problem of the speed isn't going to be fixed (and it most probably won't) just won't finish a single game you start. Standart map is large enough anyway. Yes its wrong but what can you do about it.
2 choises:
1) waste your time and ruin the game experience.
2) play with a delay but much smaller one and have a good game experience.
|
|
|  |
 |
|
CobaltNova
|
|
I just recently got Civ 3, and have not gotten to a point when comps actually have railroads (playing a low difficulty level the first time plz don't laugh). I play on a huge map, and have a railroad across a large section of it. With auto animations off, it takes approx 3 to 5 seconds to move settler from one side to the other. I have a 933 mhz Pentium 3 (not the P4 with 2 times as many pipes). There is no combat that turn, no units in the way, no movement graphics being shown, and (this prob doesn't matter) the entire area is within my culture and has no units in the way of its path.
Seeing as how the pathing was done before the move, why does the computer take so long to auto-move a unit? Its just: get next spot off path list, ensure spot is clear, update x,y coords, is this last move?-repeat. Its like 150 squares tops. Even if it takes 10 cpu cycles (outrageous) per move it should only 1 and a half or so seconds! Take that times 100 computer moves that you don't see times 15 other comps and it is a wonder the wait isn't longer. It seems to me that it isn't the AI "thinking" more an almost insignificant railroad movement bug times a lot of units.
|
|
|  |
All times are GMT. The time now is 05:16. Apolyton Time is 00:16. |
top of page
|
| archivepost |
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|