• 🏆 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] Real variable to be used many times, needs array?

Status
Not open for further replies.
Level 3
Joined
May 6, 2007
Messages
66
  • Victim Gold
    • Events
      • Unit - A unit owned by Neutral Victim Dies
    • Conditions
      • (Owner of (Killing unit)) Equal to Neutral Extra
      • ((Custom value of (Killing unit)) Greater than 0) and ((Custom value of (Killing unit)) Less than 7)
    • Actions
      • Set victimreal = ((Real((Point-value of (Dying unit)))) x (Random real number between 0.90 and 1.10))
      • Player - Add (Integer(victimreal)) to (Player((Custom value of (Killing unit)))) Current gold
      • Floating Text - Create floating text that reads (String(victimreal)) above (Dying unit) with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
There are many units for Neutral Victim, and if each is to be killed by Neutral Extra at the same time, would the game crash if there are not enough "victimreal"? Does that mean I would need an array?
 
Status
Not open for further replies.
Top