• Log InLog In
  • Register
Liquid`
Team Liquid Liquipedia
EDT 21:37
CEST 03:37
KST 10:37
  • Home
  • Forum
  • Calendar
  • Streams
  • Liquipedia
  • Features
  • Store
  • EPT
  • TL+
  • StarCraft 2
  • Brood War
  • Smash
  • Heroes
  • Counter-Strike
  • Overwatch
  • Liquibet
  • Fantasy StarCraft
  • TLPD
  • StarCraft 2
  • Brood War
  • Blogs
Forum Sidebar
Events/Features
News
Featured News
Serral wins EWC 202543Tournament Spotlight: FEL Cracow 202510Power Rank - Esports World Cup 202580RSL Season 1 - Final Week9[ASL19] Finals Recap: Standing Tall15
Community News
Weekly Cups (Jul 28-Aug 3): herO doubles up6LiuLi Cup - August 2025 Tournaments3[BSL 2025] H2 - Team Wars, Weeklies & SB Ladder10EWC 2025 - Replay Pack4Google Play ASL (Season 20) Announced62
StarCraft 2
General
Official Ladder Map Pool Update (April 28, 2025) The GOAT ranking of GOAT rankings Weekly Cups (Jul 28-Aug 3): herO doubles up Clem Interview: "PvT is a bit insane right now" Serral wins EWC 2025
Tourneys
StarCraft Evolution League (SC Evo Biweekly) Global Tourney for College Students in September Sparkling Tuna Cup - Weekly Open Tournament WardiTV Mondays $5,000 WardiTV Summer Championship 2025
Strategy
Custom Maps
External Content
Mutation # 485 Death from Below Mutation # 484 Magnetic Pull Mutation #239 Bad Weather Mutation # 483 Kill Bot Wars
Brood War
General
BW General Discussion StarCon Philadelphia Where is technical support? BGH Auto Balance -> http://bghmmr.eu/ Google Play ASL (Season 20) Announced
Tourneys
[CSLPRO] It's CSLAN Season! - Last Chance [Megathread] Daily Proleagues [ASL20] Online Qualifiers Day 2 Cosmonarchy Pro Showmatches
Strategy
[G] Mineral Boosting Simple Questions, Simple Answers Muta micro map competition Does 1 second matter in StarCraft?
Other Games
General Games
Stormgate/Frost Giant Megathread Nintendo Switch Thread Total Annihilation Server - TAForever Beyond All Reason [MMORPG] Tree of Savior (Successor of Ragnarok)
Dota 2
Official 'what is Dota anymore' discussion
League of Legends
Heroes of the Storm
Simple Questions, Simple Answers Heroes of the Storm 2.0
Hearthstone
Heroes of StarCraft mini-set
TL Mafia
TL Mafia Community Thread Vanilla Mini Mafia
Community
General
US Politics Mega-thread European Politico-economics QA Mega-thread Things Aren’t Peaceful in Palestine Russo-Ukrainian War Thread Bitcoin discussion thread
Fan Clubs
INnoVation Fan Club SKT1 Classic Fan Club!
Media & Entertainment
Movie Discussion! [Manga] One Piece Anime Discussion Thread [\m/] Heavy Metal Thread Korean Music Discussion
Sports
2024 - 2025 Football Thread Formula 1 Discussion TeamLiquid Health and Fitness Initiative For 2023
World Cup 2022
Tech Support
Gtx660 graphics card replacement Installation of Windows 10 suck at "just a moment" Computer Build, Upgrade & Buying Resource Thread
TL Community
TeamLiquid Team Shirt On Sale The Automated Ban List
Blogs
[Girl blog} My fema…
artosisisthebest
Sharpening the Filtration…
frozenclaw
ASL S20 English Commentary…
namkraft
The Link Between Fitness and…
TrAiDoS
momentary artworks from des…
tankgirl
from making sc maps to makin…
Husyelt
Customize Sidebar...

Website Feedback

Closed Threads



Active: 570 users

[Q] Cost to repair? - Page 3

Forum Index > Brood War Strategy
Post a Reply
Prev 1 2 3 4 5 Next All
Grobyc
Profile Blog Joined June 2008
Canada18410 Posts
Last Edited: 2009-04-24 02:42:25
April 24 2009 02:41 GMT
#41
Okay I got totally confused in my testing, and I have to go soon but I made a UMS map for testing it which can be found here:
http://files.filefront.com/test33scx/;13648175;/fileinfo.html

Some things to note:
- Operation cwal + changing the build time of the unit/building DOES AFFECT THE REPAIR COST
- Sending any unit to the beacon automatically sets your resource count(mineral and gas) to exactly 1000 each time. This is for setting a number that is high enough and easily recordable for seeing how much it cost to repair.
- The marine and ghost have modified damages incase you want to attack one of your units, reducing it's health so you can do another trial on it or something.
- I put duplicates of every mech unit, one with 100% health and the other set with 1% health.
- The factory and starport are there for building more units, in the case that you accidently killed your own or something.

Some things I noted in my little bit of testing:

- siege tank(150/100) had a repair cost of a ratio 1:1 with minerals to gas, EVEN THOUGH it is more mineral heavy than gas.
- I tried repairing a goliath(100,50) and it cost more minerals(i believe, or maybe it was gas) to repair than gas. I.E not a 1:1 mineral:gas ratio like the siege tank. it was more like 1.4:1 or something.
- When I changed the goliaths unit cost to 150/100 like the tank, it DID REPAIR AT A 1:1 RATIO.
If you watch Godzilla backwards it's about a benevolent lizard who helps rebuild a city and then moonwalks into the ocean.
Ryshi
Profile Blog Joined June 2004
Canada361 Posts
April 24 2009 03:57 GMT
#42
^that last bit is very interesting o_o
The World God Only Knows
Polemarch
Profile Joined August 2005
Canada1564 Posts
Last Edited: 2009-04-24 04:58:14
April 24 2009 04:55 GMT
#43
I'm guessing it's meant to be a 1:3 ratio of the unit/building's cost, but there's some rounding error that makes it equal gas/minerals for e.g. tank/BC.

e.g. mineral cost per repair-animation for a tank might be 1.2 and gas cost per repair animation might be 0.8; but both get rounded to 1.
I BELIEVE IN CAPITAL LETTER PUNISHMENT!!!!!
CharlieMurphy
Profile Blog Joined March 2006
United States22895 Posts
April 24 2009 09:01 GMT
#44
On April 24 2009 11:25 kakisama wrote:
so what about repair time?

That's the first thing I thought of when I saw this thread because I was already fairly certain everything is about 1/3 cost to repair.
..and then I would, ya know, check em'. (Aka SpoR)
Patriot.dlk
Profile Blog Joined October 2004
Sweden5462 Posts
April 24 2009 09:37 GMT
#45
I love blizzards algorithms =)
Thx for the people doin all the testing
jeppew
Profile Joined April 2009
Sweden471 Posts
April 24 2009 11:08 GMT
#46
it's probably like in Wc3, units have a repair cost, seperate from their acutal cost.
the repair cost is how many resources you need to repair from 0 to max hp.
so the rates should be related to their real cost but there might not be a universal algoritm for all of them, some units might be more cost effiecent to repair than others.
Jiiks
Profile Joined January 2009
Finland487 Posts
April 24 2009 11:31 GMT
#47
I tested all the units might test buildings if im bored here's my results:
Played on fastest didn't get times cause advloader clock bugged.
+ Show Spoiler +
Siege tank: 1-150hp
Minerals/Gas: 33/33
%of new: 22/33

SCV: 1-60hp
Minerals: 17
%of new: 34

Goliath: 1-125
Minerals/Gas: 34/17
%of new: 34/34

Vulture: 1-80hp
Minerals: 25
%of new: 33

Valkyrie: 1-200hp
Minerals/Gas: 84/42
%of new: 34/34

Wraith: 1-120hp
Minerals/Gas: 33/33
%of new: 22/33

Science Vessel: 1-200hp
Minerals/Gas: 33/66
%of new: 33/29

Dropship: 1-150hp
Minerals/Gas: 33/33
%of new: 33/33

Battlecruiser: 1-500hp
Minerals/Gas: 96/96
%of new: 24/32
niteReloaded
Profile Blog Joined February 2007
Croatia5281 Posts
April 24 2009 11:47 GMT
#48
On April 24 2009 11:41 Grobyc wrote:
Okay I got totally confused in my testing, and I have to go soon but I made a UMS map for testing it which can be found here:
http://files.filefront.com/test33scx/;13648175;/fileinfo.html

Some things to note:
- Operation cwal + changing the build time of the unit/building DOES AFFECT THE REPAIR COST
- Sending any unit to the beacon automatically sets your resource count(mineral and gas) to exactly 1000 each time. This is for setting a number that is high enough and easily recordable for seeing how much it cost to repair.
- The marine and ghost have modified damages incase you want to attack one of your units, reducing it's health so you can do another trial on it or something.
- I put duplicates of every mech unit, one with 100% health and the other set with 1% health.
- The factory and starport are there for building more units, in the case that you accidently killed your own or something.

Some things I noted in my little bit of testing:

- siege tank(150/100) had a repair cost of a ratio 1:1 with minerals to gas, EVEN THOUGH it is more mineral heavy than gas.
- I tried repairing a goliath(100,50) and it cost more minerals(i believe, or maybe it was gas) to repair than gas. I.E not a 1:1 mineral:gas ratio like the siege tank. it was more like 1.4:1 or something.
- When I changed the goliaths unit cost to 150/100 like the tank, it DID REPAIR AT A 1:1 RATIO.

now thats what I call a scientific approach
mahnini
Profile Blog Joined October 2005
United States6862 Posts
April 24 2009 11:48 GMT
#49
repair time and cost are related to build time and cost of whatever you're repairing. this is how people make stuff take forever to repair in UMS games, they just crank up the build times.
the world's a playground. you know that when you're a kid, but somewhere along the way everyone forgets it.
RaiZ
Profile Blog Joined April 2003
2813 Posts
April 24 2009 12:02 GMT
#50
Quick ! I'll do it before anyone can say something !
Insert a [we still have something to learn after 10 years ? Jez] comment ~
Okay solved.
Too much tl.net / starcraft yes ?
Man is least himself when he talks in his own person. Give him a mask, and he will tell you the truth. Oscar Wilde
seppolevne
Profile Blog Joined February 2009
Canada1681 Posts
April 24 2009 13:41 GMT
#51
On April 24 2009 20:31 Jiiks wrote:
I tested all the units might test buildings if im bored here's my results:
Played on fastest didn't get times cause advloader clock bugged.
+ Show Spoiler +
Siege tank: 1-150hp
Minerals/Gas: 33/33
%of new: 22/33

SCV: 1-60hp
Minerals: 17
%of new: 34

Goliath: 1-125
Minerals/Gas: 34/17
%of new: 34/34

Vulture: 1-80hp
Minerals: 25
%of new: 33

Valkyrie: 1-200hp
Minerals/Gas: 84/42
%of new: 34/34

Wraith: 1-120hp
Minerals/Gas: 33/33
%of new: 22/33

Science Vessel: 1-200hp
Minerals/Gas: 33/66
%of new: 33/29

Dropship: 1-150hp
Minerals/Gas: 33/33
%of new: 33/33

Battlecruiser: 1-500hp
Minerals/Gas: 96/96
%of new: 24/32


Do you think I could throw this in OP? Great work ^^
J- Pirate Udyr WW T- Pirate Riven Galio M- Galio Annie S- Sona Lux -- Always farm, never carry.
jeppew
Profile Joined April 2009
Sweden471 Posts
Last Edited: 2009-04-24 15:22:09
April 24 2009 13:45 GMT
#52
On April 24 2009 11:41 Grobyc wrote:
Okay I got totally confused in my testing, and I have to go soon but I made a UMS map for testing it which can be found here:
http://files.filefront.com/test33scx/;13648175;/fileinfo.html

Some things to note:
- Operation cwal + changing the build time of the unit/building DOES AFFECT THE REPAIR COST
- Sending any unit to the beacon automatically sets your resource count(mineral and gas) to exactly 1000 each time. This is for setting a number that is high enough and easily recordable for seeing how much it cost to repair.
- The marine and ghost have modified damages incase you want to attack one of your units, reducing it's health so you can do another trial on it or something.
- I put duplicates of every mech unit, one with 100% health and the other set with 1% health.
- The factory and starport are there for building more units, in the case that you accidently killed your own or something.

Some things I noted in my little bit of testing:

- siege tank(150/100) had a repair cost of a ratio 1:1 with minerals to gas, EVEN THOUGH it is more mineral heavy than gas.
- I tried repairing a goliath(100,50) and it cost more minerals(i believe, or maybe it was gas) to repair than gas. I.E not a 1:1 mineral:gas ratio like the siege tank. it was more like 1.4:1 or something.
- When I changed the goliaths unit cost to 150/100 like the tank, it DID REPAIR AT A 1:1 RATIO.



maybe the cost of repairing 1hp is (mineralcost)*k/MaxHp for minerals and 1.5*(gascost)*k/MaxHp for gas.

where k is some konstant, so if k was 1 then repairing a tank from half hp would cost 75/75.
but, i would guess that k is probably somewhere around 0.2
so repairing a unit from 1hp to max should cost somewhere around 0.2 minerals of it's cost and 0.3 gas.

edit; didn't read the cwal part, sry.
so construction speed is a factor aswell, does the cost increase the quicker the unit is built or the other way around?
Jiiks
Profile Joined January 2009
Finland487 Posts
April 24 2009 14:00 GMT
#53
On April 24 2009 22:41 seppolevne wrote:
Show nested quote +
On April 24 2009 20:31 Jiiks wrote:
I tested all the units might test buildings if im bored here's my results:
Played on fastest didn't get times cause advloader clock bugged.
+ Show Spoiler +
Siege tank: 1-150hp
Minerals/Gas: 33/33
%of new: 22/33

SCV: 1-60hp
Minerals: 17
%of new: 34

Goliath: 1-125
Minerals/Gas: 34/17
%of new: 34/34

Vulture: 1-80hp
Minerals: 25
%of new: 33

Valkyrie: 1-200hp
Minerals/Gas: 84/42
%of new: 34/34

Wraith: 1-120hp
Minerals/Gas: 33/33
%of new: 22/33

Science Vessel: 1-200hp
Minerals/Gas: 33/66
%of new: 33/29

Dropship: 1-150hp
Minerals/Gas: 33/33
%of new: 33/33

Battlecruiser: 1-500hp
Minerals/Gas: 96/96
%of new: 24/32


Do you think I could throw this in OP? Great work ^^


Yea sure i dont mind.
cyronc
Profile Joined March 2008
218 Posts
April 24 2009 15:48 GMT
#54
as far as i know (and im not quite sure about this) the formula sc uses is something like (hp-to-repair/maxhp)*(unit cost in mins and gas)*constant value

i dont know what the constant value is but it would be neat if somebody could try to run the numbers gained via experiments above through this formula and see whether its a viable explanation (and if it is what the constant value lokks like) or not

gl hf
iH82G8!
HeaDStrong
Profile Blog Joined January 2009
Scotland785 Posts
April 24 2009 16:48 GMT
#55
This is nice read. I wish I wasn't that lazy and would experiment with stuff i'm curious about.

BTW has anyone though how an SCV can repair air units but cant atack them?! a mystery to be solved...

On April 24 2009 09:46 dirtnap wrote:
i think it's something like 5 minerals per HP. not much at all.


epic troll!
SirNukes
Profile Joined April 2009
18 Posts
Last Edited: 2009-04-26 20:54:20
April 24 2009 17:38 GMT
#56
I did some testing using staredit to modify single unit values (cost, build time, health) and came up with something that should be close to the SC repair logic. Testing was done with units at 50% health. It seems to me there are three variables that describe repairs: the cost per repair cycle, the time per repair cycle, and the health healed per repair cycle. I will lay out the logic I found for calculating these in steps.

---Finding the cost per repair cycle
1) Calculate 1% of the mineral and gas cost of the repair target, ignoring zeroes.
ex1. Siege Tank: 150 min * 0.01 = 1.5 min, , 100 gas * 0.01 = 1 gas.
ex2. Armory: 100 min * 0.01 = 1 min, 50 gas * 0.01 = 0.5 gas
ex3. CC: 400 min * 0.01 = 4 min
2) Divide the smallest value from (1) into 1 and note this new value, which I will call proportional change.
ex1. Siege Tank: 1 / 1 gas = 1
ex2. Armory: 1 / 0.5 gas = 2
ex3. CC: 1 / 4 min = 0.25
3) Apply this proportional change from (2) to each of the values from (1).
ex1. Siege Tank: 1.5 min * 1 = 1.5 min, 1 gas * 1 = 1 gas
ex2. Armory: 1 min * 2 = 2 min, 0.5 gas * 2 = 1 gas
ex3. CC: 4 min * 0.25 = 1 min
4) Round down the values from (3) to obtain the cost per repair cycle.
ex1. Siege Tank: 1 min, 1 gas
ex2. Armory: 2 min, 1 gas
ex3. CC: 1 min, 0 gas

---Finding the time per repair cycle
5) Calculate 2.8% of the unit's Build Time.
ex1. Siege Tank: 50 seconds *0.028 = 1.4s
ex2. Armory: 80 seconds *0.028 = 2.24s
ex3. CC: 120 seconds *0.028 = 3.36s
6) Multiply the value from (5) by the proportional change from (2) to obtain the time per repair cycle.
ex1. Siege Tank: 1.4s * 1 = 1.4 seconds
ex2. Armory: 2.24s * 2 = 4.48 seconds
ex3. CC: 3.36s * 0.25 = 0.84 seconds

---Finding the health healed per repair cycle
7) Divide the value(s) from (4) into the unit's total cost.
ex1. Siege Tank: 1 min / 100 min = 0.01, 1 gas / 150 gas = 0.00667...
ex2. Armory: 2 min / 100 min = 0.02, 1 gas / 50 gas = 0.02
ex3. CC: 1 min / 400 min = 0.0025
8) Multiply the highest of the values from (7) by the unit's maximum health and by 3.15 (this is not exact; the game appears to use a '3' value but some framerate rounding causes it to vary between 3 and 3.3 or so). This is approximately the health healed per repair cycle.
ex1. Siege Tank: 0.01 * 150 health * 3.15 = 4.725 health
ex2. Armory: 0.02 * 750 health * 3.15 = 47.25 health
ex3. CC: 0.0025 * 1500 health * 3.15 = 11.8125 health

To summarize the examples:
ex1. Siege Tank: Costs 1 min and 1 gas to heal 4.725 health over 1.4 seconds.
ex2. Armory: Costs 2 min and 1 gas to heal 47.25 health over 4.48 seconds.
ex3. CC: Costs 1 min to heal 11.8125 health over 0.84 seconds.

The above results appear to work for costs down to 1 and up to several thousand. The numbers are likely not exact in a couple places due to rounding, but should generally be close (+/- 5% or so).

Some extra observations:
If an SCV gets its repair command interrupted during a repair cycle (likely by another command), you do not get any sort of refund on unused repair time and will have to pay the initial cost again to resume repairs. However, if the repair target moves, the repair cycle pauses until the SCV catches up, at which time it will resume the cycle from where it left off, costing no extra resources. Multiple SCVs repairing the same target each run on their own repair cycles and do not seem to interact. While the game does track fractional health values (in 256ths, I read somewhere), it does not appear to track fractional resource values, at least not with repairs.
Impervious
Profile Blog Joined March 2009
Canada4200 Posts
April 24 2009 21:10 GMT
#57
^^

Wow. Nice work.
~ \(ˌ)im-ˈpər-vē-əs\ : not capable of being damaged or harmed.
Polemarch
Profile Joined August 2005
Canada1564 Posts
April 24 2009 21:34 GMT
#58
Wow that's great, sirnukes, thank you!

Regarding the extra observation about the repair command interruption; does this mean that e.g. if you spam an SCV and repeatedly tell it to repair a bunker, then it costs more (and repairs at the same rate) than if you had just told it to repair once and let it finish?
I BELIEVE IN CAPITAL LETTER PUNISHMENT!!!!!
SirNukes
Profile Joined April 2009
18 Posts
April 24 2009 22:33 GMT
#59
On April 25 2009 06:34 Polemarch wrote:
Regarding the extra observation about the repair command interruption; does this mean that e.g. if you spam an SCV and repeatedly tell it to repair a bunker, then it costs more (and repairs at the same rate) than if you had just told it to repair once and let it finish?

It will cost more and, it seems, repair slower since there is a tiny delay after giving the repair order and the SCV starting repairs. A 50% bunker took 10 seconds and 17 minerals to repair normally, while a spam-clicked 50% bunker took 15 seconds and 104 minerals to repair for me. If you click fast enough you can stop the SCV from repairing because it will be stuck in that tiny delay. In theory, I think you could click just right so that the SCV only repairs 1 health each time, meaning a 50% bunker would take 175 minerals to repair.
arb
Profile Blog Joined April 2008
Noobville17921 Posts
April 24 2009 23:23 GMT
#60
Does it cost more if you repair with more scvs?
Artillery spawned from the forges of Hell
Prev 1 2 3 4 5 Next All
Please log in or register to reply.
Live Events Refresh
DaveTesta Events
00:00
Kirktown Co-op 1v1 Bash
davetesta62
[ Submit Event ]
Live Streams
Refresh
StarCraft 2
PiGStarcraft284
Nina 94
RuFF_SC2 8
StarCraft: Brood War
Artosis 812
ggaemo 103
Larva 68
NaDa 53
Aegong 32
Icarus 6
HiyA 2
Stormgate
WinterStarcraft673
Dota 2
monkeys_forever703
LuMiX1
Counter-Strike
taco 596
Stewie2K203
Super Smash Bros
hungrybox700
Mew2King29
Other Games
summit1g13872
tarik_tv8613
Day[9].tv1349
shahzam915
JimRising 328
ViBE210
C9.Mang0197
Maynarde110
Livibee31
Organizations
Other Games
gamesdonequick1664
BasetradeTV93
StarCraft 2
Blizzard YouTube
StarCraft: Brood War
BSLTrovo
sctven
[ Show 15 non-featured ]
StarCraft 2
• intothetv
• AfreecaTV YouTube
• Kozan
• IndyKCrew
• LaughNgamezSOOP
• Migwel
• sooper7s
StarCraft: Brood War
• Azhi_Dahaki21
• HerbMon 21
• BSLYoutube
• STPLYoutube
• ZZZeroYoutube
League of Legends
• Doublelift6018
Other Games
• Day9tv1349
• Scarra939
Upcoming Events
The PondCast
8h 23m
WardiTV Summer Champion…
9h 23m
Replay Cast
22h 23m
LiuLi Cup
1d 9h
uThermal 2v2 Circuit
1d 13h
RSL Revival
2 days
RSL Revival
2 days
uThermal 2v2 Circuit
2 days
CSO Cup
2 days
Sparkling Tuna Cup
3 days
[ Show More ]
uThermal 2v2 Circuit
3 days
Wardi Open
4 days
RotterdaM Event
4 days
RSL Revival
5 days
Liquipedia Results

Completed

ASL Season 20: Qualifier #2
FEL Cracow 2025
CC Div. A S7

Ongoing

Copa Latinoamericana 4
Jiahua Invitational
BSL 20 Team Wars
KCM Race Survival 2025 Season 3
BSL 21 Qualifiers
HCC Europe
BLAST Bounty Fall Qual
IEM Cologne 2025
FISSURE Playground #1
BLAST.tv Austin Major 2025
ESL Impact League Season 7
IEM Dallas 2025

Upcoming

ASL Season 20
CSLPRO Chat StarLAN 3
BSL Season 21
BSL 21 Team A
RSL Revival: Season 2
Maestros of the Game
SEL Season 2 Championship
WardiTV Summer 2025
uThermal 2v2 Main Event
Thunderpick World Champ.
MESA Nomadic Masters Fall
CS Asia Championships 2025
Roobet Cup 2025
ESL Pro League S22
StarSeries Fall 2025
FISSURE Playground #2
BLAST Open Fall 2025
BLAST Open Fall Qual
Esports World Cup 2025
BLAST Bounty Fall 2025
TLPD

1. ByuN
2. TY
3. Dark
4. Solar
5. Stats
6. Nerchio
7. sOs
8. soO
9. INnoVation
10. Elazer
1. Rain
2. Flash
3. EffOrt
4. Last
5. Bisu
6. Soulkey
7. Mini
8. Sharp
Sidebar Settings...

Advertising | Privacy Policy | Terms Of Use | Contact Us

Original banner artwork: Jim Warren
The contents of this webpage are copyright © 2025 TLnet. All Rights Reserved.