bugGlobulation 2 - Bugs: bug #16242, improvement-idea for pathfinding...


bug #16242: improvement-idea for pathfinding concerning idle units

Submitter:  Leo Wandersleb <giszmo>
Submitted:  Sat 01 Apr 2006 12:00:23 PM UTC
Severity:  1 - Wish Status:  None
Assigned to:  None Open/Closed:  Open
Release:  None Operating System:  None
* Mandatory Fields

Add a New Comment Rich Markup

Sat 01 Apr 2006 10:50:17 PM UTC, comment #1: 

I'm not sure whether this is needed.

Since walking diagonal is as fast as horizontal or vertical,
I'd expect that idle globs would be eluded without increasing
the distance in most cases.
In the other cases the idle glob must be on an direct diagonal line
between the worker and a resource or an obstacle which it must pass.
(Well, and then, there are a few pathological cases which depend on
opening or closing of paths.)

If the movements of the idle glob (when inside a forbidden-area) would
be deterministic, we might get a funny situation.  The idle glob might
be pushed by the worker's forbidden-area in the same direction as the
worker is heading - all the way.  Might look funny, if we see globs
running around in pairs.
If the glob is pushed into a bottleneck it will block the path.

If idle globs have a bad effect on pathfinding, I would propose
another idea to deal with it.  It's not better than yours - in
fact, it is worse when it comes to warriors, but it leads to
meassure the usefulness:

Before a worker makes its move, we check if on the neighbouring
fields is an idle glob.  If there is one, we check if it is nearer
than the worker itself.  If it is, the worker passes its job and (if
present) the resource it carries.
Might look good, but as I said - this won't help warriors.
(There would be a theoretical possibilty of a resource being transfered
a long distance in an instant.)
I have omited that different globs have different speed, because I
think this would average out.

The same idea provides a way to messure, if it would be beneficial at
all.  Each time the worker (before its move) is adjacent to at least
one idle glob which is at least two fields nearer than the worker, we
increase a counter. At the end of the game we look at the counter, the
number of overall movements and their ratio.
This is a way to test the need to change the code at all.  So it would
fit both ideas.

Kai Antweiler <snth>
Group administrator
Sat 01 Apr 2006 12:00:23 PM UTC, original submission:  

let working units carry 5x5-forbidden-for-idle-units-areas with them. that would push idle units quickly out of town freeing the ways for working ones.

if that technique works well (and fast) it would be also possible to have a switch at flags telling assigned units to be prioritized over units having "normal" jobs. that way warriors would rush to their flags much faster if they have to cross crowded areas to get there.

Leo Wandersleb <giszmo>
Group Member


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


CC list is empty


There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

Only logged-in users can vote.


No changes have been made to this item

Back to the top

Powered by Savane 3.13-b921.
Corresponding source code