Commit Graph
231 Commits
Author SHA1 Message Date
Eric Rosenbaum e19c1942c3 Merge remote-tracking branch 'LLK/develop' into develop
# Conflicts:
#	src/index.js
#	src/sprites/clone.js
#	src/worker.js
2016-09-13 18:09:43 -04:00
Eric Rosenbaum d9a703b4ad play sound and play note block 2016-09-13 17:52:54 -04:00
Eric Rosenbaum 7709a4095e first working audio engine using audioworker 2016-09-07 16:55:38 -04:00
Eric Rosenbaum 6d21890338 Merge remote-tracking branch 'LLK/develop' into develop 2016-09-06 12:55:19 -04:00
Eric Rosenbaum 8bf2949eea play note block uses scale degree input 2016-09-06 12:54:58 -04:00
Tim Mickel 3dbfc3fdb6 Tweaks from SB2 importer audit (#137)
* Fix SB2 variable imports!

* Fix expectedArg field types

* motion_pointindirection uses math_angle

* Fix "think for secs" expected input

* Add handling for empty input case (empty if-else, for example)

* Fix opcodes for if_else, repeat_until, set tempo

* Specialized number fields for SB2 import

* Convert color picker numbers to hex in SB2 import

* KEY_OPTIONS -> KEY_OPTION

* Backdrop blocks get BACKDROP

* Update toolbox XML to match naming changes

* Merge in math_angle case

* Move color converter to its own utility

* Fix merge conflicts

* Add negative color check.

* Fix keyoptions naming

* Pen JSON tweak post-scratch-blocks update
2016-09-06 11:46:10 -04:00
Tim Mickel 9a8b68643a Shadow improvements (#135)
* Always add `next` to block representation

* Add `shadow` property to inputs, to maintain obscured shadows

* Create obscured shadows in SB2 import

* Add XML import of obscured shadows

* Alias SB2 shadow inputs to block inputs

* Add shadow to inputs on "delete inputs" test

* Add a small test to ensure obscured shadows are preserved

* Add more obscured shadow tests
2016-09-06 10:55:52 -04:00
dekrain 7caf8e588a More hats (#143)
* Key pressed hat

* Tabs -> Spaces

* Oops

* Edge activate

* Fix hat

Phew...

* I forgot to change it also here

:/ :/ :\

* Minor fixes for TravisCi

* Minor docs

* Line length
2016-09-03 16:33:45 -04:00
Tim Mickel e831866789 Keyboard events, "key is down" reporter (#117)
* Keyboard events, "key is down" reporter

* Update comment about inputs

* Simplify/generalize keyMap into a keys-pressed list

* Cast values passed to scratchKeyToKeyCode appropriately.

* Cut unspaced key values

* Fix lint from merge commit
2016-09-02 11:23:09 -04:00
Tim Mickel 86f136dd10 Merge pull request #115 from tmickel/feature/2.0-loader
Start of a 2.0 project loader
2016-09-02 11:16:35 -04:00
Tim Mickel 77d0376b15 Merge pull request #107 from tmickel/feature/hats
Hat blocks
2016-09-02 11:12:07 -04:00
Tim Mickel ae89cfbb6b Comment nit 2016-09-02 09:47:27 -04:00
liam4 1437a358e1 getDay is zero-based where Sunday = 0; Sunday should be 1 2016-09-02 10:20:54 -03:00
liam4 602cb47a1e Remove unused util variable 2016-09-02 01:01:17 -03:00
liam4 f981e8747f Implement 'current' block 2016-09-02 00:48:14 -03:00
Tim Mickel c70e9759a9 Add initial SB2 importer and spec map 2016-08-31 13:56:05 -04:00
Tim Mickel 3e749fb9f1 Add loadProject, setEditingTarget, and UI emits 2016-08-31 12:28:09 -04:00
Tim Mickel 23d9999a9f Add runtime.getTargetById helper 2016-08-31 12:18:24 -04:00
Tim Mickel d4a43639f3 Add editingTarget and map block events to that target 2016-08-31 12:08:54 -04:00
Tim Mickel 08f48c5b30 Always start runtime with an empty target list. 2016-08-31 12:03:41 -04:00
Tim Mickel ba0cc0dcfc Pass along newCoordinate of Blockly MOVE events 2016-08-31 11:50:29 -04:00
Tim Mickel ad82a5cb74 Add naming mechanism for targets/clones 2016-08-31 11:50:10 -04:00
Tim Mickel 2c6722b958 Add unique ID for Targets 2016-08-31 11:39:57 -04:00
Tim Mickel b1a3026ea1 Blockly XML encoding for Blocks object
Provide two functions, `toXML` and `blockToXML`, which can be used to generate workspaces based on the VM representation of the blocks.
2016-08-31 11:38:45 -04:00
Tim Mickel c58bda1839 Record coordinate changes in block representation 2016-08-31 11:34:29 -04:00
Tim Mickel 05a5369d7b Switch Blockly listener to normal function (not closure/generated) 2016-08-31 11:34:17 -04:00
Tim Mickel aa70c1bc3b Add shadow, x, y properties to block adapter 2016-08-31 11:32:59 -04:00
Tim Mickel 8339e2769f Clean up and add documentation to sprite/clone 2016-08-31 11:30:09 -04:00
Tim Mickel 2da121d019 Add UID utility 2016-08-31 11:21:42 -04:00
Tim Mickel be06078df1 Update sprite and clones to have basic costume support 2016-08-31 11:21:32 -04:00
Tim Mickel bdc95cffc0 Rename trigger->activate/start 2016-08-29 10:26:26 -04:00
Tim Mickel 1098a06985 Various renames for hat opcodes/top blocks, allScriptsDo 2016-08-29 10:18:49 -04:00
Tim Mickel 3ccfdf3df0 Use hasOwnProperty in getIsHat/getIsEdgeTriggeredHat 2016-08-29 10:03:21 -04:00
Tim Mickel 40c90bbcc7 Add isActiveThread and simplify broadcast-and-wait accordingly 2016-08-29 10:01:31 -04:00
Tim Mickel 64b82f4dc2 Switch back j->i 2016-08-29 09:52:34 -04:00
Tim Mickel 29887e24c9 Simplify execute hat check.
In case a reporter has side-effects, we'd probably like to run hat predicates even if there is no next block.
2016-08-24 11:04:23 -04:00
Tim Mickel 4f81033762 Remove extra Thread require 2016-08-23 18:46:54 -04:00
Tim Mickel 4f2cccf279 Fix issue when broadcasting in a when-broadcast 2016-08-23 18:37:03 -04:00
Tim Mickel fe2ba2a536 Implementation of timer > _, broadcast, broadcast and wait 2016-08-23 18:14:05 -04:00
Tim Mickel b4cf64009f General-purpose hat implementation 2016-08-23 18:12:32 -04:00
Tim Mickel 39fdbaf983 Add atStackTop helper to Thread 2016-08-23 18:12:19 -04:00
Tim Mickel 43f3b59f7c Add retireThread to seqeuencer 2016-08-23 15:53:34 -04:00
Tim Mickel 94e389c8fb Refactor script glowing into its own runtime function 2016-08-23 15:47:21 -04:00
Eric Rosenbaum 5e268d57d3 scale to midi note reporter 2016-08-17 16:45:01 -04:00
Eric Rosenbaum f8e460f1b4 fixing quantize unit again 2016-08-17 12:45:06 -04:00
Eric Rosenbaum 911a8fa02e fixing quantize unit (oops) 2016-08-17 11:45:58 -04:00
Eric Rosenbaum fee8f61079 removing attempted quantization 2016-08-17 11:38:01 -04:00
Eric Rosenbaum d121a4c6fa Merge remote-tracking branch 'LLK/develop' into develop
# Conflicts:
#	src/engine/runtime.js
2016-08-16 16:41:36 -04:00
Eric Rosenbaum d5e46535e8 playing with quantization 2016-08-16 16:32:35 -04:00
Eric Rosenbaum 27184762bd fixed panner 2016-08-16 12:04:24 -04:00