• 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.

[JASS] Do I need to null "location" or "group" if I have not initialized them?

Status
Not open for further replies.
Level 11
Joined
Oct 11, 2012
Messages
711
JASS:
function example takes nothing returns nothing
    local location loc  // I know using "location" should be avoided, but for the purpose of this thread please allow me to use it here. 
    local group g
    local timer t
    if udg_boolean = true then
         set g = CreateGroup()
         set loc = ......
         set t = CreateTimer()
         ...........
    endif
    //Do I need to do the following if "udg_boolean" is false?
    call RemoveLocation(loc)
    call DestroyGroup(g)
    set loc = null
    set g = null
    set t = null
endfunction

My question is in the code above, thnx all.
 
Status
Not open for further replies.
Top