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

[Solved] Reach Level 15 then ends and refunds money

Status
Not open for further replies.
Level 1
Joined
Jun 21, 2009
Messages
282
Need this trigger once you buy an item, it'll learn you a skill +1 up, until level 15, once level 15, and if you try to buy anymore it'll just refund you back your money.

This is what I have so far:

  • Fire Style Dragons Breath Jutsu
    • Events
      • Unit - A unit Sells an item (from shop)
    • Conditions
      • (Item-type of (Sold Item)) Equal to Fire Style: Dragons Breath Jutsu
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Level of Fire Style for (Buying unit)) Equal to 1
          • (Level of Fire Style: Dragons Breath Jutsu for (Buying unit)) Equal to 0
        • Then - Actions
          • Unit - Add Fire Style: Dragons Breath Jutsu to (Buying unit)
        • Else - Actions
          • Unit - Set level of Fire Style: Dragons Breath Jutsu for (Buying unit) to ((Level of Fire Style: Dragons Breath Jutsu for (Buying unit)) + 1)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Level of Fire Style for (Buying unit)) Equal to 0
            • Then - Actions
              • Player - Add 100 to (Owner of (Buying unit)) Current gold
              • Player - Add 1 to (Owner of (Buying unit)) Current lumber
              • Floating Text - Create floating text that reads You don't meet the ... at (Position of (Selling unit)) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Level of Fire Style: Dragons Breath Jutsu for (Buying unit)) Equal to 15
                • Then - Actions
                  • Player - Add 100 to (Owner of (Buying unit)) Current gold
                  • Player - Add 1 to (Owner of (Buying unit)) Current lumber
                  • Floating Text - Create floating text that reads You've learned the ... at (Position of (Selling unit)) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
                • Else - Actions
            • Else - Actions
It won't refund back your gold and lumber at level 15, thats what i'm needing help on.
 
Level 1
Joined
Jun 21, 2009
Messages
282
Fire Style Level 0 is there for people who don't have the passive ability Fire Style, some people might have Water Style, or Earth Style, so I implemented that Level 0 Fire Style in order for people who have Fire Style to only learn Fire Style Abilities, same for the other elements.

Do you know how I would make Fire Style only learnable for Fire abilities? same with the other elements.
 
Status
Not open for further replies.
Top