• 🏆 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] Quick Question About Variables

Status
Not open for further replies.
Level 19
Joined
Aug 16, 2007
Messages
881
Hello there! I've just got a quick question about variables. According to the Object Manager I'm using my variable "TempPoint" in 58 triggers. Is there any chance that this may glitch using the variable in alot of triggers? I mean, is there any chance that another trigger will overwrite another triggers TempPoint variable? Regardless it's an instant or timed-event trigger? Thanks. :)
 
Level 19
Joined
Aug 16, 2007
Messages
881
It should be fine, as long as the variable is being disposed at the end and assigned at the beginning of your trigger.

Thanks for the quick answer. :) Yeah, exactly what I thought. I assing my variable at the beginning at the trigger and destroys it at the end of the trigger. It's named TempPoint because it's a temporary variable. Just thought it may glitch by using it in alot of triggers. Thanks again, +rep.
 
Level 19
Joined
Aug 16, 2007
Messages
881
It depends whether or not all your uses of it are instantaneous, or have some kind of wait/timer associated with them.

Everything is instant and I don't use waits, cause that ruins the MUI capability. The only timers I use is...

  • Events
    • Time - Every 1.00 seconds of game time
...this event, and that should not affect the variables itself.
 
Status
Not open for further replies.
Top