diff options
| author | jmoenig <jens@moenig.org> | 2014-09-29 09:50:16 +0200 |
|---|---|---|
| committer | jmoenig <jens@moenig.org> | 2014-09-29 09:50:16 +0200 |
| commit | 8b5fa7f23c82999ff8cf34731f053e7e58766643 (patch) | |
| tree | 66c5cb64396308b31286f691955b20b52e0e66a6 /threads.js | |
| parent | 94c44902e1307d9477d43fe78e5b7df4430741f9 (diff) | |
| download | snap-yow-8b5fa7f23c82999ff8cf34731f053e7e58766643.tar.gz snap-yow-8b5fa7f23c82999ff8cf34731f053e7e58766643.zip | |
fixed #591
fully copy local variables for sprite duplicates and (Scratch-like)
clones
Diffstat (limited to 'threads.js')
| -rw-r--r-- | threads.js | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -83,7 +83,7 @@ ArgLabelMorph, localize, XML_Element, hex_sha512*/ // Global stuff //////////////////////////////////////////////////////// -modules.threads = '2014-September-18'; +modules.threads = '2014-September-29'; var ThreadManager; var Process; @@ -2973,8 +2973,11 @@ VariableFrame.prototype.toString = function () { }; VariableFrame.prototype.copy = function () { - var frame = new VariableFrame(this.parentFrame); - frame.vars = copy(this.vars); + var frame = new VariableFrame(this.parentFrame), + myself = this; + this.names().forEach(function (vName) { + frame.addVar(vName, myself.getVar(vName)); + }); return frame; }; |
