Free and Open Source real time strategy game with a new take on micro-management

Current Issues with Game Behavior

From Globulation2

Jump to: navigation, search

This wiki page is a part of a listing of Current Issues with Using Globulation 2. It has been placed on its own page due to problems with wiki pages beyond a certain size. See that page for an explanation of the status of the listing.

Autonomous Unit Behavior


  • BUG: Explorers summoned to distant exploration flags tend to not have enough smarts to know when to go back for food, and thus frequently die when this is done. (This is bug 19603 (“explorers starve to death near distant exploration flags”).)

  • It would be nice to be able to request that explorers follow coastlines. Or they should do this on their own, simply finding coastlines interesting. Right now to do this I have to keep moving an exploration flag to coax an explorer along a coast. This is quite tedious and prevents me from doing anything else. If I am guiding two explorers, then I have to ignore everything else. Plus, the explorers typically die in the end because they are not smart enough to go back for food.
  • Even if you have 100s of explorers, they will leave large chunks of the world unknown even though they can get there and back without starving. If explorers find unknown territory, they will (sometimes, sometimes not!) explore the edge, but if they are in the middle of known territory, they generally wander aimlessly. Explorers can be relied upon to explore a 64 by 64 map fairly well, and eventually (if you wait long enough) they will probably explore a 128 by 128 map. But you will wait forever for them to explore a 256 by 256 map, and they will certainly never explore a 512 by 512 map.

Miscellaneous Issues with Autonomous Unit Behavior

  • Globules carrying the same kind of resource (for constructing/supplying a building) or seeking the same service (food/healing/training) or seeking to do the same kind of work (clearing or war/exploration flags with level requirements satisfied by both globules) that are closer to each others' destinations should swap destinations. For example, I often see this kind of situation, where each X marks a worker carrying wheat and the arrows indicate where the workers are going:

               X ----------------------------------------->

    In addition to the obvious direct benefit of getting the globules to their destinations more quickly, this would also reduce traffic jams (which can get quite bad).

    I don't know how to calculate this both efficiently and optimally. The simplest way to calculate it is to compare every pair of globules carrying the same kind of resources. For each such pair of globules, call them X and Y, look up X's current location in Y's destination's gradient, and look up Y's current location in X's destination's gradient. If X is closer to Y's destination, and vice versa, then they should swap destinations. Unfortunately, comparing all pairs is inefficient because there will be too many pairs because the number of pairs grows extremely fast. To make it efficient would need some heuristic for deciding on which pairs to actually compare. Perhaps this heuristic could focus on regions with bad traffic jams. Even picking some pairs randomly to compare (and swap destinations if appropriate) might make a big improvement in globule performance. (By the way, a fully optimal solution to rearranging destinations might in theory have to consider also triples, quadruples, etc. That's probably way too difficult to even consider implementing.)

    Bug 16242 (“improvement-idea for pathfinding concerning idle units”) comment #1 is related. Bug 19488 (“unit allocation seams to ignore distance (22-rc)”) seems to be describing the same problem but has a different idea about the solution.

  • Before moving toward a building to feed/heal/train, a globule books a place in the building. However, for extreme long distance trips, this sometimes is wasteful, because it can leave the slot in the building unused for a long period of time. It might perhaps be better if globules sometimes moved toward (one or more) buildings they wanted to use and did not try to book a place until they were sufficiently close. Perhaps this distance could be derived from the estimated time to arrive and the estimated time for a globule (i.e., some other globule) to get served by the building?
  • Globules know where resources are in unexplored areas that are not yet visible. It is inconsistent that workers can see things that the player can't.

    Warning: Any solution to this would have to take into account that glob2 currently depends in a number of ways on globules knowing where resources are without having seen them:

      The current approach simplifies the implementation by sharing part of the computation of resource gradients among all players. (It is not clear to me how big of an advantage this is, because the actual gradients can not be shared because different players have different forbidden regions.) The fix would involve sharing even less of the computation, because the different players have explored different parts of the world.

      The current approach allows computing gradients using the resources that are actually there, instead of each player's memory of what resources have been seen most recently, which might differ because of the actions of other players. Solving this would involve implementing some notion of memory.

      With the current approach, only explorers need code for exploring. This is significant because glob2 does not (yet) have a good gradient-based method for exploring. (There are some untested and unimplemented proposals.)

      The current approach simplifies map design, because the map designer can assume workers will know where to find resources. (This might be solved by starting each player with 1 explorer, which many designed maps already do.)

      The current AI opponents depend on their warriors being able to automatically find a path to attack you, because the AI opponents do not actually explore the world and instead cheat to find out where your base is and simply place war flags on your locations despite never having actually seen the locations.

  • Workers that have picked up a resource that ends up unneeded often seem to end up discarding it for another type that is needed. In many cases, it might be better for them to hang on to the resource for a while, because it will likely be needed. (Or maybe there should be some way to stockpile unused resources?)
  • It would be nice to be able to force individual globules to abandon their current activity and try picking a new one. Even better would be to allow ordering a globule to go to a particular place or work on a particular task. This might actually allow reducing micromanagement, because right now one often must take many actions with building and flag settings and areas to get the same effect as a direct order to a globule.

Bugs in Individual Globule Behavior

  • BUG: I have seen workers bringing some resource for construction almost reach their destination, then abruptly completely forget about being assigned to construction. You can see the moment when they forget about their assignment because they lose the white circle (I keep pressing and releasing the mouse button on the construction site so I can watch them). They will then do something else like harvesting wheat (throwing away the wood or stone they were carrying) to deliver to an inn. This does not happen because the building they were working for has all its resources. There is no obvious sensible reason for this to happen. (This is one item in bug 19592.)
  • BUG: I have seen workers carrying wood wander around just next to a construction site that needs wood, but do nothing and instead wander aimlessly. (This is one item in bug 19592.)
  • BUG: I have seen 10 workers assigned to bring wheat to an inn. I watch what the assigned workers are doing and I see them wandering around aimlessly, despite plenty of wheat nearby. If “draw unit paths” is on, I sometimes see a line going from a worker to some empty cell (near but not in the wheat field) and the worker moves from cell to cell near this target cell. This seems to happen most in situations of high congestion. (This is one item in bug 19592.)
  • BUG: I have seen workers right next to an inn that needs construction and does not have all workers assigned yet, and next to wood that can be used for it, and with nothing to do, and not hungry yet, and yet just doing nothing. (This is one item in bug 19592.)
  • BUG: I have repeatedly seen hungry warriors within direct sight of an inn (with an unblocked path to the inn) that has both food and places just sit there spinning (not moving by even one cell) and starving to death. This happens most frequently after the warriors were summoned into battle with a war flag, although I have seen it at other times. If “draw unit paths” is on, sometimes one can periodically see a line flash out from each warrior to some sensible destination, but the line immediately disappears. The warriors stay in place until they run out of hit points due to starvation. Note that when the warriors initially get into this stuck state, they still have plenty of food and are unwounded. I have recently discovered that manually placing a forbidden area on the warriors generally helps to get them unstuck. (This is one item in bug 19592.)
  • BUG: Workers sometimes harvest wheat even when the only offered jobs are from inns that are full of food and have no guests, and there are no clearing areas or clearing flags. There are no building sites or hives needing wheat. The workers that harvest wheat are shown as carrying wheat after it happens, as though they were harvesting the wheat to carry it to a building. When this happens, the indicators of small dots above the inns show only black dots meaning that the inns have not accepted any workers.

AIs (Computer Players)

  • To help understand the AIs, it would be nice if there were an easy way to watch AIs play against each other as a spectator. It would also be nice if it were possible for such a spectator to see the world from the point of view of each AI. (Actually, there is! It is just undocumented and not straightforward to discover. Also, it only allows you to see the game from the point of view of one of the AIs. You can't switch around or watch the entire map.)
  • What does “Numbi” mean in the name “AINumbi”? Similarly, what does “Castor” mean? What does “Nico” mean? Etc.
  • Can “AINumbi” please be renamed to “AIPathetic”? ☺ In my brief experience, “AINumbi” often dies before it even encounters an enemy. An AI this pathetic deserves a name that will properly explain to the player just how weak and hopeless it is.
  • AINumbi has an annoying tendency to die all on its own if started in a location that is not close to resources. It would be better if this just slowed it down, rather than causing it to die.

Flags, Areas, and Work Assignments

  • It would be helpful if there were a flag that summons workers even if there is nothing to clear. I have wanted to try to force a worker migration to another island to have a local surplus of workers there, and there seems to be no easy way to do this. I think it might be better to rename clearing flags to “work flag” and change things so that if you turn off all of the kinds of resources to clear, workers will come regardless. (It would be good of course to keep the current behavior that if clearing is requested and all resources are cleared then workers do not get assigned.)
  • It would be nice to have a kind of area that allowed harvesting of the resources in a cell provided the last resource was not taken. So harvesting would be allowed if the resource was 2/5, 3/5, 4/5, or 5/5. An AI can do this easily by creating/removing forbidden areas depending on the amount remaining of a resource, but it is too micromanage-y for a human to be able to do. (Or maybe the amount of resource on a location should affect the probability of it spreading to the next location, so that there would be benefits from allowing a resource to be higher than 1/5?)
  • It would be helpful to have an area that means “clear this if it is forest, protect this if it is wheat”. Otherwise I spend too much time micromanaging the areas. (It is not clear what the user interface would look like. (Are there enough colors/patterns for another kind of area?) I basically want all of the settings I can make with clearing flags, but combined with the ability of areas to specify the precise region easily.)
  • It would be nice to have areas that are forbidden only for harvesting and that if empty can be moved through. (Yes, I know that this might prevent a new resource from growing there if a globule is on the location at the wrong time.)
  • Clearing areas appear to override forbidden areas. This has the result that a worker will clear the cell, but not move into the cell. (This should be documented.) This causes user interface difficulties because I often find myself in a race with the mouse to both remove a clearing area and place a forbidden area before a worker clears it. Unfortunately I often end up losing the race. (Generally, I placed the clearing area trying to get rid of wood, and the wood is now gone and some wheat has just grown, and I desperately want to keep the wheat to help expand a farm or guard the farm's border against wood.)

    (Kai thinks the current behavior is not right, and Leo thinks it is correct.)

  • It would be nice to have clearing areas that will attract workers like clearing flags do. The circular areas of clearing flags are very tedious to use.
  • It would be nice to have a kind of clearing area/flag which makes its resources preferred for building purposes rather than causes the resources to be chopped down and thrown away. The idea is that when a worker needs wood, they would be willing to go a bit further to chop down wood from this area, and when a worker chops down wood in this area, the worker would try to find a building that needs wood before discarding it. What I am imagining is a kind of clearing area where the speed of clearing is not as important as using the resources well. (Perhaps this idea is not so important because it seems relatively rare for resources to be so tight that one can't afford to simply slash and burn in Brazilian-rain-forest style. Not an ecologically good message, but when you're out for world domination these things are less important.)
  • When a building is set to X workers and the number of resources needed to finish construction/repair/upgrading is Y, then up to min(X,2*Y) workers can be assigned. The multiplication by 2 in 2*Y speeds completion (especially when some of the workers can't complete their task because of hunger or enemies), but also often results in worker effort and resources being wasted. For high priority buildings, one is willing to waste some resources and (more importantly) worker effort/time, but for low priority buildings it is better not to waste workers' time bringing resources that will then end up being discarded. If one doesn't want this waste to happen (e.g., the building is not important enough), it is very tedious to micromanage the number of workers requested for a building as the building nears completion to keep this from happening. It seems like it ought to be possible for some (most?) buildings to not have this wasteful duplication of effort happen. (If priorities are added, then the priorities could be used to decide whether to allow the waste in the hope of gaining speed. This would allow the user to say whether it is more important to finish the building quickly or more important to not waste workers' time.)

    (By the way, does the current code work on a per-resource type basis? So that if 2 algae and 1 wood are still needed, then maximum 2 woods and 4 algae will be requested? Or does it mix up the different resource types?)

Miscellaneous Game Behavior Issues

  • BUG?: If you upgrade a building that will become larger due to the upgrade, and while waiting for globules to exit the building and the larger area a resource grows on the larger area, then it seems that the upgrading is silently canceled! It seems to me that it would be much better if the upgrade were not canceled and the building status indicator showed that it was waiting for the area to be cleared.
  • BUG?: There are numerous abuse possibilities with building sites! The most impressive that has occurred to me so far is filling a region (perhaps the whole map?) with bogus stone wall building sites with the requested workers set to zero. You get 1 hit point per location for free! You can fill a location at an arbitrary distance from your other units at no cost. Nothing can grow or move on the location. You get told when enemy warriors attack your bogus building sites. Enemy warriors will waste their time destroying your bogus building sites. Enemy defense towers will waste their ammunition on your bogus building sites. You can get rid of the building sites when you want to move through them (and then recreate them after you pass through). If any AI ever used this it would be unbeatable by a human because it could do it much more effectively than a human.

    There appears to be some minor protection against this now. It seems that within 5 seconds after an enemy destroys one of your building sites, you can not make another. This protection is a bit weak. You can make a bunch of bogus building sites at once. You can also simply wait 5 seconds (and an AI could set a timer to wait exactly 5 seconds).

    It might also help to forbid setting the requested workers of a building site to zero. This way, bogus building sites would at least attract workers, discouraging their use. Or having zero requested workers could be allowed, but a building site with a zero workers setting that persists for more than a few seconds would be deleted. (A few seconds would be allowed in case the user makes a minor mistake while adjusting things.) Of course, this is only a partial solution because you could still make the construction sites in some place inaccessible to your workers to prevent workers from spending time on them (possibly surrounding the building sites with forbidden areas to accomplish this).

    The above “solutions” are only partial. The only fully correct solution that I can see is to make building sites that have not yet had any resources supplied have no real existence: zero hit points, workers/warriors can walk on them (and enemy units don't even see them), resources can grow on them, etc. This would be a larger change and would obviously take a lot more time to implement.

  • To reduce the micromanagement, it might help a lot to give human players access to some of the mechanisms used by the AIs. Although the individual globules are fully AI-driven, the player must still fiddle with the placement and settings of numerous buildings, flags, and areas. For example, the human may think, “I need another inn, so please suggest a good place for one.”, and this would be done by using the AI's algorithms. Or the human may think, “I would like my buildings to have a good number of workers assigned to each, so please tell me where you think the current assignment is high or low and give me an easy way to follow your advice.”. Overall, it seems that it could be much better for human players to be based on an AI with human intervention at key points.

    Apparently one can already today get part of the effect of this by allying with an AI. But how do you do it properly? I suppose one wants to start with just one hive shared between the human and the AI, as though they were really just one player. It would be nice if there were clear instructions on how to do this and/or a nice interface to request this to be set up. (Actually, it turns out the interface is really easy. It's just not documented.) And it would be nice if there was some way to tell the AI not to make certain choices or interfere with some things (this part will be hard).

  • It would be useful if the distance from water that wheat and wood grows could be set on a per-map basis, with the default for randomly generated maps depending on the map size and type. For maps with thin land-masses (like those randomly generated by the “Swamp” or “Crater Lakes” generators), often wood/wheat overgrows the entire land-mass. This causes big problems for AIs and forces humans to waste lots of their time clearing wood/wheat.
  • I don't understand how harvesting fruit works. For example, in one game I had only 3 cherry trees, zillions of globules, and yet all my inns had lots of cherries in them and most of my globules had some fruit the last time they ate. How does this happen? This seems impossible.
  • The documentation should explain that if you destroy a building, you don't get any of its resources back. (Yes, one quickly discovers this, but it would be nice for it to be in the documentation.)
  • What effect does happiness have? The documentation seems to indicate that fruit-induced conversion is governed only by what food is available and not by past history. Am I missing something?
  • What happens to globules that are inside a building at the time it is destroyed? It would be nice if this were documented. I've never been able to tell for sure exactly what happens.