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

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening

Reply
 
Thread Tools Display Modes
  #11  
Old April 20th, 2008, 10:23 PM

Loren Loren is offline
First Lieutenant
 
Join Date: Nov 2006
Posts: 739
Thanks: 1
Thanked 8 Times in 8 Posts
Loren is on a distinguished road
Default Re: Does My Site Search Mage Know Something I Don\'

Quote:
vfb said:
Well, here's a really simple algorithm that would be better than the current one IMO.

Maintain a CurrentSearch list of sites being searched in current month.

Code:

* Loop through owned sites to find next province to search:
- Capitol? Discard.
- 4 sites known? Discard.
- In CurrentSearch? Discard.
- Rank =
100 * (4 - (current search path level searched in province)
+ 10 * (4 - (# of known sites))
+ (total of other paths already searched in province)
- Rank < CurrentRank? Discard.
- CurrentRank = Rank, add to CurrentSearch list



Needs some modification to handle Tiamat, but so does the current search.
I don't see the reason for the number of other paths searched term. I think the number of sites found is the important term.

I do agree that your algorithm is considerably superior to the current one and it's certainly easy to do.

As for the multi-site spells I think they can be reasonably approximated by treating it as the sum of the ratings of casting all the components. Since the ranking is a unitless value it doesn't matter that Tiamat scores 4x as high as the single-path spells.
Reply With Quote
  #12  
Old April 20th, 2008, 11:09 PM

VedalkenBear VedalkenBear is offline
Second Lieutenant
 
Join Date: May 2006
Posts: 465
Thanks: 10
Thanked 16 Times in 14 Posts
VedalkenBear is on a distinguished road
Default Re: Does My Site Search Mage Know Something I Don\'

Certainly you can simulate it. I prefer a more theoretical approach.

If all of your provinces are unsearched, and you can cast Haruspex, where do you cast it? Probably on a Forest province, since it has a higher (I believe 0.25 higher) probability of containing a nature site. Which one doesn't matter.

This also ignores the different utility of different sites. E.g., searching underwater provinces with Haruspex, while not as guaranteed to find a site, has a not insignificant chance of discovering a fortress (Kelp Fortress). As such, would you preferentially search underwater sites with Haruspex, or not?

There are many variables, but since this is an allocation problem, it should be susceptible to LP in some form.
Reply With Quote
  #13  
Old April 21st, 2008, 03:28 AM
vfb's Avatar

vfb vfb is offline
General
 
Join Date: Mar 2007
Location: Japan
Posts: 3,691
Thanks: 269
Thanked 397 Times in 200 Posts
vfb is on a distinguished road
Default Re: Does My Site Search Mage Know Something I Don\'

Quote:
Loren said:
Quote:
vfb said:
Well, here's a really simple algorithm that would be better than the current one IMO.

Maintain a CurrentSearch list of sites being searched in current month.

Code:

* Loop through owned sites to find next province to search:
- Capitol? Discard.
- 4 sites known? Discard.
- In CurrentSearch? Discard.
- Rank =
100 * (4 - (current search path level searched in province)
+ 10 * (4 - (# of known sites))
+ (total of other paths already searched in province)
- Rank < CurrentRank? Discard.
- CurrentRank = Rank, add to CurrentSearch list



Needs some modification to handle Tiamat, but so does the current search.
I don't see the reason for the number of other paths searched term. I think the number of sites found is the important term.

...
When all provinces to be searched have the same number of found sites, and have been searched at the same level in the path being searched, then you want to search the provinces that have been 'cleared' of other paths first. The provinces that have not been 'cleared' are more likely to contain sites of those other paths.

The algorithm sorts first by unsearched provinces by the path being searched. Only if two or more provinces are equal in that respect does it consider the number of known sites. And only if that count is equal does it consider the searched paths total.

It's possible it should weight (a province with zero found sites that has been searched at W1) higher than (a province with three found sites that has not been W searched.)

It doesn't do that, but I wanted to come up with something quick and practical to implement. I'm not interested in theory so much.
__________________
Whether he submitted the post, or whether he did not, made no difference. The Thought Police would get him just the same. He had committed— would still have committed, even if he had never set pen to paper— the essential crime that contained all others in itself. Thoughtcrime, they called it. Thoughtcrime was not a thing that could be concealed forever.
http://z7.invisionfree.com/Dom3mods/index.php?
Reply With Quote
  #14  
Old April 21st, 2008, 02:09 PM

Loren Loren is offline
First Lieutenant
 
Join Date: Nov 2006
Posts: 739
Thanks: 1
Thanked 8 Times in 8 Posts
Loren is on a distinguished road
Default Re: Does My Site Search Mage Know Something I Don\'

Quote:
vfb said:
Quote:
Loren said:
Quote:
vfb said:
Well, here's a really simple algorithm that would be better than the current one IMO.

Maintain a CurrentSearch list of sites being searched in current month.

Code:

* Loop through owned sites to find next province to search:
- Capitol? Discard.
- 4 sites known? Discard.
- In CurrentSearch? Discard.
- Rank =
100 * (4 - (current search path level searched in province)
+ 10 * (4 - (# of known sites))
+ (total of other paths already searched in province)
- Rank < CurrentRank? Discard.
- CurrentRank = Rank, add to CurrentSearch list



Needs some modification to handle Tiamat, but so does the current search.
I don't see the reason for the number of other paths searched term. I think the number of sites found is the important term.

...
When all provinces to be searched have the same number of found sites, and have been searched at the same level in the path being searched, then you want to search the provinces that have been 'cleared' of other paths first. The provinces that have not been 'cleared' are more likely to contain sites of those other paths.

The algorithm sorts first by unsearched provinces by the path being searched. Only if two or more provinces are equal in that respect does it consider the number of known sites. And only if that count is equal does it consider the searched paths total.

It's possible it should weight (a province with zero found sites that has been searched at W1) higher than (a province with three found sites that has not been W searched.)

It doesn't do that, but I wanted to come up with something quick and practical to implement. I'm not interested in theory so much.
Oh, I see what you're up to. Agreed.
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 11:16 AM.


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