Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 9 10 [11] 12 13 ... 31

Author Topic: Proceedurally Generated RTS  (Read 57089 times)

Fayrik

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #150 on: January 27, 2011, 04:40:10 pm »

Hmm, well, I see your point...

Actually, seeing that new compile, everything looks fine from here. Eheh.
Logged
So THIS is how migrations start.
"Hey, dude, there's this crazy bastard digging in the ground for stuff. Let's go watch."

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #151 on: January 27, 2011, 04:54:03 pm »

Actually, seeing that new compile, everything looks fine from here. Eheh.

I can push that 3x up to about 50x before I start exceeding the number of flops I can perform in 1/30th of a second (i.e. bog down the frame rate).

So yeah.  My issue now is locating the cases where #1 beats both #2 and #3 (etc.) and keeping that from occurring.
Logged

Nivim

  • Bay Watcher
  • Has the asylum forgotten? Are they still the same?
    • View Profile
Re: Proceedurally Generated RTS
« Reply #152 on: January 31, 2011, 10:28:19 am »

Quote from: Nivm
If your triangle has irregularities, do you think you could draw that geometric figure even in description? Are you trying to define the distance from the center of the triangle as an absolute strength of a unit, or its strength relative to other units?
I think I understand you here, and I think the answer is "relative strength."
And the first question? Are you avoiding that particular idea, for at the moment it is just an idea, or do you not see it?
Logged
Imagine a cool peice of sky-blue and milk-white marble about 3cm by 2cm and by 0.5cm, containing a tiny 2mm malacolite crystal. Now imagine the miles of metamorphic rock it's embedded in that no pick or chisel will ever touch. Then, imagine that those miles will melt back into their mantle long before any telescope even refracts an image of their planet. The watchers will be so excited to have that image too.

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #153 on: January 31, 2011, 10:58:41 am »

Quote from: Nivm
If your triangle has irregularities, do you think you could draw that geometric figure even in description? Are you trying to define the distance from the center of the triangle as an absolute strength of a unit, or its strength relative to other units?
I think I understand you here, and I think the answer is "relative strength."
And the first question? Are you avoiding that particular idea, for at the moment it is just an idea, or do you not see it?

I don't know how you mean.  I don't understand what the points of the triangle are, etc.
Logged

Nivim

  • Bay Watcher
  • Has the asylum forgotten? Are they still the same?
    • View Profile
Re: Proceedurally Generated RTS
« Reply #154 on: January 31, 2011, 06:52:14 pm »

 If you're looking for a triangle, how can you find it if you haven't defined what the points are? At first I assumed you were looking for three min-maxed units that would each wipe out one of the others and be wiped out by one of the others, which leaves your sides as simple average win/lose ratios. But looking at how your searching for these ~points and how you describe such a triangle as irregular, it seems more like you're creating a circle with the distance from the center as the unit's relative strength, then trying to bend that into a triangle. Or perhaps there are many valid overlapping triangles with points in the general shape of a circle.
 Either need a new shape to describe this, or different definitions for the original shape. I guess it doesn't matter much, as long as you're ignoring this triangle concept, but it would make it easier for me, and hopefully others, to understand what you're doing.
Logged
Imagine a cool peice of sky-blue and milk-white marble about 3cm by 2cm and by 0.5cm, containing a tiny 2mm malacolite crystal. Now imagine the miles of metamorphic rock it's embedded in that no pick or chisel will ever touch. Then, imagine that those miles will melt back into their mantle long before any telescope even refracts an image of their planet. The watchers will be so excited to have that image too.

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #155 on: January 31, 2011, 07:14:53 pm »

If you're looking for a triangle, how can you find it if you haven't defined what the points are?

Imagine a Cartesian grid that is 30 units wide and 30 units tall.  How many triangles are there?  Do all of them have the same orientation?  Are all of them the same size?  Are all of them equilateral?

Quote
At first I assumed you were looking for three min-maxed units that would each wipe out one of the others and be wiped out by one of the others, which leaves your sides as simple average win/lose ratios.

Correct.  The win/loss ratios would form the edges.  However, I'm not looking for min-maxed units, simply a minimum win/loss ratio (a unit should win and still retain a certain % of the group's total health--eg. 10 units vs. 10 units should have 3 units left at full health, or 6 at half, etc. (or better) to conform to a 30% health threshold).

Quote
But looking at how your searching for these ~points and how you describe such a triangle as irregular, it seems more like you're creating a circle with the distance from the center as the unit's relative strength, then trying to bend that into a triangle. Or perhaps there are many valid overlapping triangles with points in the general shape of a circle.

There are hundreds of triangles available, yes.  All I am looking for is one of them, and not all of the points even reside at the same distance from the center of the "circle."  Although the points should form more of a "doughnut" (assuming unit strength could be calculated, as there is not an objective place to stand in order to measure).

Quote
Either need a new shape to describe this, or different definitions for the original shape. I guess it doesn't matter much, as long as you're ignoring this triangle concept, but it would make it easier for me, and hopefully others, to understand what you're doing.

I call it a triangle because the results are three units that have a Rock Paper Scissors relationship and the resulting node-graph of "what beats what" resembles a triangle.
Logged

Nivim

  • Bay Watcher
  • Has the asylum forgotten? Are they still the same?
    • View Profile
Re: Proceedurally Generated RTS
« Reply #156 on: January 31, 2011, 08:20:06 pm »

If you're looking for a triangle, how can you find it if you haven't defined what the points are?
Imagine a Cartesian grid that is 30 units wide and 30 units tall.  How many triangles are there?  Do all of them have the same orientation?  Are all of them the same size?  Are all of them equilateral?
The shape shouldn't have anything to do with the cartesian co-ordinate system. If it did, we would need to define what the units were, and what the axis were, which should define what the points are, but then we'd need to define what the lines are again, and worse, what the distance of the lines are. Unless that's the point you were trying to make...?

Correct.  The win/loss ratios would form the edges.  However, I'm not looking for min-maxed units, simply a minimum win/loss ratio (a unit should win and still retain a certain % of the group's total health--eg. 10 units vs. 10 units should have 3 units left at full health, or 6 at half, etc. (or better) to conform to a 30% health threshold).

Quote
But looking at how your searching for these ~points and how you describe such a triangle as irregular, it seems more like you're creating a circle with the distance from the center as the unit's relative strength, then trying to bend that into a triangle. Or perhaps there are many valid overlapping triangles with points in the general shape of a circle.
There are hundreds of triangles available, yes.  All I am looking for is one of them, and not all of the points even reside at the same distance from the center of the "circle."  Although the points should form more of a "doughnut" (assuming unit strength could be calculated, as there is not an objective place to stand in order to measure).
Doesn't looking for a single triangle out of a multitude by minimum(?) win/loss ratio preclude procedural unit generation? It's not as though in a balanced triangle any of the other units would fall on the sides of that triangle, since those sides are only win/loss ratios, and those wins and losses do not record how much of a win or loss (since you bring up hit-points).
How are you combining the reaction between points simile with the distance from center simile? If we wished to define an absolute strength for each unit we would need to calculate the shape/distortion of the donut, which could be possible by imaginative use of differentials, which does bring us back to the Cartesian co-ordinate system, but what are our units and axis?

Quote
Either need a new shape to describe this, or different definitions for the original shape. I guess it doesn't matter much, as long as you're ignoring this triangle concept, but it would make it easier for me, and hopefully others, to understand what you're doing.
I call it a triangle because the results are three units that have a Rock Paper Scissors relationship and the resulting node-graph of "what beats what" resembles a triangle.
And for Scissors Glue Rock Paper? Or any possible balanced relations that aren't just a triangle? If we have a multitude of possible triangles, then we have a multitude of possible points (units), which means we also have a multitude of other shapes as well.
Logged
Imagine a cool peice of sky-blue and milk-white marble about 3cm by 2cm and by 0.5cm, containing a tiny 2mm malacolite crystal. Now imagine the miles of metamorphic rock it's embedded in that no pick or chisel will ever touch. Then, imagine that those miles will melt back into their mantle long before any telescope even refracts an image of their planet. The watchers will be so excited to have that image too.

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #157 on: January 31, 2011, 08:44:07 pm »

If you're looking for a triangle, how can you find it if you haven't defined what the points are?
Imagine a Cartesian grid that is 30 units wide and 30 units tall.  How many triangles are there?  Do all of them have the same orientation?  Are all of them the same size?  Are all of them equilateral?
The shape shouldn't have anything to do with the cartesian co-ordinate system. If it did, we would need to define what the units were, and what the axis were, which should define what the points are, but then we'd need to define what the lines are again, and worse, what the distance of the lines are. Unless that's the point you were trying to make...?

That is the point I'm trying to make.  Only its an 8 axis grid (8 stats don't cha know).

Quote
Correct.  The win/loss ratios would form the edges.  However, I'm not looking for min-maxed units, simply a minimum win/loss ratio (a unit should win and still retain a certain % of the group's total health--eg. 10 units vs. 10 units should have 3 units left at full health, or 6 at half, etc. (or better) to conform to a 30% health threshold).

Quote
But looking at how your searching for these ~points and how you describe such a triangle as irregular, it seems more like you're creating a circle with the distance from the center as the unit's relative strength, then trying to bend that into a triangle. Or perhaps there are many valid overlapping triangles with points in the general shape of a circle.
There are hundreds of triangles available, yes.  All I am looking for is one of them, and not all of the points even reside at the same distance from the center of the "circle."  Although the points should form more of a "doughnut" (assuming unit strength could be calculated, as there is not an objective place to stand in order to measure).
Doesn't looking for a single triangle out of a multitude by minimum(?) win/loss ratio preclude procedural unit generation? It's not as though in a balanced triangle any of the other units would fall on the sides of that triangle, since those sides are only win/loss ratios, and those wins and losses do not record how much of a win or loss (since you bring up hit-points).
How are you combining the reaction between points simile with the distance from center simile? If we wished to define an absolute strength for each unit we would need to calculate the shape/distortion of the donut, which could be possible by imaginative use of differentials, which does bring us back to the Cartesian co-ordinate system, but what are our units and axis?

Hence why I don't understand what you're trying to ask (in your original question).  And why would minimum win/loss preclude procedural generation?  Each triangle is different from the last, validating the idea.

Quote
Quote
Either need a new shape to describe this, or different definitions for the original shape. I guess it doesn't matter much, as long as you're ignoring this triangle concept, but it would make it easier for me, and hopefully others, to understand what you're doing.
I call it a triangle because the results are three units that have a Rock Paper Scissors relationship and the resulting node-graph of "what beats what" resembles a triangle.
And for Scissors Glue Rock Paper? Or any possible balanced relations that aren't just a triangle? If we have a multitude of possible triangles, then we have a multitude of possible points (units), which means we also have a multitude of other shapes as well.

True, but with a base triangle, you can add more units and just fit them in where ever they fit.  The whole point is that the game should start with a balanced selection of units: that is, anything the AI throws at the player, they should have a unit they can use to counter.
Logged

qwertyuiopas

  • Bay Watcher
  • Photoshop is for elves who cannot use MSPaint.
    • View Profile
    • uristqwerty.ca, my current (barren) site.
Re: Proceedurally Generated RTS
« Reply #158 on: January 31, 2011, 10:22:55 pm »

I'm noticing that units with a high rate of fire tend to be more powerful in larger groups, so end up beating both of the others at the end.
Logged
Eh?
Eh!

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #159 on: January 31, 2011, 10:39:53 pm »

I'm noticing that units with a high rate of fire tend to be more powerful in larger groups, so end up beating both of the others at the end.

What's the base damage and number of shots?
Logged

Akhier the Dragon hearted

  • Bay Watcher
  • I'm a Dragon, Roar
    • View Profile
    • My YouTube Channel
Re: Proceedurally Generated RTS
« Reply #160 on: February 01, 2011, 03:27:33 am »

I think I may have just found one of the things causing a problem. I think you are ending up with ships that are to similar sometimes. #1 and #2 of my test below are almost exactly the same ship and where basically break even till the last 3 fights when #2 swept the field. The fights where more of a who lost a ship first kind of match and they both kicked #3 to the curb.
Code: [Select]
#1
HP500 Armor7 Dmg24x8 AP2 RoF12 Speed11 Range57

#2
HP525 Armor7 Dmg24x5 AP2 RoF7 Speed11 Range59

#3
HP500 Armor5 Dmg24x5 AP2 RoF8 Speed12 Range63


1 v 2   1 v 3   2 v 3
3   7   10  0   10  0
Also as an idea you should have a way to dump the numbers into a block of text that could be copied and pasted or something so that it is easier to save data from tests and maybe you could make a personal version that dumps the 3 into a text document and then restarts so you could just leave it run over night or something and examine the results the next day to look for patterns.
Logged
Quote
Join us. The crazy is at a perfect temperature today.
So it seems I accidentally put my canteen in my wheelbarrow and didn't notice... and then I got really thirsty... so right before going to sleep I go to take a swig from my canteen and... end up snorting a line of low-grade meth.

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #161 on: February 01, 2011, 09:26:45 am »

Yes, near-identical happens sometimes.  Any thoughts on how to avoid it would be appreciated.
Logged

Virex

  • Bay Watcher
  • Subjects interest attracted. Annalyses pending...
    • View Profile
Re: Proceedurally Generated RTS
« Reply #162 on: February 01, 2011, 12:46:15 pm »

If you describe your units as a point in n-dimensional space, where n is the amount of different stats (7 in this case), It's pretty easy to define a distance vector (HP1-HP2, Armor1-Armor2 etc) and obtain that vector's length. Then in your initial pool of 7, discard anything that is too close to another unit and take the next one from the full pool before running the triangle finder.
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #163 on: February 01, 2011, 12:51:25 pm »

On problem:

Then in your initial pool of 7, discard anything that is too close to another unit and take the next one from the full pool before running the triangle finder.

I can't discard units from the pool because the next unit doesn't beat the first.

Eg.

array of units:
unit1
unit2
unit3
unit4
unit5
unit6
unit7

unit4 is "too close" to unit 3 and discarded.
unit1
unit2
unit3
----
unit5
unit6
unit7

Now unit 5 has to "beat" unit 3, and if it doesn't....the entire structure collapses.  The whole point of saving them is for nothing.
Logged

Akhier the Dragon hearted

  • Bay Watcher
  • I'm a Dragon, Roar
    • View Profile
    • My YouTube Channel
Re: Proceedurally Generated RTS
« Reply #164 on: February 01, 2011, 02:53:55 pm »

   I do not have a way to separate them but I do notice
something. HP and Armor; Dmg, AP, and RoF; and Speed
and Range are 3 categories of stats so would probably be
a good place to start. HP and Armor are what keep the
ships alive. Damage, AP, and RoF are used to damage the
opponent. Speed and Range are what is used to get to
and away from a fight.
   The biggest problem with trying to separate out similar
ships is how to identify whats too similar. Damage is
probably the easiest seeing as you can just get it down
to damage per a second or whatever. Health and armor
are next up in difficulty in that you would have to decide
how important they are compared to each other so you
can weight them right. The hardest will be Speed and
Range because of them being the biggest thing out there.
After all what good is doing thousands of DPS if you have
a range of 0 or the other ship can always run away?
   If you still use a point buy system you could have
instead of one big pool the points get spread out into 3
pools, one for each of the categories I outlined. If each
ship received say 6 points you have the possibility of three
pools of 2; a pool of 3, 2, and 1; or a pool of 4 and two
pools of 1 which each would have 3 different configurations
in a ship. You would have to have a minimum chassis to put
this on though so each ship always ends up with a little bit
of speed, range, health, or any of those other necessities.
Logged
Quote
Join us. The crazy is at a perfect temperature today.
So it seems I accidentally put my canteen in my wheelbarrow and didn't notice... and then I got really thirsty... so right before going to sleep I go to take a swig from my canteen and... end up snorting a line of low-grade meth.
Pages: 1 ... 9 10 [11] 12 13 ... 31