Commit graph

3105 commits

Author SHA1 Message Date
Karishma Chadha
6dfc0b678e Add integration test for monitor save/load. 2018-11-09 23:45:49 -05:00
Karishma Chadha
14bee14d8c Update extensions to load when deserializing monitors. This is necessary when the monitor is the only part of the project that uses the extension. Update extension monitor color category. 2018-11-09 23:45:49 -05:00
Karishma Chadha
df24ca7b46 Refactor sb3 monitor deserialization. Create monitor blocks with the relevant info if they don't exist. 2018-11-09 23:45:49 -05:00
Karishma Chadha
1b9b3ac909 Revert changes that were made to leverage the monitor blocks getting created when the toolbox is loaded. This approach does not work when viewing the project detached from scratch-blocks (e.g. player mode). 2018-11-09 23:45:48 -05:00
Karishma Chadha
ebdd548c8f Update for auto-positioning monitors so that having just one of x or y be 0 (e.g. a monitor placed in the top right corner of the stage) does not result in the monitor being treated as a new monitor and get auto-positioned. 2018-11-09 23:45:48 -05:00
Karishma Chadha
d690c76a34 Update sb2 deserialization of monitors. 2018-11-09 23:45:48 -05:00
Karishma Chadha
1a4f0a75f2 Serialize and deserialize monitors. Obtain monitor block information from runtime. Fix issue where stage monitors weren't getting loaded correctly. 2018-11-09 23:45:48 -05:00
Karishma Chadha
cfa71723eb Ignore video sensing monitor and import music tempo monitor unless it is hidden. Load extensions for visible monitors. Add tests for new functionality. 2018-11-09 00:09:54 -05:00
Evelyn Eastmond
3050f496b2 Resolves #1687. Clears discover timeout when needed. (#1697) 2018-11-08 15:31:15 -05:00
Evelyn Eastmond
53c165c2f6 Close Scratch Link web socket on every new peripheral scan attempt (#1696)
* Progress towards: #1671: Close web socket before making a new one for hardware extensions.

* Always disconnect before scanning for new peripheral.  Removing console logs.

* Removing unused test code.
2018-11-08 15:21:28 -05:00
Karishma Chadha
fe186913ac
Merge pull request #1742 from kchadha/multi-monitors
Multi monitors
2018-11-08 14:44:22 -05:00
Karishma Chadha
7ea310a194 Fix typo in comment 2018-11-08 14:43:07 -05:00
Karishma Chadha
87244b4110 Normalize capitalization of sensing_current block fields during sb2 import and during monitor id generation. Update monitors integration test to include sensing_current block monitors. 2018-11-08 14:11:30 -05:00
Ray Schamp
4f5aba4fe6
Merge pull request #1727 from paulkaplan/add-ext-on-share
Add unloaded extensions on block sharing
2018-11-08 10:15:58 +00:00
Karishma Chadha
5db3db3a92 monitor id getter should use block fields instead of a list of strings 2018-11-08 01:33:26 -05:00
Karishma Chadha
7d1226458f Fix import of current day of week block from sb2. 2018-11-08 00:37:49 -05:00
Karishma Chadha
0e7eae98d5 Separate out monitors for blocks reporter blocks that have parameters. 2018-11-08 00:37:28 -05:00
Karishma Chadha
8aa0fa11aa
Merge pull request #1649 from mzgoddard/get-attribute-stage-alt-name
Get attribute stage alt name
2018-11-07 17:47:44 -05:00
Karishma Chadha
4bb2d19584
Merge pull request #1683 from mzgoddard/sequencer-thread-cleanup
Sequencer thread cleanup
2018-11-07 17:15:11 -05:00
Eric Rosenbaum
2cff4159bb
Use the new note picker field in music and EV3 extensions (#1720)
* Add note field type

* Note picker in music extension plays notes

* Use note picker in EV3 beep block
2018-11-07 11:50:15 -05:00
Eric Rosenbaum
eef1885fad
On websocket error, use sendRequestError instead of disconnect (#1736) 2018-11-07 10:25:09 -05:00
Paul Kaplan
ce94144051 Fixup from comments 2018-11-07 10:11:16 -05:00
DD
5ad193b96e Better comment 2018-11-06 17:51:39 -05:00
DD
1cef52e180 Remove mysterious swp file 2018-11-06 17:43:26 -05:00
DD
3c95b32da0 Rearrange so that if we already have the asset, there's no need to go through promise.all 2018-11-06 17:39:26 -05:00
DD
2a032be1a9 Remove todo 2018-11-06 17:34:07 -05:00
DD
6763355d00 Fix scaling to perform nearest neighbor 2018-11-06 17:22:25 -05:00
DD
2bd468950f Why do our lint rules require such weird formatting 2018-11-06 16:54:41 -05:00
DD
998c5a186e Merge images as part of fetch bitmap 2018-11-06 16:44:17 -05:00
Valerie R Young
05a28e553e Say 'end' only after 4th increment 2018-11-06 13:26:25 -05:00
Eric Rosenbaum
3bd0797810
Make volume a sprite-specific monitor (#1730) 2018-11-06 10:52:40 -05:00
DD
e538800293 Merge branch 'pull915' into textLayer 2018-11-06 10:39:43 -05:00
DD
876139847a Merge branch 'develop' into pull915 2018-11-06 10:39:27 -05:00
DD
b6b3ca21d7 Load text layer asset 2018-11-06 10:36:52 -05:00
DD
88b6bdd06c Get text assets from zip 2018-11-05 18:07:56 -05:00
DD
86149325b1 Try to make loadCostume more readable, and revert deserializeCostume to changing the costume object directly 2018-11-05 17:11:07 -05:00
Valerie R Young
b64d18b627 Satisfy linter 2018-11-05 15:16:57 -05:00
Valerie R Young
2c76d3bf71 Add unit test for unknown opcode inputs 2018-11-05 13:23:31 -05:00
Paul Kaplan
979ed66594 Add a unit test to ensure extensions are loaded on shareBlocksToTarget 2018-11-05 13:01:00 -05:00
Paul Kaplan
c8ad1955d4 Load extensions before sharing blocks.
This commit fixes the unit tests so the assertions are made after the promise resolves
2018-11-05 13:00:35 -05:00
Paul Kaplan
bc1da9fa44 Move extension ID parsing into a helper and add test 2018-11-05 12:57:09 -05:00
Michael "Z" Goddard
692b71a737
Merge pull request #1709 from mzgoddard/cast-to-number
Shortcut Cast.toNumber if given a number
2018-11-02 15:58:15 -04:00
Michael "Z" Goddard
a3f9aa1e22
cache the set of actively monitored blocks
Projects can have 100's of potentially monitored blocks. Caching the
set of monitored blocks can save time in Runtime._step every frame.
2018-11-02 15:24:05 -04:00
Karishma Chadha
d64322a110
Merge pull request #1719 from rschamp/hotfix/sprite-upload-from-image
Handle images uploaded as sprites
2018-11-01 18:18:52 -04:00
Paul Kaplan
bb6aa7644b
Merge pull request #1718 from paulkaplan/block-id-on-drag-end
Include the original blockId of the top block being dragged.
2018-11-01 15:03:29 -04:00
Ray Schamp
3d06f0e633 Handle images uploaded as sprites
The sprite upload code in GUI serializes asset data, flattening it. We need to rehydrate the asset.
2018-11-01 18:28:54 +00:00
Paul Kaplan
596d0c4f5f Include the origin blockId of the top block being dragged.
This is required by the GUI in order to take a snapshot of the blocks for the backpack. Only the ID is needed, the rest can be done by the GUI.
2018-11-01 14:13:07 -04:00
Michael "Z" Goddard
bca01a9ed2
rename Stage to _stage_ when its the OBJECT input for getAttributeOf 2018-11-01 12:33:56 -04:00
Karishma Chadha
5593c9ab3e
Merge pull request #1711 from kchadha/import-cloud-var-info
Import cloud var info and enforce cloud var limit
2018-11-01 09:46:37 -04:00
Karishma Chadha
ffef2e92fc Fix up docs and incorrect initialization of cloud data manager functions. Add 'spec' unit tests that the cloud data manager functions are actually functions. 2018-10-31 19:20:13 -04:00