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

Integer(Wood Stock) Increase

Status
Not open for further replies.
Level 6
Joined
May 1, 2009
Messages
156
I could mess around with the editor to find how to add to integers but I just figure not try and mess up somewhere, so can someone tell me how to periodically increase like wood stock. (Ex. Every 5 seconds you get +5 wood)
 
Level 19
Joined
Feb 25, 2009
Messages
2,004
This is for all players that are in-game and are controlled by user(s):
  • Lumber
    • Events
      • Time - Every 5.00 seconds of game time
    • Conditions
    • Actions
      • Set PlayersInGame = (All players matching ((((Matching player) controller) Equal to User) and (((Matching player) slot status) Equal to Is playing)))
      • Player Group - Pick every player in PlayersInGame and do (Actions)
        • Loop - Actions
          • Player - Add 5 to (Picked player) Current lumber
      • Custom script: call DestroyForce(udg_PlayersInGame)
 
Status
Not open for further replies.
Top