• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Sell Function

Status
Not open for further replies.
Level 5
Joined
Nov 14, 2008
Messages
119
How do i do a sell trigger?
Currently i've a "sell" trigger.
But it only sells for 75% of the first tower gold.

My tower is upgradable e.g you can upgrade 5 times,the total gold for upgrading 5 times is 500gold.But when i use the sell trigger it only sells for 15 gold.Which is 75% of how much the first tower cost.

+rep to anyone who can help!Thanks in advance.
 
Level 5
Joined
Nov 14, 2008
Messages
119
Edit:Okay
Event->Player 1 red finishes training a unit.
Conditions->Trained unit equal to Sell.
Actions->Special Effect,
->Remove trained unit from the game.
->Remove triggering unit from the game.
->Add point-value for triggering unit to owner of trained unit current gold.
->Display to the owner of player group,owner of house,you recieved (string((point-value of triggering unit.<and the behind is the text>
 
Last edited:
Level 13
Joined
Nov 4, 2006
Messages
1,239
Level 5
Joined
Sep 13, 2008
Messages
165
See the 'Add Point Value' Trigger? That there is your problem
Because you no doubt copied the lvl 2 tower from the lvl 1 tower, the point value (a value in the Object Editor) is the same for all the units. (which is 15). Just change the Unit's Point value in the Object editor to 75% of the upgrading cost.
 
Status
Not open for further replies.
Top