Moderators: phlip, Larson, Moderators General, Prelates
W3bbo wrote:
Given a set of constraints on these members (e.g. Faction X's units must all have greater HP and cost than Faction Y), does there exist an algorithm which ensures no faction has any inherent advantage over another? And if so, can it be solved in polynomial time? Is it possible to solve it without resorting to a brute-force of every battle scenario?
If you start an argument over whether "they" "them" and "their" can be used as gender neutral singular pronouns, in this thread, I will do terrible, terrible things to you.
-Belial
Derek wrote:It is theoretically possible though, and would be NP-Complete (for most games).
The Reaper wrote:Evolution is a really really really long run-on sentence.
Surg wrote:Derek wrote:It is theoretically possible though, and would be NP-Complete (for most games).
What would be the polynomial sized certificate for a balanced game?
EvanED wrote:I disagree it's even a well-defined question; for many reasons such as the ones game_boy alluded to.
For instance, suppose that your game covers the epic battles of Snorks vs the Blubs. For simplicity's sake, say each side only has one kind of unit, with equal cost and production abilities. As it happens, Snorks will reliably beat Bulbs one-on-one, but with a catch: they require absolutely intense, perfect micro. Without that micro, Snorks will win every time. (Perhaps Snorks have some kind of homing attack, but with some fancy maneuvers, the Blubs can dodge it.) The crossover point at which win rates are about 50-50 is, say, 300 APM.
EvanED wrote:Is the game balanced?
EvanED wrote:If not, which side is better?
W3bbo wrote:Ninja-edit 2: This paper, released a few days ago, is almost relevant to this thread: http://arxiv.org/pdf/1201.4995v1.pdf although it is more concerned with the complexity of play rather than balancing - there is a paragraph on Starcraft near the end.
The Reaper wrote:Evolution is a really really really long run-on sentence.
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:The other nebulous constraint on balancing is keeping the game fun and hence marketable. The game can be trivially balanced by making only one race playable.
W3bbo wrote:Game_boy wrote:The other nebulous constraint on balancing is keeping the game fun and hence marketable. The game can be trivially balanced by making only one race playable.
That's what Warcraft 1 and Starcraft 2 did... just saying
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:@freakish
Yes, but you've solved the wrong problem. Balancing the game for Optimal Players is nothing like balancing for those operating at the limits of human performance - let's say 400 useful apm and a certain eye-speed/gamestate information input rate, even assuming perfect decision making. In my earlier posts I tried to explain how a game that was balanced for Optimal Players is indeed balanced but also worthless.
The other nebulous constraint on balancing is keeping the game fun and hence marketable. The game can be trivially balanced by making only one race playable.
Game_boy wrote:W3bbo wrote:Game_boy wrote:The other nebulous constraint on balancing is keeping the game fun and hence marketable. The game can be trivially balanced by making only one race playable.
That's what Warcraft 1 and Starcraft 2 did... just saying
Starcraft 2 is pretty balanced at a competitive level now? Matchups about 50% on Korean and International databases?
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:@freakish
A player with limited (low) apm has far less micro options and also sacrifices keeping up macro while microing. Currently pure phoenix (range 4) completely counters pure mutalisk (range 3) but no one is capable of microing hard enough to not lose phoenixes while engaging.
void PlayGame()
{
while (!GameOver)
{
MakeDecisionAndExecute();
Sleep(495); //sleep for 495 millisecond
}
}
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:I meant low = 300-400. You still can't micro or keep up production near perfectly with that.
And I don't mean mechanically implementing such a bot. The thread is about a CS problem in perfect balance
and I don't think this is possible in a limited-apm system.
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:I DO understand computer code and basic maths you know.
freakish777 wrote:Then why do you keep bringing up apm? How is it relevant to the conversation at this point? (you mentioned that we need to ensure that we don't try to balance for computer players who have higher apm than humans, because that wouldn't be balanced for humans, I mentioned that that's really not a big deal, here's how you keep that from happening, you continue to mention apm).
The Reaper wrote:Evolution is a really really really long run-on sentence.
phlip wrote:freakish777 wrote:Then why do you keep bringing up apm? How is it relevant to the conversation at this point? (you mentioned that we need to ensure that we don't try to balance for computer players who have higher apm than humans, because that wouldn't be balanced for humans, I mentioned that that's really not a big deal, here's how you keep that from happening, you continue to mention apm).
No, he mentioned Optimal Players as opposed to humans with all their human limits. APM was merely an example.
Take, say, a hypothetical: Player A is able to get 100 resources per minute, without having to do any action. Player B, has a button they have to click regularly - after each click it is disabled for a minute (so clicking it early does nothing, but clicking it late wastes time), and clicking this button gives 101 resources. An Optimal Players analysis would give the advantage to player B, even analysing it with a restricted APM (since it only takes one action each minute). However, with a human in the driving seat, they have to hit this button within 0.6 seconds of it becoming enabled, every single time, on the dot, otherwise they end up worse off. And I think most players would declare this as unbalanced in favour of A. The question of how many resources player B's button should provide every click in order for it to be "fair" is a question that's hard to well-define, let alone be solvable. In practise, the ideal amount of resources to give would vary depending on the skill level of the players - many values would have it be simultaneously such that player A has an advantage among new players, while player B has an advantage among experts. So you'd have to pick a target skill level that you want to be "balanced", whether that's the average player, or the top tier, before the question of how to balance it even has a hope of being defined well enough to be worthy of throwing some maths at. And the choice there depends on the target audience of the game... whether they're going for mass appeal, or a tournament scene, or what have you.
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:Hvaing just added all those caveats to your method, you're no longer saying anything new.
Is there something wrong with the approach I've given from a Computer Science perspective?
freakish777 wrote:In the example given (obviously there are things like Chrono Boosts and Mules that are similar to this but not quite the same)
freakish777 wrote:What exactly is your aversion to real discussion?
phlip wrote:freakish777 wrote:In the example given (obviously there are things like Chrono Boosts and Mules that are similar to this but not quite the same)
Yeah, it's SC2 that I was thinking of - specifically, comparing the three races' basic macro spells - Mule, Spawn Larva, and Chrono Boost. With the Mule and Chrono Boost, if you're a bit late with one, or miss one entirely, you can catch up later (within reason, as long as your OC/Nexus doesn't max out on energy)... you can do a mule drop every 80 seconds, or a Chrono Boost every 40... but say you miss a mule drop, and end up doing one 2 minutes after the previous one, instead of 80 seconds... then you only need to wait 40 seconds before you can do it again - you end up with the same amount of resources, you just are a little bit lower for a brief period, and then catch up. The same applies to Chrono Boost.
With Spawn Larva, however, if you miss one, or are late with one, there's no catching up... you can't bank up larva inject time like you can with energy on the OC/Nexus... regardless of how late you are with a Spawn Larva, you still need to wait 40s before you can use Spawn Larva again on the same hatch.
The end result is that, in regards to this small segment of the game, Zerg is a less forgiving race than the other two. Depending on how you choose to balance these abilities, you either get that low-level Zerg players will have a disadvantage compared to low-level players of other races, or high-level Zerg players have an advantage over high-level players of other races.
For a non-factional example, compare Gateways with Warp Gates - Gateways let you queue units, so you have no downtime... you can queue the next unit shortly before the previous one finishes, and there'll be no down-time. Warp Gates on the other hand have no queue, so any time between cooldown finishing and you warping in the next round is wasted downtime. However, Warp Gates' cooldown is 5 seconds less than the time it takes to build a unit at a Gateway, so you can build units more quickly with Warp Gates... as long as you're always returning to the warp gates within 5 seconds of the cooldown ending. Warp Gates also have other advantages, like getting the units earlier (you get the unit at the start of the cooldown, instead of the end of the build process), and the whole warp-in-across-the-map thing, which are also harder to factor in. But the upshot is that you never see a high-level player intentionally keep gateways when warp gates are available, but at the very low levels, it's sometimes tempting to keep them as gateways, as the queues can compensate somewhat for terrible macro (as inefficient as they are for competent players).
freakish777 wrote:What exactly is your aversion to real discussion?
Well, from my skim reading, you basically just seem to be using a lot of words to say "you do the best thing to do, by finding the best thing, and then doing it, where 'best thing' is defined as the thing which is the best"... it's sorta hard to respond to that in any sort of in-depth way.
The answer to "can a program do x?" is not "yes, by making a heuristic, and then having that heuristic do x", no matter how many words it takes to say it.
freakish777 wrote:You're splitting your players into "skilled enough to, on average, leverage it into an advantage over those not skilled enough." [...] To balance and try to maintain it being fun, you'd want to set up your bots at different skill levels.
freakish777 wrote:This (really rough) algorithm
phlip wrote:freakish777 wrote:You're splitting your players into "skilled enough to, on average, leverage it into an advantage over those not skilled enough." [...] To balance and try to maintain it being fun, you'd want to set up your bots at different skill levels.
... And then what? When your different-skill-level bots come back and give different answers to the question of "what do I have to do to make this balanced?", what do you do then? From a CS perspective.
freakish777 wrote:This (really rough) algorithm
Which is exactly the problem. It's like you're talking with someone about how to build a house. And your answer goes into great detail about buying a plot of land, and gives exact instructions on how to arrange a loan, and get the land titles sorted out, and the like. And then you just say "and then you build a house on it". The bits that you're handwaving away as "a heuristic", "find the most optimal action" or "DecideAndExecute()" are the interesting parts of the problem, while the bits you're going into detail on are just a framework. It's hard for people to get excited about a framework.
freakish777 wrote:It's like you're talking with someone about how to build a house. And your answer goes into great detail about buying a plot of land, and gives exact instructions on how to arrange a loan, and get the land titles sorted out, and the like. And then you just say "and then you build a house on it".
That's because Heuristic is a well defined term:
http://en.wikipedia.org/wiki/Heuristic#Computer_science
freakish777 wrote:In this particular example, we want to modify our heuristic with each iteration to improve it so it more accurately reflects the game, which is (in my opinion) exciting
freakish777 wrote:Resource Value = F(t) = ((Slope * t) + BaseValue)
Unit[x] value Creation = F(t, enemyComposition) = ((Slope * t) + BaseValue) - UnfavorableEnemyComposition(enemyComposition, x)
Unit value Placement = F(positionA, positionB, t) = SomeConstant(TimeConstantA*t*distance(positionA, positionB) + SomeOtherConstant)
Map Visibility = F(percentageUncovered, t) = (KnowledgeConstant * percentageUncovered) - (TimeConstantB * t)
[...]
When you modify your heuristic, you're modifying BaseValue, Slope, SomeConstant, TimeConstantA, SomeOtherConstant, etc (even the type of function could be updated, but that adds a huge layer of complexity that shouldn't be necessary).
freakish777 wrote:Decide of DecideAndExecute() is just Minimax executing at as shallow a depth as possible (since we're an RTS, we don't have time to figure out what the best plan is if it takes more than X time to figure out, we're better off pretending our heuristic gives us a perfect valuation each time and executing immediately, since we're going to change our heuristic for the better with each iteration anyways). [...]
phlip wrote:freakish777 wrote:It's like you're talking with someone about how to build a house. And your answer goes into great detail about buying a plot of land, and gives exact instructions on how to arrange a loan, and get the land titles sorted out, and the like. And then you just say "and then you build a house on it".
That's because Heuristic is a well defined term:
http://en.wikipedia.org/wiki/Heuristic#Computer_science
It's certainly at least as well-defined as "house".
freakish777 wrote:In this particular example, we want to modify our heuristic with each iteration to improve it so it more accurately reflects the game, which is (in my opinion) exciting
It certainly is. That's kinda why it'd be better if you looked more into that, rather than just handwavily saying "and then you modify the heuristic". I get that it's a challenging thing to do. That's kinda the point. You really do seem to be saying both "it's easy, you just do x", while simultaneously saying "I don't want to go into details about x, it's too hard".
Besides, you've said "a heuristic"... you can give more details than that, without needing to get into the particulars of a given case. How approximate are we talking here? Something like a greedy algorithm, which is pretty simple, but often quite far off the mark? Or something like a neural net, much more complicated, and hard to analyse, but giving better results? Or someting akin to the Christofides algorithm, hand-tailored to the problem, and giving a result that's at least close to the right answer in all cases? And then, how do you modify it every iteration, as you suggest? For a neural net this is built-in, but for the hand-tailored option this is very non-trivial. What level of approximation are we working at?
freakish777 wrote:Resource Value = F(t) = ((Slope * t) + BaseValue)
Unit[x] value Creation = F(t, enemyComposition) = ((Slope * t) + BaseValue) - UnfavorableEnemyComposition(enemyComposition, x)
Unit value Placement = F(positionA, positionB, t) = SomeConstant(TimeConstantA*t*distance(positionA, positionB) + SomeOtherConstant)
Map Visibility = F(percentageUncovered, t) = (KnowledgeConstant * percentageUncovered) - (TimeConstantB * t)
[...]
When you modify your heuristic, you're modifying BaseValue, Slope, SomeConstant, TimeConstantA, SomeOtherConstant, etc (even the type of function could be updated, but that adds a huge layer of complexity that shouldn't be necessary).
Ah, I see, the "spherical cow" level of approximation.
freakish777 wrote:Decide of DecideAndExecute() is just Minimax executing at as shallow a depth as possible (since we're an RTS, we don't have time to figure out what the best plan is if it takes more than X time to figure out, we're better off pretending our heuristic gives us a perfect valuation each time and executing immediately, since we're going to change our heuristic for the better with each iteration anyways). [...]
See, this is what I'm talking about. You spend a lot of words describing something simple like minimax, spending most of your time offloading the complexity into the heuristic. But the heuristic you mentioned is also very simple, and you spend most of your time offloading the complexity into the iterative processing. But the iterative processing you mentioned is also very simple, and you spend most of the time offloading the complexity into the various parameters. Which you then handwave away. And what you're left with is a bunch of words describing the simple edges of the problem, and all the complex middle of the problem is just a big handwavery vague gap.
The Reaper wrote:Evolution is a really really really long run-on sentence.
Game_boy wrote:What you're saying is obvious.
If you were doing a shortest path algorithm it would be like:
Define each node on the network as a Point. A Network is a collection of Points arranged in a network. Define a path as a set of Points in the Network of Points such that there is a Path betweeen each Point on the Network, such that there is a Path. "Short Path" is a Path that is short.
Our heuristic is a Heuristic which finds a Short Path in the Network by some parameters <short> <path> and <network>. At Time T, the shortest Path "P" on the Network is a path that is the shortest. SomeOtherConstant is a Constant that isn't the same as TheFirstConstantIWasReferringTo.
Routine <CalculateShortestPath> calculates a Network Path that is Short for an acceptable value of Shortness that is an attribute of a Path. Simply run <CalculateShortestPath> with the given parameters and you will get a suitably short Path as output.
The Reaper wrote:Evolution is a really really really long run-on sentence.
Koa wrote:People lose games through sheer frustration of certain strategies regardless of their actual effectiveness.
A human can't pay attention to 10 different engagements on the map at once, whereas a bot, even with a speed limitation, would.
If you don't replicate human limitations properly
Also, you can't really have a computer teach itself to play an RTS such as SC2 using genetic algorithms.
There have been serious attempts to make bots for BW
Things like a single worker would ruin the bot's economy because the bot would constantly make a wrong decision to never attack it.
The amount of information that you would have to teach a bot in order for it to teach itself would be enormous.
But even assuming that you could overcome all of these issues, how could you derive any sensible data from such a bot for the end of balancing? Let's say that a bot can obtain a 95% winrate using marines or something (which it likely would unless you accurately replicate human limitations). What parameters of the game do you change to fix this issue? Is it marines themselves, or is it that the other races don't have an answer for marines?
What if the other races DO have an early game advantage, but it just hasn't been discovered yet? Such a bot could only be a vague consultant for balancing concerns.
I think it would be important to define what is balance
freakish777 wrote:Not relevant for creating a balanced game. 100% necessary for creating a fun game, but that isn't what was asked for.
I never said "Just limit APM, that's all you need to do." I said "There's things you can do, like limit APM, to make a bot approximate a human player." Set 4 (X,Y) coordinates and have them represent a screen, only give bots information on units that are within the boundary lines. Not particularly complicated.
I didn't suggest using a Genetic Algorithm to have a computer "teach" itself how to play. I suggested using a GA for it to learn the variable/function values for it's heuristics that it uses to determine how important a unit/building/game variable is.
Serious attempts by who? Source?
This doesn't sound at all like a learning system, but rather someone who hard coded a bunch of static strategies and said "Pick from one of these pre-existing strategies."
The reason Blizzard doesn't have bots that balance games for them isn't a technical one, but an economic one.
Let's make an assumption that the units and building in the game are static (game design has finished, graphic artists have started animating all the motions for units, story people are placing final touches on any story involved in a single player campaign, Software Engineers are nearing completion) and so are the mechanics (you're not allowed to change the actions available to a unit, add or subtract units, etc, just change variables such as Speed, Speed of Attack, Damage per attack, Cooldown Rate, Build Rate, etc).
Users browsing this forum: No registered users and 0 guests