| General | Hosted Sites | Civ5 | CivRev | Civ4Col | Civ4 | Civ3 | Civ2 | Civ1 | Misc | Marketplace |
![]() |
|
|
Welcome to Civilization Fanatics' Center. You are currently viewing our site as a guest which gives you limited access to our site features. By joining our free community, you will be able to participate in the discussions, search the forum, send private messages, vote in polls, upload your own screenshots to the gallery, and access many other special features. Registration is fast, simple and absolutely free, so sign up today! If you have any problems with the registration process or your account login, please contact support. |
|
|||||||
![]() |
|
|
Thread Tools |
|
|
#1 |
|
Warlord
Join Date: Aug 2011
Posts: 122
|
1UPT rules out multicore AI
The long turn speeds is because of one reason: 1 unit per tile.
In Civ 4, it doesn't matter if there is a unit on tile X. The AI can move units in any order, in parallel, and at the end check for collisions between different armies (combat). Think of it like this: Core 1: Best move for unit A. Core 2: Best move for unit B Core 3: Best move for unit C Core 4: Best move for unit D Civilization V: Core 1: Best move for unit A Core 2: Cannot calculate, because unit A needs to move first otherwise there will be stacked units Core 3: Sitting idlely Core 4: Sleeping Unit movement speeds have just quadrupled on a four core. |
|
|
|
|
|
#2 |
|
Emperor
Join Date: Apr 2007
Location: Australia
Posts: 1,669
|
...so, which online university did you do your computer science course at?
Moderator Action: if you disagree with a user's post you are welcome to criticize/discuss the content of the post, attacking the user themselves is unacceptable. - ori Please read the forum rules: http://forums.civfanatics.com/faq.php?faq=updated_rules_2011
__________________
The man said ,"I wouldn’t vote for you if you were the Archangel Gabriel", to which Menzies replied "If I were the Archangel Gabriel, I’m afraid you wouldn’t be in my constituency". Last edited by ori; Sep 20, 2011 at 12:36 PM. |
|
|
|
|
|
#3 | |
|
King
Join Date: May 2005
Posts: 628
|
Quote:
|
|
|
|
|
|
|
#4 |
|
Warlord
Join Date: Apr 2011
Location: Earth
Posts: 226
|
|
|
|
|
|
|
#5 |
|
Chieftain
Join Date: Sep 2011
Location: Sydney, Australia
Posts: 5
|
If the AI in CiV worked like the OP thinks it does (and I know enough to know it doesn't), then one could note that his CiV AI could use multiple cores by the simple expedient of each core moving units in different areas of the map.
|
|
|
|
|
|
#6 |
|
Flawless
Join Date: Feb 2008
Location: Norway
Posts: 921
|
1UPT does make pathfinding require more resources (and therefore longer TBT), but it's not like the AI can't use multicore CPUs and having a quadcore instead of a dualcore will shorten the TBT.
|
|
|
|
|
|
#7 |
|
Warlord
Join Date: Sep 2005
Posts: 137
|
One thing I've never understood is how Civ 1 on my Amiga was markedly quicker than Civ 5 is on a speedy PC. I understand that the game is more complex these days, but given the 1,000fold increase in processor power between the two PCs, I don't think the game is 1,000 times more complex.
Is it just laziness from programmers that they think they don't need to optimise things cos computers are so much faster and people are simply used to relatively long turn times? |
|
|
|
|
|
#8 |
|
Prince
Join Date: Mar 2004
Location: On this forum
Posts: 562
|
Empirical evidence argues against you. I can set up system monitors that report usage. The NVIDIA drivers seem to have a good report tool. It does show the system using all 4 cores in between turns. I am not saying they are being used efficiently, but they seem to be in use.
Your programming algorithm assumptions seem off to me. If the AI is already aware of a simultaneous turn algorithm for Multi Player, (however badly that may function) then there is nothing that prevents it from using that same code for in between turns on Single Player. Why invent two sets of AI codes?
__________________
If you aren't confused, You don't understand |
|
|
|
|
|
#9 | ||
|
King
Join Date: May 2005
Posts: 628
|
Quote:
But more than that...You don't move units X and Y independently. The best move for unit X often depends on where you're putting unit Y and unit Z. If it worked the way the OP suggests it would, then the AI would be completely incapable of using units in a coherent manner because they would constantly be moving all over the place. Finally, it assumes that there are absolutely no other tasks at around the same time that could be done in parallel. If the AI is currently moving its units around, then it cannot think about anything else in its turn other than moving those units in that singular location around. Quote:
Last edited by GenocideBringer; Sep 20, 2011 at 06:49 AM. |
||
|
|
|
|
|
#10 | |
|
Chieftain
Join Date: Sep 2011
Posts: 82
|
Quote:
|
|
|
|
|
|
|
#11 | |
|
Scout
Join Date: Dec 2001
Location: Berlin, Germany
Posts: 3,393
|
Quote:
Releasing a strategy game today whose AI adheres to the standards from 1991 ... would be like releasing a shooter with VGA graphics. Last edited by Psyringe; Sep 20, 2011 at 07:31 AM. |
|
|
|
|
|
|
#12 |
|
Limit 1 Facepalm Per Turn
Join Date: Aug 2011
Location: Ontario, Canada
Posts: 1,038
|
Man... you would have each core working on a different facet of unit A. After that's done, each core would work on a different facet of unit B.
Or each core would in fact manage several units in tandem since they all have to take each other into account (ideally). If anything 1UPT would make multicore more beneficial, I couldn't imagine a universe where it would make it less. |
|
|
|
|
|
#13 | |
|
King
Join Date: Jul 2008
Location: Finland
Posts: 835
|
Quote:
Core 1: Best move for unit A partition 1 Core 2: Best move for unit A partition 2 Core 3: Best move for unit A partition 3 Core 4: Best move for unit A partition 4 That is, divine the path finding problem of an unit to four partitions that each take roughly the same time to finish. Btw. the whole approach of calculating movement for one unit at a time, independently from movements of other units, is flawed if you want the AI to be competitive (although that is the way it's probably done, and that's why the AI throws its ranged units and generals in front etc.). |
|
|
|
|
|
|
#14 | |
|
Emperor
Join Date: Nov 2003
Location: Southern California foothills
Posts: 1,849
|
Quote:
The main advantage, and the main perceived speedup from running Civ on a multicore machine seems to stem from the fact that hardware interrupts and CPU calls from other processes running in the background are less likely to deprive Civ of a CPU core.
__________________
If you need to look up one of our many Civ-related acronyms (UA, CKN, MPM, NC, etc) or terms try the Civ5 Guide to Acronyms and Terms. |
|
|
|
|
|
|
#15 |
|
Gods & Emperors
|
Ironic considering that Civ5 is the first Civ game to take advantage of multi-core CPUs.
LOL.
__________________
![]() ![]() ![]() Machiavellian Doctrine: Managing The World | Mod Epic (Game) Mod |
|
|
|
|
|
#16 |
|
Warlord
Join Date: Sep 2005
Posts: 137
|
A couple of fair points re: the Amiga v Fast PC issue.
Although I will say this - I don't remember the AI being really bad in earlier Civs - especially Civ 1. Of course, I was obviously not as experienced as I am now - but I do remember being shocked and pleasantly surprised when I was playing a game on the highest level and all of a sudden, a supposed friend turned up on my doorstep out of the blue and took out my cities with battleships and tanks. I'm guessing this was because I'd recently shipped my entire army to the end side of the world to take out a mutual enemy. I realise this isn't really representative, but I've never seen that in the latest CiV! |
|
|
|
|
|
#17 |
|
King
Join Date: May 2005
Posts: 628
|
Keep in mind that whenever you add new mechanics, the AI has to be taught to use them. Even back in the 90s, a computer was able to beat one of the best chess players in the world, because Chess is fundamentally a simple game. Even with such a simple game, the AI that beat Kasparov was run on an extremely powerful supercomputer.
Civs 1 and 2 were far simpler, as far as number of mechanics goes, than Civ IV or V. Creating an AI that can properly take advantage of all of these mechanics is going to be way, WAY more demanding on the processor. It's not that the Civ V devs are just incompetent at designing AIs, it's just that there's a limit to what modern processing power can do and any AI improvements need to be done with that in mind. A good human player in a game with as many mechanics and nuances as Civ V is going to rape the face off of any AI that could actually feasibly run on a modern computer. What you're seeing isn't the Civ V devs being incompetent, it's the limitations of AI. Of course, the AI can still be made better - it can always be made better. It's just that the idea of a truly intelligent AI, being able to compete one on one with an experienced Civ player, is a pipe dream. Last edited by GenocideBringer; Sep 20, 2011 at 11:30 AM. |
|
|
|
|
|
#18 | |
|
Gods & Emperors
|
Quote:
This is my biggest concern. Alpha Centauri is often lauded for its depth, but it had a lot of features the AI couldn't handle. So features discussions always comes with issue on whether the AI can handle it. And the Civ franchise from III on has had a fairly mixed/positive record on this. On one hand, there is a stated commitment to provide symmetry between human and AI, on the other hand, gameplay preferences tend to create things like vassals, religion, right of passage agreements that the AI can't fully handle and can only be forced to use in a very restricted way. Civ5 have issues where the AI get to do things, like taunt, ask for gifts, that human players can't do. Those things always annoy me. But I think this will be a struggle we'll have forever as long as Civ is a commercially facing franchise that prioritizes sales and gratification of fans over fairness and total balance (ie: As Soren noted, providing some slack in the AI can give more fun than having a tight game that's restrictive ) But it's definately a balancing act, and I feel there's a tendency in the fan community to go completely for fun features and it's far easier to argue for vassal states,colonies and all that stuff than to say 'no we can't do it; let's imagine those same things more abstractly using known limitations and taking into account what the AI can handle'
__________________
![]() ![]() ![]() Machiavellian Doctrine: Managing The World | Mod Epic (Game) Mod |
|
|
|
|
|
|
#19 | |
|
Scout
Join Date: Dec 2001
Location: Berlin, Germany
Posts: 3,393
|
Quote:
Civ1's AI had a line in its code that literally said "If the year is 1900, and if the player is in the lead, attack him." It was very crude. But most players simply didn't have the necessary experience to evaluate an AI and attributed a level of reason to it that was far beyond the real thing. In your example, you "assume" that the AI had a good reason for its decision, when in fact it may just have triggered the very crude line of programming I quoted above. (Actually I doubt that the Civ1 AI had any concept about where the player's armies were, but I'm not 100% sure.) Another example is that Civ1 tried to bring trailing AIs back into the game by gifting world wonders to it. It's blatant cheating, but as players, many of us assumed that the AI had actually built that wonder, when in fact there was just an algorithm that decided "This AI has fallen behind, I'll grant it a free world wonder so that it can catch up." If such an AI were released in a modern strategy game, people would criticize it heavily. They would recognize (and rightfully criticize) that an "attack player when he's leading" algorithms devaluates peaceful approaches - no matter what you do, the AI will eventually be out to get you, even if you were partners for millennia, even if it's against the best interests of the AI. They would also identify the "free world wonders" as blatant cheating (in hindsight, it would have been easy to identify in Civ1 too, as the AI often "built" wonders in cities that had no way of providing the necessary amount of shields). This can actually be seen in players' reactions towards the Civ5 AI, which in several ways was a step backwards to the Civ1 AI (at least on release, I don't know if and how much it has improved by now). But exactly the same things that were okay for Civ1's AI were heavily criticized in Civ5, and rightly so. It simply isn't acceptable to go back to the primitive and crude ways of AI design from 20 years ago (especially not if the AI _still_ takes a lot of time to process its actions, even on modern hardware).
|
|
|
|
|
|
|
#20 | |
|
Scout
Join Date: Dec 2001
Location: Berlin, Germany
Posts: 3,393
|
Quote:
On the other end of the spectrum, you have games like "Galactic Civilizations". The AI in these games works quite well, but the game was designed from scratch with the goal to be manageable for contemporary AI algorithms. As a result, the games end up as favorites of players who want strong AIs, but are criticized by other players for feeling bland and formulaic. For the time being, if you design an AI, you have to find some middle ground between a game that's rich in interesting features and a game that features a strong, competitive, non-cheating AI. You can't have both. The best way of doing it is (imho) the way that Civ4 chose: Ship with a decent AI, but release the AI code so that the community can improve it. The casual players will be satisfied with the original AI, and the hardcore players (who won't be) are free to improve it. (Side note: I think that even contemporary AIs _could_ be much better than they are if AI programming was seen as more important by game designers and especially publishers. But this is wishful thinking, as Jon Shafer revealed during that now famous talk round, in which he fully acknowledged that publishers have no reason to invest in a good AI as it wont increase their business. While I do disagree with this statement, it accurately reflects the current line of thinking among the people who finance game development.) |
|
|
|
|
![]() |
| Bookmarks |
|
| Thread Tools | |
|
|