Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#3332 closed defect (fixed)

[PATCH] Inconsistency in decay and regen rate sharing.

Reported by: mimo Owned by: mimo
Priority: Should Have Milestone: Alpha 19
Component: UI & Simulation Keywords: patch
Cc: sanderd17 Patch:

Description

A defenseTower has a decay rate of 5, and a regenRate for each garrisoned unit of 5. So we would naively think that a single unit is enough to stop its decay when captured in enemy territory. That's true if in the middle of the enemy territory, but not if at the border of the enemy territory which looks really inconsistent. The problem comes from the sharing of the cp points between the enemy and gaia when at the border. Let's take a tower surrounded at 60% by the enemy and 40% by gaia. The 5 decay points will be divided proportionnally in 3 attributed to the enemy and 2 to gaia. But the regenRate is equally distributed, that is 2.5 taken from the enemy and 2.5 from gaia. But as gaia was attributed only 2, only 4.5 total regen points can be taken and the decay will continue. But if the tower was fully surrounded by the enemy territory, there would be no such inconsistency and the decay would stop. The attached patch fixes the problem.

Attachments (2)

capturable.diff (1.3 KB ) - added by mimo 9 years ago.
capturable.2.diff (1.3 KB ) - added by mimo 9 years ago.

Download all attachments as: .zip

Change History (5)

by mimo, 9 years ago

Attachment: capturable.diff added

by mimo, 9 years ago

Attachment: capturable.2.diff added

comment:1 by mimo, 9 years ago

Summary: Inconsistency in decay and regen rate sharing.[PATCH] Inconsistency in decay and regen rate sharing.

comment:2 by mimo, 9 years ago

Owner: set to mimo
Resolution: fixed
Status: newclosed

In 16864:

improve consistency between decay and regen rates for buildings, fixes #3332

comment:3 by leper, 9 years ago

Keywords: review removed
Note: See TracTickets for help on using tickets.