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

[Trigger] Sell System

Status
Not open for further replies.
Level 4
Joined
Sep 9, 2007
Messages
95
For a sell system how would I make this? So far I've got this -

Events : A unit finishes casting an ability
Conditions : Spell being cast equal to Sell
Actions :

What should I do for actions? Or is it not possible and I have to do it for every building? Or is it only possible in JASS?
 
Level 4
Joined
Sep 9, 2007
Messages
95
I am not sure but i think it's right:

Event-Units starts casting an ability
Condition-Ability Being Cast Equal To Sell
Action-Kill Casting Unit

I am not sure but i think that will work.

That would work, but that's more of destroy, not sell. I mean like SELL, like when you get something in return for it because you didn't put it in the right place.
 
Level 5
Joined
Jan 15, 2007
Messages
199
  • Sell Trigger
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Sell
    • Actions
      • Player - Add (Point Value of (Triggering unit)) to (Owner of (Triggering unit)) Current gold
      • Unit - Kill (Triggering unit)
and set the value of the tower when u sell it by changing the value in stats - point value in the object editor
 
Level 4
Joined
Sep 9, 2007
Messages
95
  • Sell Trigger
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Sell
    • Actions
      • Player - Add (Point Value of (Triggering unit)) to (Owner of (Triggering unit)) Current gold
      • Unit - Kill (Triggering unit)
and set the value of the tower when u sell it by changing the value in stats - point value in the object editor

Okay, I'll try that, thanks.
 
Status
Not open for further replies.
Top