Scrip self variable life cycle

Quick question in the form of some code:

function init(self)
	self.test = "test"
end

function final(self)
	self.test = nil -- Is this needed, or will it be automatically garbage collected when the game object is deleted?
end

Not needed. It will be garbage collected.

1 Like

Hurrah!