kopia lustrzana https://github.com/backface/turtlestitch
enabled sending atomic lists to other scenes
rodzic
69fbe439d3
commit
89a4fe410a
|
@ -44,6 +44,7 @@
|
|||
|
||||
### 2021-10-21
|
||||
* threads, objects: make "when I receive 'any message'" hat scripts threadsafe (uninterruptable by other messages)
|
||||
* threads: enabled sending atomic lists to other scenes
|
||||
|
||||
### 2021-10-20
|
||||
* blocks: enable sending green-flag events when switching scenes
|
||||
|
|
|
@ -4704,7 +4704,14 @@ Process.prototype.doSwitchToScene = function (id, transmission) {
|
|||
message = this.inputOption(transmission.at(1)),
|
||||
ide, scenes, num, scene;
|
||||
this.assertAlive(rcvr);
|
||||
this.assertType(message, ['text', 'number']);
|
||||
this.assertType(message, ['text', 'number', 'list']);
|
||||
if (message instanceof List && !message.canBeJSON()) {
|
||||
// make sure only atomic leafs are inside the list
|
||||
// don't actually encode the list as json, though
|
||||
throw new Error(localize(
|
||||
'can only send lists\nwith atomic data\nto another scene'
|
||||
));
|
||||
}
|
||||
if (this.readyToTerminate) {
|
||||
// let the user press "stop" or "esc",
|
||||
// prevent "when this scene starts" hat blocks from directly
|
||||
|
|
Ładowanie…
Reference in New Issue