Michael "Z" Goddard
a32b15a8f9
Add VideoSensing math module
...
- motionVector takes motion component and returns a 2d vector
- scratchAtan2 takes a y and x value and returns an angle in degrees
referencing Scratch's coordinate system
2018-04-03 16:19:52 -04:00
Michael "Z" Goddard
b46c956203
Comment items in Scratch3VideoSensingBlocks
2018-04-03 16:19:51 -04:00
Michael "Z" Goddard
c291a04cc7
Add file comment block to video_sensing/debug.js
2018-04-03 16:19:51 -04:00
Michael "Z" Goddard
e65b7985cb
Add whenMotionGreaterThan hat block to video sensing ext
2018-04-03 16:19:51 -04:00
Michael "Z" Goddard
cfd74a7c7f
Add checkboxes for each video sensing debug view
2018-04-03 16:19:51 -04:00
Michael "Z" Goddard
b012d60689
Add video sensing debug C_CELL and AB_CELL views
...
- Rename UV to UV_CELL, UV cannot be rendered in a non-cell format
Modify C and AB views as well to better represent in color the work being done.
If you watch the debug views with XY_CELL, AB_CELL, C_CELL, and UV_CELL you can
see how AB_CELL and C_CELL affect UV_CELL in similar color patterns.
2018-04-03 16:19:51 -04:00
Michael "Z" Goddard
0a58a6d806
Merge pull request #1001 from mzgoddard/motion-detect
...
Motion detect
2018-04-03 16:19:26 -04:00
Michael "Z" Goddard
f3d19dc1a1
Use videoSensing extension for sb2 senseVideoMotion
2018-03-29 19:02:07 -04:00
Michael "Z" Goddard
c206dc3241
Add motion playground page for debugging video sensing
2018-03-29 19:02:07 -04:00
Paul Kaplan
2d9bd92140
Merge pull request #930 from ericrosenbaum/bugfix/loudness-performance
...
Only measure loudness once per step
2018-03-29 16:27:10 -04:00
Michael "Z" Goddard
3c473f6ba8
Translate scratch 2 video sensing into scratch 3 extension
...
- Add videoSensing extension to extension-manager
2018-03-29 15:15:11 -04:00
kchadha
51306e3492
Merge pull request #963 from towerofnix/foreach-vm
...
Implement for-each block
2018-03-28 10:52:14 -04:00
Florrie
307a48da5a
Remove tests for old behavior
2018-03-28 11:38:19 -03:00
Karishma Chadha
1511fa79e3
Update tests to allow parsing whole .sb2s
2018-03-25 19:08:52 -04:00
Karishma Chadha
b8e67a7727
Hookup sb2 import code to deserialize assets from local sb2 file.
2018-03-25 18:14:30 -04:00
Paul Kaplan
13641297fd
Merge pull request #996 from paulkaplan/fix-bubble-bounds
...
Position the speech bubble more tightly.
2018-03-23 14:36:52 -04:00
Paul Kaplan
ea534b35ea
Position the speech bubble more tightly.
2018-03-23 10:51:19 -04:00
kchadha
dbc7b9597f
Merge pull request #979 from kchadha/serialization-cleanup
...
SB3 Serialization & Load Project
2018-03-23 10:11:49 -04:00
Paul Kaplan
a27ed888d2
Merge pull request #992 from paulkaplan/stage-clicked
...
Make "when clicked" blocks target dependent.
2018-03-23 09:20:22 -04:00
Chris Willis-Ford
9dc3df1fda
Merge pull request #994 from cwillisf/looks-extension-support
...
Looks extension support
2018-03-22 15:16:21 -07:00
Florrie
1db4a2c7a7
Compatibility implementation
2018-03-22 18:55:36 -03:00
Eric Rosenbaum
4e3c5c7f2e
Merge pull request #991 from ericrosenbaum/bugfix/clones-share-activesoundplayers
...
Clones share their parent’s activeSoundPlayers object
2018-03-22 16:49:04 -04:00
Karishma Chadha
c4ad76eef1
Turns out ArrayBuffers are not views of themselves.
2018-03-22 16:19:36 -04:00
Karishma Chadha
3a4f620318
Check if loadProject input is any typed array using ArrayBuffer.isView. This allows us to pass a project's asset.data (from storage) directly instead of calling toString on it first.
2018-03-22 14:04:58 -04:00
Karishma Chadha
2c3e3472ed
Add warning to 'fromJSON' function since it is now just a wrapper around loadProject. Change vm sb3_serialization test to use 'loadProject' function instead of 'fromJSON'.
2018-03-21 17:55:02 -04:00
Karishma Chadha
ce6ef92eb5
Clear runtime after validation success instead of before.
2018-03-21 17:46:39 -04:00
Karishma Chadha
ab863096cd
Remove cruft and fix for..in loops.
2018-03-21 17:42:01 -04:00
Karishma Chadha
9d3a3fd12f
When serializing md5+ext, the name should reflect that. Deserializing translates this name back to what vm and other components currently expect.
2018-03-21 16:51:40 -04:00
Karishma Chadha
24e248d4fb
Removing cruft...
2018-03-21 14:46:21 -04:00
Christopher Willis-Ford
26bc7851bb
Rename ReporterScope.SPRITE to TARGET & add JSDoc
2018-03-20 15:30:34 -07:00
Christopher Willis-Ford
d3352ac54d
Add JSDoc tags for ArgumentType & BlockType
2018-03-20 15:26:27 -07:00
Christopher Willis-Ford
1049e90a8f
Wrap extension menu function to provide context
...
When the extension system calls a function to retrieve extension menu
items, it now provides the ID of the current editing target. There's
also now a little bit of error-checking on the results.
2018-03-20 15:26:27 -07:00
Christopher Willis-Ford
2932f232c4
Improve developer feedback for missing block func
2018-03-20 15:26:12 -07:00
Christopher Willis-Ford
4201f212d3
Add JSDoc for extension metadata format
...
This is a first pass and is probably not 100% correct. It also contains
the new (experimental?) reporter scope field.
2018-03-20 15:05:21 -07:00
Christopher Willis-Ford
6a06984678
Add enum for reporter scope
...
Some reporters are sprite-specific, such as the costume name/number or
X position of the sprite. Others are global. This enum allows an
extension author to specify the scope of a reporter.
2018-03-20 15:05:21 -07:00
Paul Kaplan
140094a7ad
Make "when clicked" blocks target dependent.
...
This involves adding a new opcode, event_whenstageclicked, and adding a
method to the blocks container to update the opcode pair depending on
whether the target is the stage. This method is then called in two
places: first after the sb2 import parses the blocks (not done in the
sb2 parsing itself because no other blocks are target specific) and then
again when blocks are shared between targets.
Also added tests for the block container method, and a fixture project
that tests the opcode splitting on sb2 import.
2018-03-20 10:41:50 -04:00
Eric Rosenbaum
2b985fa083
Merge pull request #975 from ericrosenbaum/bugfix/move-volume-to-rendered-target
...
Move volume to rendered target
2018-03-19 16:45:25 -04:00
Eric Rosenbaum
2527c804ea
Clones get ref to parent’s activeSoundPlayers obj
2018-03-19 16:44:49 -04:00
Chris Willis-Ford
4c0e968bec
Merge pull request #978 from cwillisf/fix-saythink-and-wait
...
Fix say/think and wait
2018-03-19 10:36:01 -07:00
Paul Kaplan
979c8b05e0
Merge pull request #965 from bartljak/issue#960
...
fixed issue 960
2018-03-19 06:06:00 -07:00
Karishma Chadha
b4f6f24926
Fix up tests.
2018-03-16 11:43:27 -04:00
Eric Rosenbaum
ec0eca2b86
Merge pull request #981 from towerofnix/fix-key-pressed-import
...
Make "key pressed?" sensing block import correctly
2018-03-16 11:42:35 -04:00
Florrie
6517bd0974
Make 'key pressed?' block import correctly
2018-03-16 11:58:25 -03:00
Karishma Chadha
003ed01015
Update VM to use scratch-parser callback interface
2018-03-15 22:40:40 -04:00
Andrew Sliwinski
1d90c82fcf
Merge pull request #945 from picklesrus/translate-extension
...
Translate extension block
2018-03-15 08:36:39 -04:00
kchadha
a3ed4cad99
Remove todo
2018-03-14 22:52:00 -04:00
kchadha
0d55e4c74f
Modifying apis to accomodate existing tests.
2018-03-14 22:52:00 -04:00
kchadha
22be2b15f3
Major refactor of project loading. Removed loadProjectLocal, in favor of going back to single API (loadProject). loadProject uses scratch-parser to unpack and validate project. Scratch-parser is getting updated to return validated project, with appended project metadata, and unpacked zip (JSZip object) if provided a buffer.
2018-03-14 22:52:00 -04:00
kchadha
2c551d1739
Some more cleanup.
2018-03-14 22:51:59 -04:00
kchadha
09c8110923
Always serialize parent and next on a block even if they're null.
2018-03-14 22:51:59 -04:00