Giter VIP home page Giter VIP logo

forkphorus's Issues

WebGL renderer / Graphic Effects Not Supported

WebGL is faster than a 2d canvas and allows accurately applying filters. Scratch 3 and sulfurous use WebGL so forkphorus is overdue for this.

A 2d canvas should still be used as a fallback.

The P.renderer.ProjectRenderer interface is sufficiently abstract that this should be possible without affecting core code.

https://scratch.mit.edu/projects/78096056/

Describe what you were doing to cause this error:

Happened again. Tried to load this project: https://scratch.mit.edu/projects/78096056/
Dunno what's going on. I'm on a school chromebook so that might have something to do with it but idk. I've sent a bug report b4 and i got ur response, it works fine on my main PC but like i said idk


Project URL: https://scratch.mit.edu/projects/78096056/
Project ID: 78096056
https://forkphorus.github.io/#78096056
Mozilla/5.0 (X11; CrOS x86_64 11895.118.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.159 Safari/537.36

[object ProgressEvent]

https://scratch.mit.edu/projects/247070325/

Please describe what you were doing to cause this error:

Loaded up the game, started the level (by pressing J), and when the yellow zone visual effect went away, phosphorus crashed.

Project URL: https://scratch.mit.edu/projects/247070325/
Project ID: 247070325
https://garbomuffin.github.io/phosphorus/#247070325
Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36

Message: Failed to execute 'getImageData' on 'CanvasRenderingContext2D': The canvas has been tainted by cross-origin data.
Stack:
Error: Failed to execute 'getImageData' on 'CanvasRenderingContext2D': The canvas has been tainted by cross-origin data.
    at Sprite.touching (https://garbomuffin.github.io/phosphorus/phosphorus.js:1269:44)
    at eval (eval at scopedEval (https://garbomuffin.github.io/phosphorus/phosphorus.js:5128:12), <anonymous>:43:7)
    at Stage.P.runtime.P.core.Stage.step (https://garbomuffin.github.io/phosphorus/phosphorus.js:4924:13)

Optimize list watchers

Our Scratch 3 list watches are terribly slow and can really be noticed on any project that has large lists (such as my sorting algorithm projects), where a very significant time can be spent creating the list and keeping it up to date.

Some sounds don't play

Some sounds don't play. I think I know the cause -- audio decoding is problematic and the audiobuffernodes used by forkphorus cannot contain too much audio.

Target ES5

Target ES5 instead of ES6 to support more browsers.

https://scratch.mit.edu/projects/304369304/

Describe what you were doing to cause this error:


Project URL: https://scratch.mit.edu/projects/304369304/
Project ID: 304369304
https://forkphorus.github.io/app.html?id=304369304&turbo=false&full-screen=true
Mozilla/5.0 (Linux; Android 5.0; SM-G900P Build/LRX21T) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.125 Mobile Safari/537.36

Message: textElements[Symbol.iterator] is not a function
Stack:
TypeError: textElements[Symbol.iterator] is not a function
    at patchSVG (https://forkphorus.github.io/phosphorus.dist.js:4987:28)
    at getAsText.then (https://forkphorus.github.io/phosphorus.dist.js:5010:25)

https://scratch.mit.edu/projects/241565591/

If you quickly hit either "1 Player" or "2 player" (within 48 frames), then not all the tiles will render.

The problem is that the repeat (48) loop used to spawn the tiles does not run instantly as it does in Scratch 3.


Project URL: https://scratch.mit.edu/projects/241565591/
Project ID: 241565591
file:///C:/Users/Thomas/Projects/forkphorus/index.html#241565591
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:65.0) Gecko/20100101 Firefox/65.0

https://scratch.mit.edu/projects/78096056/

Describe what you were doing to cause this error:

Tried to run a certain project, internal error occured.


Project URL: https://scratch.mit.edu/projects/78096056/
Project ID: 78096056
https://forkphorus.github.io/forkphorus/#78096056
Mozilla/5.0 (X11; CrOS x86_64 11895.118.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.159 Safari/537.36

Message: (object.listeners.whenSceneStarts[key] || (intermediate value)(intermediate value)).push is not a function
Stack:
TypeError: (object.listeners.whenSceneStarts[key] || (intermediate value)(intermediate value)).push is not a function
    at Object.compiler.compileListener (https://forkphorus.github.io/forkphorus/phosphorus.dist.js:5641:109)
    at compileScripts (https://forkphorus.github.io/forkphorus/phosphorus.dist.js:4699:30)
    at Object.compile (https://forkphorus.github.io/forkphorus/phosphorus.dist.js:5662:21)
    at https://forkphorus.github.io/forkphorus/phosphorus.dist.js:4387:32

Missing Scratch 3 blocks

Sounds:

  • Change [effect] effect by [10] (missing in phosphorus; scratch 3 addition)
  • Set [effect] effect to [100] (missing in phosphorus; scratch 3 addition)

Events:

  • When [thing] > [10] (missing in phosphorus)

Sensing:

  • Loudness (missing in phosphorus) (pseudo-implemented, always returns -1)

Control

  • for in

Music: (extension)

  • Play drum
  • Rest
  • Play note
  • Set instrument

All other extensions except pen:

  • Everything

https://scratch.mit.edu/projects/250740608/

Describe what you were doing to cause this error:
Loading project.


Project URL: https://scratch.mit.edu/projects/250740608/
Project ID: 250740608
https://forkphorus.github.io/#250740608
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.169 Safari/537.36

Message: Unknown project type (only Scratch 2 and 3 projects are supported)
Stack:
Error: Unknown project type (only Scratch 2 and 3 projects are supported)
    at https://forkphorus.github.io/player.js:178:17

Cloud variables

Connecting to the real cloud variable server is probably a terrible idea for various reasons (behavioral differences, somehow need to get the user's auth token, etc.). However, it wouldn't be impossible for forkphorus to have its own cloud data server if it really matters. Perhaps cloud variables could be implemented as read-only at project startup or something so that you can still view cloud highscores in projects, and things like that.

Audio engine refactoring

Update the audio engine similar to how the other parts of phosphorus have been refactored.

  • ✔️ Make soundbank files all local
  • ✔️ Improve browser support (safari, no audio context, etc.)
  • Look into #3
  • ✔️ Look into #15
  • Implement Scratch 3 music blocks
  • Look into implementing other Scratch 3 audio effects
  • ✔️ Implement graceful audio decode error handling

forkphorus to APK

I think that's a thing people want.

The problem being I know nothing about android development, so that's probably not going to happen soon.

https://scratch.mit.edu/projects/310906817/

Describe what you were doing to cause this error:

Beat a level


Project URL: https://scratch.mit.edu/projects/310906817/
Project ID: 310906817
https://forkphorus.github.io/#310906817
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Firefox/68.0

Message: Argument 3 of CanvasRenderingContext2D.getImageData is not a finite floating-point value.
Stack:
trapInstanceMethod/item.obj[item.propName]</<@https://forkphorus.github.io/:209:23
spritesIntersect@https://forkphorus.github.io/phosphorus.dist.js:1412:54
touching@https://forkphorus.github.io/phosphorus.dist.js:2522:48
@https://forkphorus.github.io/phosphorus.dist.js line 5512 > eval:21:8
step@https://forkphorus.github.io/phosphorus.dist.js:5355:33

Customizable username

Right now your username is always an empty string, as if you were a signed out user. What if the user could choose their username (perhaps behind some "advanced settings" menu)? It would be kinda nice, I guess. Project creators use usernames to several things including gating features and saying things to you by name.

fetch is inconsistent and unreliable

Projects often error while loading due to networkerrors. Our P.IO.fetch should be more persistent or reliable when fetching things.

Going back to XHR might not be a bad idea, especially for onprogress (as was attempted in the io-tasks branch)

Implement Scratch 3 list stringification

Directly references a list by its block in Scratch converts it to a string.

The behavior is:

  • If every item in the list is a single character long, then return all the item joined without anything between
  • Otherwise, return all the items item joined by a single space.

Forkphorus does not implement this and you currently get the JavaScript behavior of joining all the items with commas.

Fix Scratch 2 SVG viewboxes

SVGs created by Scratch 2 have vastly incorrect viewboxes set, which can cause part of them to be cutoff very often.

TTS (text-to-speech) extension support

TTS is currently not supported, and the blocks are instead skipped.

Possible methods to add extension:

It's unclear if TTS is worth supporting as our most common niche seems to be speeding up compute-limited projects and very few of these use TTS in any significant capacity

Should add Future support to the compiler before this happens.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.