update
This commit is contained in:
14
script_properties_global/Sources/lnx/Config.hx
Normal file
14
script_properties_global/Sources/lnx/Config.hx
Normal file
@ -0,0 +1,14 @@
|
||||
package lnx;
|
||||
|
||||
class Config extends iron.Trait {
|
||||
|
||||
@prop public var speed:Float = 0.1;
|
||||
@prop public var text:String;
|
||||
|
||||
public static var inst:Config = null;
|
||||
|
||||
public function new() {
|
||||
super();
|
||||
inst = this;
|
||||
}
|
||||
}
|
||||
12
script_properties_global/Sources/lnx/ReadConfig.hx
Normal file
12
script_properties_global/Sources/lnx/ReadConfig.hx
Normal file
@ -0,0 +1,12 @@
|
||||
package lnx;
|
||||
|
||||
class ReadConfig extends iron.Trait {
|
||||
public function new() {
|
||||
super();
|
||||
|
||||
notifyOnInit(function() {
|
||||
var c = Config.inst;
|
||||
trace("Text is: " + c.text + ", speed is: " + c.speed);
|
||||
});
|
||||
}
|
||||
}
|
||||
BIN
script_properties_global/script_properties_global.blend
Normal file
BIN
script_properties_global/script_properties_global.blend
Normal file
Binary file not shown.
Reference in New Issue
Block a user