• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

[Trigger] Clarifying variables

Status
Not open for further replies.
Level 2
Joined
Nov 4, 2017
Messages
8
So i was trying to assign a location variable to another location variable also the logic of my trigger was all correct except that i notice is that when i try to reassign the latter variable it takes and removes the value of the former variable. If i may ask are gui variables pointers? Are there any specifics why variables acts like pointers in gui?
 
Not a trait of GUI, all object variables in jass are refs. There is no general copy construction. Imagine you could just copy a unit, some objects are interactive in the game world. With a location it's relatively easy, though, there is a function "Convert coordinates to point" as well as "X of point" and "Y of point".

In the jass world, locations are mostly not required, by the way.
 
Status
Not open for further replies.
Back
Top