• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Comparing Temporary grids

Status
Not open for further replies.
Level 15
Joined
Nov 30, 2007
Messages
1,202
Buildings are competing for grids so when a buildings starts constructing I want to find out the preliminary available grids, one building can't have the grid of another at the same time.

IF the building is paused it loses all its grids temporarily and nearby grids will claim its territory.

IF a building is completing faster then another it will take grids from buildings under construction that are behind it.

IF the available grids are 0 the building construction will be paused.

What I currently need help figuring out:
How to detect when a building progress catches up to another nearby building?
 
Level 12
Joined
Mar 13, 2012
Messages
1,121
For some strange reason there is no reliable way to get the construction progress of a building currently. So you will have to trigger it somehow I guess..
 
Level 20
Joined
Jul 14, 2011
Messages
3,213
If you store the time it takes for a building to become "build" and start a timer from the moment it's placed for build, you can calculate the progress
 
Status
Not open for further replies.
Top