HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Entangled/Haunted Mine Dies Completly

10-05-2005, 12:37 AM#1
MrApples
Ok, in order to make it so at startup 2 mines are entangled/haunted I used replace unit. But now when the mine is killed it dies completly instead of reverting back to a gold mine, anyway to do thsi better or fix?
10-05-2005, 08:30 AM#2
BBDino
The reaosn this occurs is because instead of the unit in question orignally being a 'gold mine' which became entangled/haunted the unit is infact a 'haunted gold mine' or 'entangled gold mine'. Thus like any other unit it goes away when killed. I dont know of a way off the top of my head to fix this without cutting some corners.

First way is to actually have a gold mine and use triggers to create an acolyte and tell it to summon a mine. If you set the build time to a really small value it wont look toooo bad. A similar thing could be done with an entagled mine and a dummy tree of life (hide it).

YOu could replace the dying mine with a gold mine, player wouldnt notice anything awry. This was my orginal idea but my only concern is you may have trouble catching how much gold should be left in the mine. Experiment.
10-05-2005, 09:55 PM#3
MrApples
Ok, creating a acolyte to do it doesn't work, and repalcing dying unit doesn't work either. I used replace unit when health becomes less than 1%
10-06-2005, 12:38 AM#4
BBDino
There is no way the acolyte could have failed to haunt an existing gold mine. You failed. However as long as you found a way to fix your problem, it doesn't matter.
10-06-2005, 01:04 PM#5
xxxSpikexxx
sure replacing dying unit doesn't work because the original unit is dead - and when you replace it the new unit will be dead as well. you should just create a new unit right on top of the dying one.
though it would be hard to figure out how much gold it had this way.

also the acolyte thing has to work if there is no error - when you try to build the haunted gold mine you can either have not enought gold or wood so you will need to give the owner of the acolite enough money for the gold mine or set a haunted goldmine's costs to 0 which i wouldn't recommend.
10-06-2005, 08:53 PM#6
MrApples
Just realized that I didn't give the Acolyte the Haunt[Instant] Ability :/. But it wouldn't work anyway... ownership is a problem. Does random unit for setting variables cause lag?
10-07-2005, 11:55 AM#7
xxxSpikexxx
random unit for setting variables?
don't realy get what you mean.

do you mean: set (unit variable) = random unit from unit group?

why would that cause lag? the Programm does a million opperations alike per second - it can't cause lag that easyly
10-07-2005, 09:26 PM#8
MrApples
i did a way that works without using random. But yes random lags for s9me reason.