[JASS] Newb Questions ?

Guys, I have a question, that may sound newb ... but: How do I create a Haunted Gold mine, with gold ???

Well, you see, I found that if I create a haunted gold mine, it doesn't have gold ...
Here is the code I used:
JASS:
set x = -4600.0
set y = 1200.0
set mine = CreateUnit(p, 'ugol', x, y, 270) //creates UDmine
But the mine created has no gold..

Then I though," I know I will use a dummy!", but didn't went well.. the stupid dummy can't summon the dam mine, on a real mine ...

So, How do I do this ?
 
Level 6
Joined
Jun 30, 2006
Messages
230
I'm trying to teach him stuff like this. He overuses variables on certain things, and doesn't use variables for stuff he should, like unit and spell ID's.

Anyways, does the gold mine thing work?
 
Level 12
Joined
Aug 20, 2007
Messages
866
Similar to the subject

Instead of making a mine the way WE does it, how could you make a unit react to other units, the same way a mine would?
Perhaps making it invulnerable and its HP representing its worth in resource? (this would go for maps that have multiple minable resources)

I was thinking making a certain kind of action to change ownership of the resource (ways to do it are innumerable, from a region, to a building, to a spell cast)

But the way it would be mined, wouldn't it be sorta like a unit is ordered to move or attack, or something onto the mine-able unit, and when he reaches his destination, becomes hidden, then reappears some seconds later (configurable) with (hopefully it's a peon model)

A sack of resource on his back with orders to go back to a town hall
And then floating text to show resources have been dropped off

I was thinking about how the haunted mine + acolytes could be recreated through triggering


If anybody'd like to make the JASS code for something like that and some pictures, it would be interesting
 
Level 5
Joined
Aug 16, 2007
Messages
149
isn't a haunted gold mine just a normal gold mine with a skin on it? So find the skin in war3.mpq and use the skin for a normal gold mine?
 
Level 12
Joined
Aug 20, 2007
Messages
866
@Me or Flame?

Uhh, I'm talking more so about the code for the acolytes on the sides

But I supposed that'd work for Flames question
 
Level 5
Joined
Aug 16, 2007
Messages
149
yeah I meant flame. And about yours, it worth in resource would probably be better as point-value and floating text above it.
 
Top