.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

The Star & the Crescent- Save $9.00
winSPWW2- Save $6.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening > Scenarios, Maps and Mods

Reply
 
Thread Tools Display Modes
  #1  
Old August 20th, 2007, 12:05 PM
DrPraetorious's Avatar

DrPraetorious DrPraetorious is offline
Major General
 
Join Date: Feb 2005
Location: Lake of Hali, Aldebaran, OH
Posts: 2,474
Thanks: 51
Thanked 67 Times in 27 Posts
DrPraetorious is on a distinguished road
Default Fair start sites on flat maps

I have a very nice fair site finder script that I posted - it works great on *wraparound* maps.

It works okay on flat maps except that it doesn't know about corners.

The only way to arrange fair start sites on flat map is to put them equally spaced in a ring around the middle. Unfortunately, I'm not sure how you'd do this on an arbitrary graph.

So how's about this for an approximate algorithm:
* Find the shortest route between every province pair.
* Find four provinces which are the "center" of this map: these four provinces will have the lowest sum-distance-to-all-provinces, and will not be within 3 provinces of one another. The remoteness of a potential start location is going to be the sum of the distance of that start to the four centers.
* Potential start locations must be in in the second quintile of remoteness. That is to say: a start location must be less remote than at least 20% of all provinces, and a start location must be more remote than at least 60% of all provinces.
* In addition, the start locations can be as far apart and have as many (non-waste, non-deep-sea, non-swamp) neighbors as you specify.
* Enable as many such start locations as you can using the same algorithm I had before.


This is fairly complicated and I need to go to my own posting and get a copy of my script which I did not otherwise backup for some time (I have some proof of concept stuff on the machines at work but I lost quite a bit when I dropped my frickin' HD on the floor).

Thoughts? Suggestions? Comments?
__________________
If you read his speech at Rice, all his arguments for going to the moon work equally well as arguments for blowing up the moon, sending cloned dinosaurs into space, or constructing a towering *****-shaped obelisk on Mars. --Randall Munroe
Reply With Quote
  #2  
Old August 21st, 2007, 11:56 AM
paradoxharbinger's Avatar

paradoxharbinger paradoxharbinger is offline
Sergeant
 
Join Date: May 2004
Posts: 338
Thanks: 0
Thanked 0 Times in 0 Posts
paradoxharbinger is on a distinguished road
Default Re: Fair start sites on flat maps

you're right about that sounding fairly complex, but it sounds good. i think the only place you might run into problems with is if you cant find a suitable number of start sites, you'll start need to relaxing your restrictions. probably wont run into problems with higher province count maps, but on smaller ones, it could be an issue.

also, not sure about the corners thing, but a possible work around might be that the province numbers are related to position of a province in it's image. might help, might not just throwing it out there.
__________________
ParadoxHarbinger's MapGen New Site!

Get The MapGen Alpha

Get The Dom3 Unit Maker

I'm shoulder high in crap, and my water-wings are flat!
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 09:21 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.