Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 16 17 [18] 19 20 ... 31

Author Topic: Proceedurally Generated RTS  (Read 57110 times)

Akhier the Dragon hearted

  • Bay Watcher
  • I'm a Dragon, Roar
    • View Profile
    • My YouTube Channel
Re: Proceedurally Generated RTS
« Reply #255 on: March 06, 2011, 11:25:28 am »

   Its probably because I misspoke, I did not mean hyperCUBE, I meant hyperrectangle.
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.

RedWarrior0

  • Bay Watcher
  • she/her
    • View Profile
Re: Proceedurally Generated RTS
« Reply #256 on: March 06, 2011, 11:40:33 am »

Actually, that hyperdimensional prism is just one facet of the game, which, when put together, takes the three dimensional form of mice.
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #257 on: March 06, 2011, 11:55:55 am »

   Its probably because I misspoke, I did not mean hyperCUBE, I meant hyperrectangle.

Still doesn't make a whole lot of sense.

But then, I've primarily been visualizing 3D space with a 4D perspective.  4D shapes aren't as easy.
Logged

Armok

  • Bay Watcher
  • God of Blood
    • View Profile
Re: Proceedurally Generated RTS
« Reply #258 on: March 06, 2011, 07:58:33 pm »

what you should do is just find a way for the game to measure the complexity of the interrelationships, and then maximize that.
Logged
So says Armok, God of blood.
Sszsszssoo...
Sszsszssaaayysss...
III...

RedWarrior0

  • Bay Watcher
  • she/her
    • View Profile
Re: Proceedurally Generated RTS
« Reply #259 on: March 06, 2011, 10:13:47 pm »

what you should do is just find a way for the game to measure the complexity of the interrelationships, and then maximize that.
Procedurally generated Turing-complete systems?
Logged

Armok

  • Bay Watcher
  • God of Blood
    • View Profile
Re: Proceedurally Generated RTS
« Reply #260 on: March 07, 2011, 02:37:50 pm »

see, now *that'd* be a great accomplishment of game design.
Logged
So says Armok, God of blood.
Sszsszssoo...
Sszsszssaaayysss...
III...

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #261 on: March 11, 2011, 01:00:57 am »

Playing around with scaling up my procedural graphics.  It takes about 170 ms to generate the original and scale it up, haven't optimized it yet, as it's still fairly brute-force.
Visuals are at 5x size.  Original ship on the left, "scaled up" version on the right.  There are still a few errors floating around (such as unconnected black pixels not being represented in the up-scaled version).

http://www.pages.drexel.edu/~mmj29/temp/pixelships_colors_v2c.swf

Some explanation of the algorithm.  Also feel free to try and solve the issue at hand in that thread.
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #262 on: March 12, 2011, 12:26:30 am »

And a final version.
Split the scale-up code into a function that can take input to allow for "as many scalings as I want" (although doubling the size 25 times longer--its not a very efficient algorithm; what is that, O(n4)?).
Uploaded swf generates the smallest and one larger version before a delay and drawing an even larger version (as it takes over 2 seconds to create).
Cockpit windows on the super-large version are ad-hoc'd right now (strait scale-up with no interpolation) as the algorithm can end up reducing the size of the windows too much.  I probably won't be using these super-large sprites, it was just an exercise to see if I could make them.
Logged

Nivim

  • Bay Watcher
  • Has the asylum forgotten? Are they still the same?
    • View Profile
Re: Proceedurally Generated RTS
« Reply #263 on: March 12, 2011, 02:27:46 pm »

 Ah, so that's what you've been doing. I do agree that your method is better, for the same reason you think so, but this version is still generating gray areas and random pixels sometimes.
Spoiler (click to show/hide)
I'm still not sure enough about the pattern to offer suggestions.
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 #264 on: March 12, 2011, 02:49:28 pm »

That's interesting.  It looks like something failed somewhere...couldn't tell you where though, as the far left ship (the original) isn't colored either.
Very odd.
I think I'll start printing the seed values to the screen too, so I can try and repo from screenshots.

The far right one failed because the middle one failed, the middle one is missing a few sections in the nose (3 pixels in the original).
« Last Edit: March 12, 2011, 02:51:22 pm by Draco18s »
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #265 on: March 23, 2011, 01:37:29 pm »

Been tinkering with things, like the ship generation algorithm.  Armor Piercing wasn't being selected for often enough, so those ships got a damage boost.  High-damage ships likewise got a num-shot penalty (54 x8 damage, regardless of reload speed, is way way powerful) as well as reigning in the upper bounds of the num-shot calculation (it was, for some reason, trying to create a 1-16 range, rather than a 1-8 which I pulled down to 1-6).

Anyway, I've started focusing on this as a game trying to build up the other mechanics.  I'm favoring outer space as the backdrop, as it removed pathing concerns.  Units can simply travel in a strait line to any location, avoiding the need for A*, etc.

Questions:
  • Battlefield type:
    • Option 1: Single scrolling area (similar to other flash space RTSs or Homeworld)
    • Option 2: Multiple locations (similar to AI War or Space Empires--would require simple pathing from one location to another)
    • Option 3: Somewhere in the middle where the world map and the combat map are separate (similar to Age of Wonders, Civilization, or Space Empire's combat maps) This is dumb, as it is not relevant for a real time strategy game.
  • Resources:
    • Number?  (i.e. AI War has 2 and a half.*  Age of Empires has 4: Stone, Wood, Metal, Gold.  Homeworld has 1:minerals.)
    • Use?  (i.e. what differentiates one resource from another?)
    • Collection method?  (how are they acquired?)
  • How is research going to be handled?
    • At the moment, I'm in favor of leaving the "max points" variable alone, making all units "tier 1."
  • Unit cap?
*Power is unit upkeep, costing metal and crystal, thus not being a resource in its own right as it is just a drain on the income of the other two.
Logged

Mephansteras

  • Bay Watcher
  • Forger of Civilizations
    • View Profile
Re: Proceedurally Generated RTS
« Reply #266 on: March 23, 2011, 01:51:10 pm »

On the resources question, I think you have to answer a few questions.

1) Weapons. Energy weapons will require power to function. Mass drivers may require power and certainly take resources depending on the type (chemical, gauss, rail, etc). Missiles should just require resources.

2) Power source for ships? Are we using an assumed infinite power source? Or are ships going to require some sort of fuel? Power consumption for flight may also impact power available for weapons or defenses.

In general, though, I think you can make do with 2-4 resource categories. This can be broken down more if you want to get detailed about it or left as large categories and abstract out the details.

1) Basic metals: Alloys and whatnot, but generally made of steel, aluminum, or silica. Mining from asteroids should make this easy, although you'll a lot of it.
2) Rare Earth Metals: Special materials needed for components and alloys. Asteroid mining works here, too, although they should be a lot rarer.
3) Fuel source: Depends on your fuel source. Could be Uranium if you want nuclear power, could be some exotic material or antimatter. Optional, since it could be lumped in with #2
4) General Supplies: Basic resources for running a ship. Food, oxygen, spare parts, etc. Optional, but could allow for interesting variability with regards to automation. A more automated ship requires fewer supplies and space devoted to said supplies but is probably less efficient.

Asteroid or moon mining probably accounts for most stuff. Less power consumption to break away from the gravitational pull of the source and plenty of resources out there. Might need space stations or colonies to supply personnel and general goods if you go that route.
Logged
Civilization Forge Mod v2.80: Adding in new races, equipment, animals, plants, metals, etc. Now with Alchemy and Libraries! Variety to spice up DF! (For DF 0.34.10)
Come play Mafia with us!
"Let us maintain our chill composure." - Toady One

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #267 on: March 23, 2011, 02:31:36 pm »

Personally I'd prefer an "infinite power source" mechanic in general.

Ostensibly, "power" is the unit-cap mechanic.  If its static then it's simply "you can run N ships."  If it isn't, then it's "you can build N ships per Y structures."
Because it's a flash game, the unit cap is going to be fairly low.  Under 1000 units for both the player and the AI(s) combined, just due to processing power available to Flash.

If it's "fuel based," then you have to worry about each ship returning to base every [interval] or [bad stuff] happens, and while Space Empires uses that kind of mechanic (as well as some Civ/Civ-like games) I don't favor it much.  It gets really annoying and doesn't work in an RTS environment well at all.

As for "basic" materials and "rare earth" materials, what's the ratio we're looking at here?  Roughly speaking every ship built would need to compose the same ratio of materials available or you start causing a back-log of build orders (AI War is notorious in this, in that "crystal" is the "rare earth metals" in our equation, are treated as a 1:1 ratio in terms of cost and availability, but more than half of the units cost HUGE amounts of crystal--or at least more C than M--thus creating an income disparity).

I'm also not going to worry about gravity wells.
Logged

Korbac

  • Bay Watcher
  • I'm very annoying, so tell me to STFU if need be
    • View Profile
Re: Proceedurally Generated RTS
« Reply #268 on: March 23, 2011, 02:53:58 pm »

"Basic" vs "Rare" could vary depending on special abilities. Perhaps you could have Resource 1 based out of firing rate and damage, Resource 2 based out of armour and hp, and Resource 3 based out of speed and range?
Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: Proceedurally Generated RTS
« Reply #269 on: March 23, 2011, 02:59:41 pm »

That's a thought.
Logged
Pages: 1 ... 16 17 [18] 19 20 ... 31