Commit graph

1449 commits

Author SHA1 Message Date
Christopher Willis-Ford
42255bbcfa Collect extension info, prep scratch-blocks data
The Extension Manager now calls an extension's `getInfo` method, then
creates `scratch-blocks`-compatible XML and JSON block data from the
results.
2017-09-06 00:57:03 -06:00
Christopher Willis-Ford
7fb7f0dc7b WIP Extension Manager
When asked to load an extension, the Extension Manager starts up a new
Worker. That worker runs the message dispatch system as well as an
instance of the new `ExtensionWorker` class, which will load the desired
extension and register it with the extension system.

Extensions, placed in `./src/extensions/*.js`, are now processed by
Webpack as separate entry points and packed into an `extensions`
subdirectory in the output.

Still to do: query an extension's information, including the blocks it
provides, and register that information with the VM, GUI, etc.
2017-09-06 00:57:03 -06:00
Eric Rosenbaum
58eaeaaf6a Add pen transparency, clamped 0-100 2017-09-05 18:00:34 -04:00
DD
caf98cb185 change order 2017-09-05 17:53:27 -04:00
DD
48fec12391 add jsdoc 2017-09-05 17:49:30 -04:00
DD
29540e705e Add updating the rotation center to updateSvg 2017-09-05 16:51:03 -04:00
Eric Rosenbaum
2b89063827 Merge branch 'patch-1' of https://github.com/Kenny2github/scratch-vm into Kenny2github-patch-1 2017-09-05 11:38:27 -04:00
Ken
3185eb27e1 Rewrote transparency block
Wrapping of the value is now handled by a new function, _wrapTransparency;
_updatePenColor now handles the transparency value;
DEFAULT_PEN_STATE now includes a transparency value (100).
2017-09-01 14:11:09 +08:00
DD Liu
bf97383b42 Merge pull request #671 from fsih/setGetSvg
Add methods to retrieve and update SVGs
2017-08-31 13:43:41 -04:00
DD
5606b067e5 More comment fixes 2017-08-31 13:41:47 -04:00
DD
7d3b9a866c Fix comment 2017-08-31 11:55:17 -04:00
DD
e5208445ac Add updateSVG to tell the renderer about the updated drawing 2017-08-31 11:43:41 -04:00
Ken
f61366643d Clamp transparency value (at least for set) 2017-08-31 09:24:41 +08:00
DD
5f5f7b1684 add get svg function 2017-08-30 14:23:03 -04:00
Ken
fc4f073526 Add glide (number) secs to [dropdown] block (#662)
* Add glide to dropdown block

* Use helper functions instead of copy-paste

* Wrong syntax for array 😒

* Aha

* Fix some Travis issues

* Aha!! This should work

* Wow, Travis is strict about spacing!

* Make requested changes

Rename function getTarget to getTargetXY
Rename parameter TO to targetName
2017-08-28 15:44:34 -04:00
Ray Schamp
f367f2d358 Merge pull request #670 from rschamp/eslint-config-scratch-4
Update eslint and eslint-config-scratch
2017-08-26 13:26:05 -04:00
Ray Schamp
32bc087bba Fix remaining lint issues 2017-08-26 13:24:10 -04:00
Ray Schamp
5113876588 Pass with --fix 2017-08-26 13:24:10 -04:00
Ray Schamp
a4d634d84d Update lint dependencies 2017-08-26 13:24:05 -04:00
Ken
8a77329c79 Fix lint issue and update maximums
Inferring from the issue, the maximum seems to be 100, not 255 (default for set is 50 and change is 10). Changed that.
A comment line was too long (thanks lint) so it has now been reworded.
2017-08-25 15:24:56 +08:00
Ken
e30e5809d1 Add new blocks
change pen transparency by (num)
set pen transparency to (num)
2017-08-25 15:07:38 +08:00
Ray Schamp
f6189903f8 Merge pull request #668 from SillyInventor/develop
Switch from parseInt to Math.floor
2017-08-24 12:24:13 -04:00
Andrew Sliwinski
d1af3ef808 Merge pull request #562 from bigeyex/feature/fix-deleted-clone-sequence-order
Fix the next thread is skipped after clone deleted
2017-08-23 09:51:38 -04:00
SillyInventor
525b601253 Switch from parseInt to Math.floor 2017-08-22 10:30:41 -04:00
Chris Willis-Ford
2665ef2b2b Merge pull request #640 from cwillisf/feature/message-dispatch
Implement message dispatch system
2017-08-17 10:57:23 -07:00
Andrew Sliwinski
6988571eb8 Merge pull request #660 from Kenny2github/patch-1
Add [string] contains [string] block
2017-08-10 10:44:01 -04:00
Ken
884e24f782 *facepalm* 2017-08-11 02:23:43 +12:00
Ken
28e61dbf48 Cleaned up 2017-08-11 01:58:59 +12:00
Ken
328514ae63 This kinda doesn’t make sense, but ok 2017-08-11 01:46:26 +12:00
Ken
963078210a Add test coverage 2017-08-11 01:37:10 +12:00
Ken
5af99566fa Wait includes is case sensitive
Made it convert to lowercase before comparing
2017-08-11 01:27:31 +12:00
Ken
3b601e8595 Add string contains string 2017-08-11 00:52:41 +12:00
Christopher Willis-Ford
b4c0cfe940 Refactor common code in {central,worker}-dispatch
Central dispatch and worker dispatch share most of their code now by
inheriting from a new shared dispatch class.

Also, the format of passed messages has been altered to make it easier
to understand in a debugger.
2017-08-09 17:30:00 -04:00
Paul Kaplan
3beebdc7be Merge pull request #657 from neurosie/variable-fix
Fix variable deserializing
2017-08-09 09:58:13 -04:00
neurosie
86e2b2338e Fix variable deserializing 2017-08-08 16:00:31 -04:00
DD Liu
21e273c6fe Merge pull request #637 from fsih/timerBlock
Fix monitor not updating every frame
2017-08-04 13:14:49 -04:00
DD Liu
58c49bd4f5 Merge branch 'develop' into timerBlock 2017-08-03 17:40:50 -04:00
DD Liu
517b396249 Merge pull request #655 from fsih/edgeActivatedHats
Activate the greater than hat block by clicking
2017-08-03 17:38:03 -04:00
DD Liu
8906aada5f words better 2017-08-03 17:32:50 -04:00
DD Liu
3ea316d04f words better 2017-08-03 17:31:34 -04:00
DD Liu
fed449876f just hat changes 2017-08-03 16:01:53 -04:00
DD Liu
ffbbbc71cc remove debugger 2017-07-31 18:09:20 -04:00
DD Liu
a48efe681e tests 2017-07-31 17:57:51 -04:00
DD Liu
cc1678fa9e Also run monitor blocks every frame 2017-07-28 14:38:26 -04:00
DD Liu
2aef75bc11 Merge branch 'develop' into timerBlock 2017-07-28 11:35:47 -04:00
TheBrokenRail
936ff04b0f Fix setting Infinity to direction (#612)
* Create rendered-target.js

* Update math-util.js

* Update rendered-target.js

* Update math-util.js

* Update rendered-target.js
2017-07-26 17:44:02 -04:00
Paul Kaplan
f2bd32a81a Merge pull request #653 from paulkaplan/sound-ids
Use sound ID instead of md5 for playing sounds
2017-07-26 09:00:00 -04:00
Paul Kaplan
fe0cb03c41 Merge pull request #652 from paulkaplan/fix-asset-naming
Use unused names when adding assets
2017-07-26 08:41:47 -04:00
Paul Kaplan
25a0e2ffaf Use new audio engine api to retreive and set sound buffers 2017-07-25 17:03:26 -04:00
Paul Kaplan
44298fd71b Use soundId instead of md5 for playing sounds 2017-07-25 12:20:32 -04:00