Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

RE: Supply Revisions

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> World in Flames >> RE: Supply Revisions Page: <<   < prev  1 [2] 3   next >   >>
Login
Message << Older Topic   Newer Topic >>
RE: Supply Revisions - 5/28/2010 12:42:25 AM   
Incy

 

Posts: 336
Joined: 10/25/2003
Status: offline
Yes. I pop a japanese CP into the med at first opportunity as a standard practice. Makes life for Italy a lot easier.

(in reply to Shannon V. OKeets)
Post #: 31
RE: Supply Revisions - 5/28/2010 1:49:32 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline

quote:

ORIGINAL: Incy

Yes. I pop a japanese CP into the med at first opportunity as a standard practice. Makes life for Italy a lot easier.

Yes, but that supply can be blocked by the CW with a combat unit (air or sea) if the CW is at war with Italy.

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Incy)
Post #: 32
RE: Supply Revisions - 5/28/2010 3:54:22 AM   
paulderynck


Posts: 8201
Joined: 3/24/2007
From: Canada
Status: offline

quote:

ORIGINAL: Incy

Yes. I pop a japanese CP into the med at first opportunity as a standard practice. Makes life for Italy a lot easier.

It used to. The FAQ answers make it real simple for the Wallies to cut.

_____________________________

Paul

(in reply to Incy)
Post #: 33
RE: Supply Revisions - 5/28/2010 11:54:29 PM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===





Attachment (1)

_____________________________

Steve

Perfection is an elusive goal.

(in reply to paulderynck)
Post #: 34
RE: Supply Revisions - 5/29/2010 11:05:33 AM   
Froonp


Posts: 7995
Joined: 10/21/2003
From: Marseilles, France
Status: offline

quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

(in reply to Shannon V. OKeets)
Post #: 35
RE: Supply Revisions - 5/29/2010 10:18:48 PM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline

quote:

ORIGINAL: Froonp


quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

I haven't gotten to supply for individual units yet, so the counter being shown is simply the one I clicked on to bring up the Supply Status screen (I never change it).

I'll rewite the code to show the HQ for now - assuming the player has clicked on one of the HQs in the supply sources list on the left. Eventually, I'll let the player click on individual units, which will displayed at the bottom of the form (I've cut it off for these screen shots).

I guess I'll just leave the unit image blank if the player clicks on a suply source that is a city.

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Froonp)
Post #: 36
RE: Supply Revisions - 5/29/2010 11:04:49 PM   
Anendrue


Posts: 817
Joined: 7/8/2005
Status: offline

quote:

ORIGINAL: Shannon V. OKeets


quote:

ORIGINAL: Froonp


quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

I haven't gotten to supply for individual units yet, so the counter being shown is simply the one I clicked on to bring up the Supply Status screen (I never change it).

I'll rewite the code to show the HQ for now - assuming the player has clicked on one of the HQs in the supply sources list on the left. Eventually, I'll let the player click on individual units, which will displayed at the bottom of the form (I've cut it off for these screen shots).

I guess I'll just leave the unit image blank if the player clicks on a suply source that is a city.

Or provide an image of a hex with a city icon? Perhaps the city name could be added to that display.

_____________________________

Integrity is what you do when nobody is watching.

(in reply to Shannon V. OKeets)
Post #: 37
RE: Supply Revisions - 5/29/2010 11:22:51 PM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline

quote:

ORIGINAL: abj9562


quote:

ORIGINAL: Shannon V. OKeets


quote:

ORIGINAL: Froonp


quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

I haven't gotten to supply for individual units yet, so the counter being shown is simply the one I clicked on to bring up the Supply Status screen (I never change it).

I'll rewite the code to show the HQ for now - assuming the player has clicked on one of the HQs in the supply sources list on the left. Eventually, I'll let the player click on individual units, which will displayed at the bottom of the form (I've cut it off for these screen shots).

I guess I'll just leave the unit image blank if the player clicks on a suply source that is a city.

Or provide an image of a hex with a city icon? Perhaps the city name could be added to that display.

The insert map already does that.

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Anendrue)
Post #: 38
RE: Supply Revisions - 5/30/2010 12:00:43 AM   
Anendrue


Posts: 817
Joined: 7/8/2005
Status: offline

quote:

ORIGINAL: Shannon V. OKeets


quote:

ORIGINAL: abj9562


quote:

ORIGINAL: Shannon V. OKeets


quote:

ORIGINAL: Froonp


quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

I haven't gotten to supply for individual units yet, so the counter being shown is simply the one I clicked on to bring up the Supply Status screen (I never change it).

I'll rewite the code to show the HQ for now - assuming the player has clicked on one of the HQs in the supply sources list on the left. Eventually, I'll let the player click on individual units, which will displayed at the bottom of the form (I've cut it off for these screen shots).

I guess I'll just leave the unit image blank if the player clicks on a suply source that is a city.

Or provide an image of a hex with a city icon? Perhaps the city name could be added to that display.

The insert map already does that.

Oh duh... face slap to self.

_____________________________

Integrity is what you do when nobody is watching.

(in reply to Shannon V. OKeets)
Post #: 39
RE: Supply Revisions - 5/30/2010 5:02:30 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
quote:

ORIGINAL: Froonp


quote:

ORIGINAL: Shannon V. OKeets

I finally got the code for overseas supply lines working for secondary supply sources. Here are two examples. Next up are tertiary supply lines (from 'secondary' supply sources that can not reach a primary supply source but can reach another secondary/tertiary supply source.
===

Why is there a falco displayed in both screenshots ?

Here are two screen shots of an improved version, showing the HQ unit if its path is being displayed. I fixed a bug in the search routine so it now finds a supply path for Umezu.

The colors are still for Italy since the Italian player is the current decision maker.



EDIT: I messed up cropping the top and bottom of the JPG file.

Attachment (1)

< Message edited by Shannon V. OKeets -- 5/30/2010 5:03:38 AM >


_____________________________

Steve

Perfection is an elusive goal.

(in reply to Froonp)
Post #: 40
RE: Supply Revisions - 5/30/2010 11:30:15 AM   
Froonp


Posts: 7995
Joined: 10/21/2003
From: Marseilles, France
Status: offline
quote:

ORIGINAL: Shannon V. OKeets
Here are two screen shots of an improved version, showing the HQ unit if its path is being displayed. I fixed a bug in the search routine so it now finds a supply path for Umezu.

On the right panel, the one labelled supply path, it would be good if the China hexes crossed by rail supply path indicated "Rail". Or the reverse, that the hexes crossed using Basic supply path indicated "Basic Supply Path", or "Basic" or "BSP".

(in reply to Shannon V. OKeets)
Post #: 41
RE: Supply Revisions - 5/30/2010 11:31:13 AM   
Froonp


Posts: 7995
Joined: 10/21/2003
From: Marseilles, France
Status: offline
It would also be good if on the inserted map (and why not on the main map too) the hexes listed in the Supply Path table were highlighted.

(in reply to Froonp)
Post #: 42
RE: Supply Revisions - 5/30/2010 5:27:51 PM   
lomyrin


Posts: 3741
Joined: 12/21/2005
From: San Diego
Status: offline
As Froonp stated in the above 2 posts I also would like to see what he proposes.

Lars

(in reply to Froonp)
Post #: 43
RE: Supply Revisions - 5/30/2010 6:52:20 PM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
quote:

ORIGINAL: Froonp

quote:

ORIGINAL: Shannon V. OKeets
Here are two screen shots of an improved version, showing the HQ unit if its path is being displayed. I fixed a bug in the search routine so it now finds a supply path for Umezu.

On the right panel, the one labelled supply path, it would be good if the China hexes crossed by rail supply path indicated "Rail". Or the reverse, that the hexes crossed using Basic supply path indicated "Basic Supply Path", or "Basic" or "BSP".

I agree. What I intend to do is count the basic path hexes in the rightmost column. That will start at zero (the beginning of the path) and only increment when a basic paht is 'consumed' to get to the next hex. For example, the overseas portion will be all zeroes but the port where the overseas link terminates would always increase the Basic Path Hex count by 1.

When I get to units using a secondary and tertiary soucre(s) then the Basic Path Hex count will reinitialize at each secondary/tertiary source.

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Froonp)
Post #: 44
RE: Supply Revisions - 5/30/2010 7:02:05 PM   
Froonp


Posts: 7995
Joined: 10/21/2003
From: Marseilles, France
Status: offline
quote:

ORIGINAL: Shannon V. OKeets

quote:

ORIGINAL: Froonp

quote:

ORIGINAL: Shannon V. OKeets
Here are two screen shots of an improved version, showing the HQ unit if its path is being displayed. I fixed a bug in the search routine so it now finds a supply path for Umezu.

On the right panel, the one labelled supply path, it would be good if the China hexes crossed by rail supply path indicated "Rail". Or the reverse, that the hexes crossed using Basic supply path indicated "Basic Supply Path", or "Basic" or "BSP".

I agree. What I intend to do is count the basic path hexes in the rightmost column. That will start at zero (the beginning of the path) and only increment when a basic paht is 'consumed' to get to the next hex. For example, the overseas portion will be all zeroes but the port where the overseas link terminates would always increase the Basic Path Hex count by 1.

When I get to units using a secondary and tertiary soucre(s) then the Basic Path Hex count will reinitialize at each secondary/tertiary source.

It seems very good to me.

(in reply to Shannon V. OKeets)
Post #: 45
RE: Supply Revisions - 5/30/2010 7:03:24 PM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
quote:

ORIGINAL: Froonp

It would also be good if on the inserted map (and why not on the main map too) the hexes listed in the Supply Path table were highlighted.

No.

I do not want to add more graphics at this point. The clutter in each hex is only borderline acceptable to me as it stands. More is not better in this case. Players should be able to understand what the supply path is from the information given in this form. As an assist to that understanding, the insert map centers on the selected hex as you click on hexes in the supply path. So, when you click on one of the sea areas, the insert map centers on the zero section box of the sea area (for the side tracing supply).

EDIT: clarity.

< Message edited by Shannon V. OKeets -- 5/30/2010 7:04:20 PM >


_____________________________

Steve

Perfection is an elusive goal.

(in reply to Froonp)
Post #: 46
RE: Supply Revisions - 6/4/2010 12:21:52 AM   
Incy

 

Posts: 336
Joined: 10/25/2003
Status: offline
The utility depends on your favourite ruleset and strategy, of course.

It's of cource useless as the only supply for a serious combat effort. However, it has many uses.

We play with isolation, and it's not really that convenient for the wallies to maintain a unit in med zones at EOT if Italy doesn't want it there. Italy can fly air only and make life miserable for the poor CW units having to go out and replace 'the previous unit' every so many times a turn. They will not always manage/give it priority, and Italy can manouvre and reorg intermittently. A single japanese CP can be cheap compared to the extra burden for CW.

We happen to play without SIF and without pilots, which make both naval units and naval aircraft more rare.

Also, even with CW units, the CP can transport resources, for example if Syria is Vichy, or the Cyprus resource, or from a contested/partisaned greece/yogu, or if Bulgaria has fallen to Stalin (and the turkey res needs transporting overseas).

(in reply to paulderynck)
Post #: 47
RE: Supply Revisions - 6/4/2010 5:01:40 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
I am late with the monthly status report and that is because I decided I would get secondary supply working before I took time out to write up the month's activities. I have that working now, so I will try to get to the monthly status report tomorrow morning.
===
Here is one of the tst cases I was using for finding a rail path. Notice that the search algorithm uses rail hexes if available, but will take a direct route to to a primary supply source if the rail path is too far out of the way. I monitored this search's decision making from start to end and the route shown here consists of just the "first choice" hexes - there were no dead ends explored.




Attachment (1)

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Incy)
Post #: 48
RE: Supply Revisions - 6/4/2010 5:04:53 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
2nd in a series of 3. Here is one that I found interesting. The algorithm looks for rail paths without overseas supply first. It just has enough Basic Path hexes available to reach Dacca from Rangoon. Of course if the weather changes it will have to go by sea.




Attachment (1)

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Shannon V. OKeets)
Post #: 49
RE: Supply Revisions - 6/4/2010 5:12:01 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
3rd and last in the series.

The way the overseas supply routines work is that for each port controlled by the given major power or its allies, a path is attempted to be found to a primary supply source. The search goes through the ports from north to south, so a lot of the British units trace to Belfast! Once the ports have been identified, the sea areas that are adjacent to the port are tested for viability (not being interdicted by the enemy) and overseas supply is propagated to adjacent sea areas around the world. Finally, secondary supply sources that do not have overland railway supply paths to a primary suply source attempt to reach a port that is adjacent to one of the sea areas through which viable supply can be traced. The results of this are manifest in this screen shot.




Attachment (1)

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Shannon V. OKeets)
Post #: 50
RE: Supply Revisions - 6/4/2010 5:36:38 PM   
Zorachus99


Posts: 1066
Joined: 9/15/2000
From: Palo Alto, CA
Status: offline
I look forward to testing this revision. 

_____________________________

Most men can survive adversity, the true test of a man's character is power. -Abraham Lincoln

(in reply to Shannon V. OKeets)
Post #: 51
RE: Supply Revisions - 6/4/2010 9:19:29 PM   
Incy

 

Posts: 336
Joined: 10/25/2003
Status: offline
I'm curious about the effectiveness of not always calculating an optimum path. I think you might be better off exhausting all paths up to lenght 2 before trying lenght 3 paths, and then lenght 4 paths.

You'll have to (try to) calculate a lenght 2 path sooner or later anyways, as the weather changes. Especially for paths that don't change much this might become expensive.

Take a complex (i.e expensive) lenght 3 path.
-Every time weather changes to rain/storm/blizzard it must be exhaustively calculated, and will not find a path, so will end up OOS and no path will be stored.
-every time weather improves it must be recalculated, and will find a path
-possibly it will have to be recalculated when the weather changes from fine to snow again too

Especially the first search is a problem because it will be exhaustive, and it will be done repeatedly for many units/sources. You might well end up with a long calculation time whenever rolling the weather.

I predict that if you always make computations that 'guarantee' an optimal result, and if you store the path even if to long (under current weather), you will end up doing much, much less calculation. A greedy but optimal search is not on average much more expensive than a greedy non-optimal search. In such a scenario weather changes will only involve recalculations because hex supply caracteristics change, i.e frozen lake hexsides & frozen ports.

(in reply to Zorachus99)
Post #: 52
RE: Supply Revisions - 6/4/2010 9:23:00 PM   
Incy

 

Posts: 336
Joined: 10/25/2003
Status: offline
btw, a very effective optimisation could be to start by calculating 'connected rail segments', i.e. a lists of rail hexes that make up uniterrupted rail grids. With each 'connected rail segment' you should also store the distance the segment has to a supply souce.

If you do this in an initial search, all secondary->primary searches will become a matter of searching for the nearest hex in a 'connected rail segment'.  An exhaustive search would never exceed 4 hexes in lenght.

Example:
Initial search for euroaxis finds and stores 3 'connected rail segment':
-all rail hexes in central europe/west europe/Italy/Balkans (dist 0) (plus baltic, It coast and east med)
-all axis rail hexes in north africa (dist 1)
-a semi-isolated pocket around Stalingrad (dist 3)
All secondary supply sources (that need recalculation) test all rail hexes within distance 4 (starting with the closest first) to see if any hex is in a 'connected rail segment'. 
If one or more connected rail hexes are found, compare the distance to the closest one, add the 'connected rail segment' distance to primary supply, and there you have the lenght of your primary path

(in reply to Incy)
Post #: 53
RE: Supply Revisions - 6/5/2010 12:30:11 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline

quote:

ORIGINAL: Incy

I'm curious about the effectiveness of not always calculating an optimum path. I think you might be better off exhausting all paths up to lenght 2 before trying lenght 3 paths, and then lenght 4 paths.

You'll have to (try to) calculate a lenght 2 path sooner or later anyways, as the weather changes. Especially for paths that don't change much this might become expensive.

Take a complex (i.e expensive) lenght 3 path.
-Every time weather changes to rain/storm/blizzard it must be exhaustively calculated, and will not find a path, so will end up OOS and no path will be stored.
-every time weather improves it must be recalculated, and will find a path
-possibly it will have to be recalculated when the weather changes from fine to snow again too

Especially the first search is a problem because it will be exhaustive, and it will be done repeatedly for many units/sources. You might well end up with a long calculation time whenever rolling the weather.

I predict that if you always make computations that 'guarantee' an optimal result, and if you store the path even if to long (under current weather), you will end up doing much, much less calculation. A greedy but optimal search is not on average much more expensive than a greedy non-optimal search. In such a scenario weather changes will only involve recalculations because hex supply caracteristics change, i.e frozen lake hexsides & frozen ports.


The search algorithm is pretty optimal as it is. It is a directed search heading towards the closest supply source (which is sometimes a port that leads overseas).

Note that if a path with fewer Basic Hexes is available, it will be longer because it will use more rail hexes. Longer paths are more vulnerable to being cut by the enemy.

If a previous path fails (e.g., due to weather) then the program will search for a path with fewer available basic path hexes. Finding one, that will become the new 'previous' path. The next time the program needs to find supply for the the unit/secondary supply source, it will try to use the previous path. So, if a path with 2 Basic Path Hexes becomes required, that will become the new default.
==
I thought about recording rail networks, but there is a maintenance task associated with keeping them up-to-date (due to the presence/absence of enemy units). I'm pretty happy with just recording the segments that are in use and the units depending on them. Note that the only time rail paths are used is from secondary to primary sources, so they aren't used all that often for supply. For shipping resources, they get a lot more use, but that is only one per turn.

_____________________________

Steve

Perfection is an elusive goal.

(in reply to Incy)
Post #: 54
RE: Supply Revisions - 6/5/2010 2:14:53 AM   
paulderynck


Posts: 8201
Joined: 3/24/2007
From: Canada
Status: offline
deleted

< Message edited by paulderynck -- 6/5/2010 2:17:03 AM >


_____________________________

Paul

(in reply to Shannon V. OKeets)
Post #: 55
RE: Supply Revisions - 6/5/2010 2:16:47 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
quote:

ORIGINAL: paulderynck


quote:

ORIGINAL: Shannon V. OKeets

2nd in a series of 3. Here is one that I found interesting. The algorithm looks for rail paths without overseas supply first. It just has enough Basic Path hexes available to reach Dacca from Rangoon. Of course if the weather changes it will have to go by sea.




Why is the path showing 4 hexes in length. Shouldn't it be 3?

From Yenangyaung to the nearest rail hex in India is 4 Basic Path hexes. Going by rail to the hex NW of Mandalay doesn't help.

EDIT: You can't cross the alpine hexsides.

< Message edited by Shannon V. OKeets -- 6/5/2010 2:17:54 AM >


_____________________________

Steve

Perfection is an elusive goal.

(in reply to paulderynck)
Post #: 56
RE: Supply Revisions - 6/5/2010 2:18:19 AM   
paulderynck


Posts: 8201
Joined: 3/24/2007
From: Canada
Status: offline
Damn! you're quick! Didn't see the Alpine hexside.

Is there any way to deduce the hex numbers when viewing these pics?

_____________________________

Paul

(in reply to Shannon V. OKeets)
Post #: 57
RE: Supply Revisions - 6/6/2010 12:48:47 AM   
Incy

 

Posts: 336
Joined: 10/25/2003
Status: offline
quote:

If a previous path fails (e.g., due to weather) then the program will search for a path with fewer available basic path hexes. Finding one, that will become the new 'previous' path. The next time the program needs to find supply for the the unit/secondary supply source, it will try to use the previous path. So, if a path with 2 Basic Path Hexes becomes required, that will become the new default.


The problem is with paths where the optimal lenght is 3 or 4.
-when the weather turns bad you'll do an exhaustive search and fail, no path being recorded.
-when the weather turns good you'll do another search and succeed
This will repeat over and over again. Worse, where paths are longer than 4 you'll end up doing exhaustive searches every time anything at all is checked.

Units with paths longer than 4 (or with no path) can be very expensive. As the game proceeds potentially hundreds of units could be without a 4-lenght or better path. Given that they have no path, every such search should be expensive, too.

The problem is that whenever anything happens that can affect supply, all of those units will have to be retested. So in the late game you may end up testing potentially hundreds of paths everytime a zoc or a hex changes.

(in reply to Shannon V. OKeets)
Post #: 58
RE: Supply Revisions - 6/6/2010 1:53:54 AM   
Shannon V. OKeets

 

Posts: 22095
Joined: 5/19/2005
From: Honolulu, Hawaii
Status: offline
quote:

ORIGINAL: Incy

quote:

If a previous path fails (e.g., due to weather) then the program will search for a path with fewer available basic path hexes. Finding one, that will become the new 'previous' path. The next time the program needs to find supply for the the unit/secondary supply source, it will try to use the previous path. So, if a path with 2 Basic Path Hexes becomes required, that will become the new default.


The problem is with paths where the optimal lenght is 3 or 4.
-when the weather turns bad you'll do an exhaustive search and fail, no path being recorded.
-when the weather turns good you'll do another search and succeed
This will repeat over and over again. Worse, where paths are longer than 4 you'll end up doing exhaustive searches every time anything at all is checked.

Units with paths longer than 4 (or with no path) can be very expensive. As the game proceeds potentially hundreds of units could be without a 4-lenght or better path. Given that they have no path, every such search should be expensive, too.

The problem is that whenever anything happens that can affect supply, all of those units will have to be retested. So in the late game you may end up testing potentially hundreds of paths everytime a zoc or a hex changes.

It's not that bad.

Only the rail paths from secondary to primary are ever more than 4 hexes away, so those searches are fast. Most of the seconary to primary never change (i.e., the cities are immobile). For example, tracing from capitals captured by the Germans (or aligned to Germany) to a German city remains the same throughout the game for the most part.

I am keeping the last successful path for each unit, even if it has since failed. This means that if a unit has supply with a path of 4 and the weather changes to 2 and all paths fail (i.e., the unit is out of supply), I still have the last successful path, so if the weather gets nice again, the path should work again. Storing paths is easy and takes very little memory. Checking them is also very fast to do.

EDIT: Existing overseas paths are easy to validate too, with the caveat that some are rail paths. From testing the new supply determination code in detail, the worst case I have seen is Ethiopia when it is held by the Italians. That secondary supply source is virtually never able to trace back to a primary supply source, but it has to be checked continuously to see if a miracle has occurred.

< Message edited by Shannon V. OKeets -- 6/6/2010 1:58:59 AM >


_____________________________

Steve

Perfection is an elusive goal.

(in reply to Incy)
Post #: 59
RE: Supply Revisions - 6/6/2010 5:06:33 PM   
Froonp


Posts: 7995
Joined: 10/21/2003
From: Marseilles, France
Status: offline
Maybe it was said below, but an idea to save time in calculating supply, would be to have units stacked with another non hq unit from the same country to use the same supply path as that unit.

(in reply to Shannon V. OKeets)
Post #: 60
Page:   <<   < prev  1 [2] 3   next >   >>
All Forums >> [New Releases from Matrix Games] >> World in Flames >> RE: Supply Revisions Page: <<   < prev  1 [2] 3   next >   >>
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

1.141