Jump to content

How the find the last few enemy units?


balduin
 Share

Recommended Posts

You are at the end of a intense battle and the enemy is almost defeated, but there is still a fisher boat, a worker or trader which you cannot find. You control almost the entire map, but you still cannot find this last unit. You spend the next 5-10 minutes searching it.

I have been several times in this frustrating situation. Searching for the last enemy unit. And I wished every single time the position of this last unit would be revealed on the mini map. For example, by putting a red circle around the unit and show the position for a few seconds in the mini map.

  • Like 3
Link to comment
Share on other sites

5 minutes ago, balduin said:

I have no idea how this is implemented in Age of Mythology. Could you explain it?

It unlock ability to see the vision of the enemy. Imagine it is like the Ally vision unlock tech, but for enemies. The biggest obstacle to implementation I think is the variablecost. In AOE2, AOM, the tech change cost base on the number of enemy unit alive. So, somethink like 20 gold (metal in 0 A.D.) per enemy unit alive. What this did was prevent the tech use before the enemy was low on population. So, if the enemy's population was 100, the tech would cost 2000 gold. If the enemy only had 3 population left, the tech only cost 60 gold. This speed up the end game a lot and was a genius move byt the developers.

  • Like 2
Link to comment
Share on other sites

2 hours ago, svott said:

But what is if a player starts with a lower amount of units in a special map/scenario? Then the opponent can see everything in the beginning. So, your simple solution is not a good solution imo.

At least the way it was done in AoE the technology wasn't available until the end of the game (or rather the last age). So just have it be a final phase tech and that problem shouldn't be a problem :) Except perhaps in Deathmatch games when you have a lot of resources and the final phase might be researched by default, but at least the conditions are the same for all players :)

  • Like 2
Link to comment
Share on other sites

  • There should also be a tech to reveal enemy heroes if it's a regicide game (perhaps only for some civs? perhaps also to reveal the wonder in wonder victory games)
  • "Conquest Structure" gamemode will work with that regard (except docks as they can still be outside of any territory and the player might still want to use them to trade or build warships)
  • Like 1
Link to comment
Share on other sites

19 hours ago, svott said:

But what is if a player starts with a lower amount of units in a special map/scenario? Then the opponent can see everything in the beginning. So, your simple solution is not a good solution imo.

This was not a problem in AOK or AOM because Omniscience or Spies/Treason can be disabled in scenarioes.

Link to comment
Share on other sites

I submitted my post under @wowgetoffyourcellphone post approx. 1 second after him.

However, I really like his idea. This could be implemented as technology, which has to be developed and could be disabled if needed. I would furthermore propose, that the all enemy buildings are also revealed if somebody uses the uncover functionality (Omniscience).

But @wowgetoffyourcellphone proposes a linear function f(x) = x * 20 where x is the number of units:

f(1) = 1 * 20 => 1 Unit -> 20 metal

f(3) = 3 * 20 => 3 Units -> 60 metal

f(100) = 100 * 20 => 100 Units -> 2000 metal

I would use a non-linear function such as:

f(x) = q*x*log(x^(s*log(x))) + g

x -> number of units
g -> min. metal to uncover 1 unit

q and s -> two constants to influence the function

for example:

q = 2; s = 7

uncover 1     unit  pay 20     metal
uncover 3     units pay 70     metal
uncover 5     units pay 201    metal
uncover 10   units pay 762    metal
uncover 25   units pay 3646   metal
uncover 50   units pay 10732  metal
uncover 75   units pay 19592  metal
uncover 100 units pay 29710  metal
uncover 300 units pay 136659 metal

the intention of the function is that uncovering a few last enemies is really cheap, but uncovering 300 is really expensive. However, the function can be influenced by choosing other values for q and s.

for example

q = 1; s = 2

uncover 1 unit pay 20 metal
uncover 3 units pay 27 metal
uncover 5 units pay 45 metal
uncover 10 units pay 126 metal
uncover 25 units pay 538 metal
uncover 50 units pay 1550 metal
uncover 75 units pay 2816 metal
uncover 100 units pay 4261 metal
uncover 300 units pay 19539 metal

I created an interactive SageMath* worksheet, which is attached together with two PDF's with graphs for the above output.

*SageMath is an open source math application, which can be found in the repositories of most Linux distributions.

gold_function.pdf

gold_function2.pdf

Gold function interactive.sws

  • Like 2
Link to comment
Share on other sites

Quote

Spies is a technology in Age of Empires II that can be researched at the Castle once the Imperial Age is researched. Once researched, it allows the player to see the enemy's Line of Sight. Spies is the only technology in the game to have a variable cost. The cost depends on how many Villagers, Fishing Ships, and Transport Ships the enemy (including 'neutral' players) team has. Each of those units increases the cost by 200 gold, with a minimum cost of 200 gold and a maximum cost of 30,000 gold. Spies are researched almost instantly.

 

  • Like 1
Link to comment
Share on other sites

Just now, wowgetoffyourcellphone said:

This sounds right. I misreadmembered and thought it was 20 gold. 200 gold sounds better, and I like themax cost.

Spies is disabled in Deathmatch mode due to the massive amount of starting gold each player has.

In Regicide games, Spies is disabled. It is replaced by Treason.

 

  • Like 1
Link to comment
Share on other sites

@Lion.Kanzen My idea was that you can use the special skill "uncover" (Omniscience) against an enemy. The enemy will be selected from a list or something. Depending on how much units the enemy has left you pay. If the enemy has only one unit left you pay 20 metal. Uncovering the last 3-5 remaining units is still cheap. This is basically the "reveal enemy units" functionality at the end of the game, which I asked for at the beginning of this thread.

If you want to use the "uncover" skill during the game it will be much more expensive. The function is complex enough that most people will not be able to predict the cost to unit relationship, which is wanted. In addition parameter q and s can be changed according to the difficulty level of the enemy.

The "uncover" skill should reveal all enemy units and buildings to you an your allies. In a multiplayer game one player pays and all allied players can see the enemy units and buildings you selected.

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...