Muffin
d39a30fb23
Replace wrapAssetRequest promise argument with a callback
...
The flexibility may be useful later
2024-05-22 20:36:25 -05:00
Muffin
d69256aa2d
Replace jszip with @turbowarp/jszip
2024-05-19 21:58:36 -05:00
JeremyGamer13 and Muffin
31c9eba1aa
Add platform info ( #205 )
...
- Platform info is now stored in project.json.
- Available to extensions on vm.runtime.platform.
- When loading a project with a different platform, emit an event and wait for callbacks before continuing.
Co-authored-by: Muffin <muffin@muffin.ink >
2024-05-08 23:01:26 -05:00
GarboMuffin
8297dd4cc9
Add native loading progress tracking ( #180 )
2024-01-03 00:56:54 -06:00
GarboMuffin
dd848dbbf6
Extension storage ( #179 )
2024-01-02 23:19:51 -06:00
Muffin
7e9dab88f4
Allow serializing and deserializing infinite length comments
...
Goes along with https://github.com/TurboWarp/scratch-blocks/commit/78177be01aab589a6cbd9844d530df02258d09c2
2023-12-31 01:09:00 -06:00
Muffin
81a0382e0f
merge-upstream: initial merge of upstream/develop
...
installs & compiles but has test errors
aside from expected merge conflicts, notable changes from upstream:
- removed husky, commitlint, etc.
- removed semantic-release etc.
2023-12-22 17:25:21 -06:00
Muffin
b9e84b7db2
Implement custom font manager
2023-08-16 10:34:06 -05:00
Muffin
2158aef763
Refactor default extension URL handling
2023-07-28 23:27:14 -05:00
Muffin
1d314182a7
Remove unnecessary helper function
2023-07-28 23:02:07 -05:00
Muffin
67afd7e8e3
Add API to export blocks with extension metadata
...
Will be used to make backpack work properly with custom extensions
2023-07-28 22:59:06 -05:00
Muffin
6681b22349
Include extension list in exported .sprite3 files
...
closes https://github.com/TurboWarp/extensions/issues/767
2023-07-25 23:53:31 -05:00
GarboMuffin
7e29bbef17
Add default extension URL for compatibility with Scratch Lab animated text projects
2023-05-22 20:09:08 -05:00
GarboMuffin
eed07ed3a4
Fix incorrect JSDoc
2023-05-22 20:00:22 -05:00
GarboMuffin
d4bc61714e
Fix serializing extensions used only by monitors
2023-05-18 00:58:25 -05:00
GarboMuffin
750cd7adb1
Fix sb3 compression breaking execution order at random
...
The bug was that property keys that look like array indexes are always
enumerated by JS before other keys regardless of creation time. For now,
we will avoid using numbers when compressing projects.
This does negligibly increase the size of project.json.
Appel v1.4 went from 2257234 to 2260628 bytes, a 0.15% increase.
2023-02-17 17:42:09 -06:00
GarboMuffin
8995c6a8f2
Fix ESLint warning in tw-compress-sb3.js
2023-02-11 16:07:48 -06:00
GarboMuffin
bc24d05d0b
Parse saved extension in ScratchX (.sbx) projects
...
They are treated the same as the list we store in .sb3 projects
2022-11-21 22:54:13 -06:00
GarboMuffin
6845e17bb9
Update a comment
2022-11-05 19:10:35 -05:00
GarboMuffin
ae7526f156
Merge branch 'extensions-update' into develop
...
This adds a new mode of custom extension that runs outside of any
sandbox -- they're just <script> tags. This is disabled by default and
needs explicit opt-in. Documentation will be written later.
This also will save the URLs of the loaded custom extensions to
project.json when serializing a project. When deserializing a project,
this list can be read to automatically load the extensions. This, again,
is disabled by default and requires explicit opt-in.
A new mechanism called the SecurityManager was added to the extension
manager to facilitate these new features. This replaces workerMode and
is a breaking change.
Various other custom extension related changes were also added:
- Reject invalid URLs in loadExtensionURL
- Various cleanup and refactoring
2022-10-29 22:55:08 -05:00
GarboMuffin
dcc0d961d7
Automatically load custom extensions saved in project
...
Requires disabled-by-default security manager configuration
2022-10-22 22:02:30 -05:00
GarboMuffin
1e35432db0
Update format for saving custom extensions
...
Use a dictionary instead. Lets the VM that loads it possibly do some clever things.
Also added a test case.
2022-10-22 21:38:06 -05:00
GarboMuffin
b31ca10082
Don't serialize hidden monitors from extensions
...
Replace our specific tw_getLastKeyPressed hack with a general solution
https://github.com/LLK/scratch-vm/issues/2331
2022-10-22 18:51:16 -05:00
GarboMuffin
a4291cef17
Save extension URLs in project.json
2022-10-22 16:12:08 -05:00
GarboMuffin
458b9b7aad
Allow rotation center preservation in exported SVGs
...
Requires additional changes in scratch-gui
2022-08-01 23:50:50 -05:00
Thomas Weber
25e81a4f67
Allow importing simple ScratchX (.sbx) project files
...
Extends .sb2 importer to convert extension blocks from ScratchX project files
(.sbx) to the format we require.
This doesn't automatically load extensions; they still must be loaded manually.
2022-07-08 22:24:33 -05:00
Thomas Weber
bfc0960553
Remove tw_getLastKeyPressed monitor from all serialized projects
2022-06-17 17:09:34 -05:00
Thomas Weber
fe6bea498d
Merge branch 'develop' of https://github.com/llk/scratch-vm into develop
2022-05-23 19:01:17 -05:00
Thomas Weber
0562999ca2
Fix unsafe variable value fixer not running on lists that didn't contain null
2022-05-22 19:54:40 -05:00
Thomas Weber
02bbfba1e9
Convert more unsafe values to string when serializing variables and lists
2022-05-22 19:50:53 -05:00
Thomas Weber
eccbd33826
Convert null to "null" when serializing variables and lists
2022-05-21 18:19:56 -05:00
Karishma Chadha
4679d06ac0
Update storage and update 'loadSound' to handle null asset from storage. Track additional metadata for broken costumes: 'bitmapResolution' and 'dataFormat'.
2022-05-18 21:26:36 -04:00
Karishma Chadha
11f938f8a9
Update to latest version of storage which fixes issue where an HTML 404 page was being returned for missing asset data. Update VM to handle null assets properly.
2022-05-18 16:55:46 -04:00
Karishma Chadha
2481f28191
Rewrite missing asset skip in the affirmative
2022-05-17 16:40:33 -04:00
Karishma Chadha
4ff6288d3f
Fix typo in suggested code change
2022-05-16 16:32:58 -04:00
Karishma Chadha
1dfaa02c97
More code cleanup from PR review
2022-05-16 16:23:41 -04:00
Karishma Chadha and Christopher Willis-Ford
fd31a777e2
Code clean up from code review
...
Co-authored-by: Christopher Willis-Ford <7019101+cwillisf@users.noreply.github.com >
2022-05-16 16:07:08 -04:00
Karishma Chadha
172409c1e3
Handle rotationCenter values that might be 0.
2022-05-13 19:14:25 -04:00
Karishma Chadha
deadce3bc6
Let GQM replace broken costume data but explicitly save and serialize broken costume data before finishing loading the costume.
2022-05-11 10:57:24 -04:00
Thomas Weber
4fdc089c50
Relicense TurboWarp/scratch-vm to BSD3C, same as upstream
...
There are two copyright holders for our modifications to upstream's VM:
- Me, who obviously is okay with this
- Geotale, who I spoke to privately and is okay with this
2022-05-09 16:36:37 -05:00
Thomas Weber
e9cddbcd59
Do not allow compressed IDs to conflict with existing variable, list, or broadcast IDs
2022-01-29 13:02:22 -06:00
Thomas Weber
e2344cd467
Rename sb3 optimization to sb3 compression
2022-01-29 11:51:59 -06:00
Thomas Weber
be7cd303a5
Never store full VM version in project.json meta
2022-01-10 21:30:55 -06:00
Thomas Weber
4c5c2fe13a
Re-enable sb3 optimization, again
2022-01-09 17:43:49 -06:00
Thomas Weber
f7a6413c4c
Fix sb3 optimization breaking on type INPUT_DIFF_BLOCK_SHADOW (3) compressed inputs
2022-01-09 17:43:40 -06:00
Thomas Weber
0018f3673a
Never include full user agent string in projects
2021-11-25 15:01:28 -06:00
Thomas Weber
a752db1631
allowOptimization=false again
...
been hearing strange bug reports that may be related
2021-09-23 17:45:46 -05:00
Thomas Weber
12cbfb8365
Enable sb3 compression again
...
It has been reduced even further, which, hopefully, will mean it's finally safe to enable
2021-09-16 15:28:34 -05:00
Thomas Weber
f5b8737a73
Reduce sb3 size optimization to just block and comment IDs
...
Optimizing variable IDs is not safe due to how the backpack interacts with variables
We still see massive size reductions from this reduced optimization
2021-09-16 15:27:58 -05:00
Thomas Weber
2467c9034d
Disable sb3 optimization again
...
Mangling variable IDs can cause unexpected behaviors in the backpack, for example
2021-08-15 22:23:56 -05:00