I have a public variable and I am trying to set it, then read it from a different function:
public var str:String;
public function DailyVerse()
{
function create() {
str = "hello";
}
function take() {
var message:String = str;
trace(message);
}
take();
}
My trace results says null
. Why does it not give me "hello"
?