• 🏆 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!

Damage Cash System [Help]

Status
Not open for further replies.
Level 1
Joined
May 5, 2009
Messages
2
Hi guys. I creating a map like Dota. I want on my map system called Damage Cash System that doing some like this:
Players during combat with enemy creeps, players or building causing damage. All time this damage is converting into material like wood (for example: Bounty). If player make more dmg then more Bounty receive also when destroy enemy buildings or denay creep receive more Bounty that normal. Player's bounty is converted into gold when he's near Bounty Hunter (he's in town). Bounty haven't same value like gold. 1.25 Bounty = 1 Gold.
It's easy: more damage caused = more gold from Bounty Hunter.
I want this system on my map but I dont know how start make this because I'm begginer.
If anyone help me make this system or only give any suggestions, I'll be grateful. And one thing: I prefer GUI.
Please help me.

Sorry for my bad English. I hope that you understand what I have on my mind.
 
Level 9
Joined
Oct 17, 2007
Messages
547
You can always use the orc ability Pillage. Modify the ability to fit your need (although returning lumber will need more triggers), trigger the game to add pillage to the units that are close to the bounter hunter and remove them when they are out of range. Use a disabled spell book to hide the added pillage ability if you want.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
For a trigger system (if pillage is not enough), you have to use the specific unit event that runs on unit damage (unit takes damage).
You also have to remembet to trigger it in such a way that ever 50 odd spawns, the trigger is destroyed and remade to reduce event leakage. Static units that never die like heroes should be attached to a trigger that never is destroyed as there is no need to destory it then. You then can convert damage directly into gold. If you want it based on unit cost, you will need an additional table system or modified natives list inorder to do so and then multiply it by the percentage damage delt. Finally, remember to make sure that they only get recources for damage delt (1000 damage to a 1 HPed unit should cound as 1 damage).

However, I advise you try and use pillage if it can do what you want.
 
Status
Not open for further replies.
Top