A Flash Player emulator written in Rust
github.com
github.com
Two weeks ago he emailed me again to ask if I could maybe finish the project because flash is now dead, and the site is part of his legacy etc. Instead I slapped ruffle.js on it and everything is back up! It's quite slow to load, but apart from that everything looks great! Ruffle is an amazing project :)
> the term "HTML5" is widely used as a buzzword to refer to modern web technologies
This is because HTML5 includes elements like canvas, which is useless without JavaScript, but JavaScript would also be much less useful in the browser without canvas. So "HTML5" is a useful shorthand for what is made possible with HTML5-level browsers https://www.w3.org/TR/2014/REC-html5-20141028/scripting-1.ht...
Also this is post-HTML5 (HTML is now a living spec without version numbers), but the HTML standard now actually does include a bunch of JavaScript API specs, such as web workers https://html.spec.whatwg.org/multipage/workers.html#introduc...
It still doesn't connect. You can use JS to manipulate an SVG and animate it. You could theoretically just move absolutely positioned colored divs around ... Or you could draw things on a canvas. Does that mean HTML5 "is ready" or "not ready"? It has got nothing to do with it. But yaaay! Lets go! Downvote a comment, which points out a flaw in logic!
Are you not aware of the discussion about HTML5 versus Flash, or do you just disagree with using HTML5 as an umbrella term here? Even the Wikipedia article [0] about HTML5 has a section on Flash, discussing features such as sound, video, graphics and interactive elements. With "HTML5 being ready" I believe OP is referring to it being a viable alternative to Flash. There is a famous quote where Steve Jobs said that Flash is no longer needed, because there are viable alternatives to the features it provided – HTML5 among others.
[0] - https://en.wikipedia.org/wiki/HTML5#"Thoughts_on_Flash"
Consider that much of what is new in HTML5 vis-à-vis HTML4 is in the changes to its JS APIs (e.g., <canvas> is all about the JS API), and its requirement that browsers support other standards such as SVG. Actually distinguishing which component of the web stack actually has a particular improvement that you seek to use doesn't provide all that much value... what does it matter if it's really the WHATWG HTML spec that mandated it or it's the ES5 spec?
Instead, you can just call it all "HTML5" and understand that it's using newer technologies that won't work on legacy browsers, although we're now so far deep into the era that we don't have a terminology for what requires a 2020 browser versus a 2015 browser.
Ready to re-create the most amazing website in human history.
> You could theoretically just move absolutely positioned colored divs around
I would say that in practical terms, this would mean that HTML5 is not ready.
> Downvote a comment, which points out a flaw in logic!
You must be fun at parties ;)
But if you want my final verdict: I agree with others in the thread that HTML is not a good replacement for Flash. Creativity was much easier to express in Flash.
The tool was just that accessible, and the community that good.
The tool is exactly the same and it outputs html\js now.
I remember reading that the English cartoon Duggee (which also happens to be my favourite children's show by far) is 100% animated in Flash. Get this, it's a professional, prime time, internationally syndicated TV show and they use Flash because it let's the animators be more productive than anything else.
Well, turns out there's a wikipedia page on that: https://en.wikipedia.org/wiki/List_of_Flash_animated_televis... Even Family Guy started with Flash!
The design philosophy behind flash was to let you make animations and interactive content.
The design philosophy behind html/css/js/web stack is a composable system of modules that can be bundled, used to center objects, and plumb state to components.
Flash was on another level. The web hasn't been the same since it left us.
But ignoring all of that, here's a quick list of (some) categories of things I still miss from Flash:
- nested animations/clips: The recursive nature of Flash made making animations very fast. It also opened up some workflows with AS2 that were not particularly scalable, but that were excellent for fast prototyping. This is the biggest thing I miss when I open programs like Aseprite. I can't begin to describe how great it was for programming to be able to embed code inside of animation, and have the entire thing be a clip that could be embedded inside another program. Doing stuff like point-and-click games with that workflow was so fast and easy, and it was so easy to build up animations with a lot of disparate parts.
- a content-first workflow: related to the above, Flash let you switch between coding and content very quickly without worrying about stuff like imports. The fact that the content/animation and coding were so synchronized was a different way of thinking about architecture. There were problems associated with it when it came to scalability and organization, but again, just very fast to work with, very accessible, and lent itself to a certain way of thinking about prototypes that had some big advantages. When you had an idea you could be switching back and forth from code to animation constantly, you didn't have to alt-tab or export anything.
- AS2: maybe controversial, because AS3 was pretty popular and a lot of programmers were campaigning hard that it was the "correct" way to do things, but again, I want to stress the weird combination of content/animation/code was part of what made Flash special, and abstracting some of that out and having more "professional" content pipelines and different ways of doing events and organizing everything -- I think something was lost with that transition.
- Also just, in general, the animation tools were good. I don't know of an Open Source (or shared source) tool that has the same level of animation tools. Blender is doing some really compelling stuff that I'm very excited about, but Greasepencil is not a substitute for Flash, it's going in its own direction, and it's much less accessible. Aseprite is great (being able to tag frames and export data about them is handy), but it has some quirks and annoyances around the timeline controls. It's also just a lot more limited, you're basically forced to do frame-by-frame animation. There are some programs that I see animators online using that seem to be very powerful, but they're often either quite expensive or so restrictive and narrowly targeted that I'm not even willing to think about using them.
- And again, I can't stress enough: even just as an animation tool, even forgetting about games, adding scripting to animations is useful. You can have a movie clip that repeats until you hit a frame and throw an event. You can have a hand-animated scene with a procedurally animated background. And that's all really, really fast to do because the way the UX is set up you just have everything accessible at the same time.
----
I don't think it would be impossible to replicate some of the things that made Flash great, and if someone really took the time to sit down and think about what made that workflow what it was, I don't think it would be impossible to make a Flash replacement considerably better than Flash. Flash had bad audio tools, its data formats were all closed down, it wasn't really extensible, it's drawing tools could have been better, and for most of its life it was terrible if you wanted to do anything with non-vector content. There are big improvements that an Open replacement could make.
It would be an uphill battle, because the ecosystem surrounding Flash didn't just exist because of Flash. There are a bunch of different factors that went into it. And there are some APIs on the web that are still annoying. Mobile support for web games is still annoying. Controller support is not great, rumble isn't really supported. There's stuff we could do better. But the core functionality that old-school Flash needed is mostly there, and we could have (functionally) a Flash replacement today. It also wouldn't need to be a web app, you could have a Flash replacement that targeted the web for compilation that itself ran as a native app, and that would be completely fine.
Heck, you could have one that didn't target the web. Obviously I'm thinking first about the web, but if there was a Flash-equivalent Open Source prototyping tool that targeted Linux/Windows, that would also be great, and as far as I know that kind of tool also doesn't exist today.
It could be done, it would just be a lot of work to build, and tricky to get right and to get polished. The really weird reality is that as far as I can tell, no one's ever tried to build a Flash successor that actually imitated the features I care about in Flash. There are plenty of game dev platforms, some very easy to use, but very few of them have great content creation tools baked in, very few are experimenting with completely novel approaches to architecture like Flash's movie clip system.
This was just _magic_.
Godot and Unity prefabs are sort of half-way there, but the scene view being the primary interaction for editing causes the _magic_ to disappear. Flash had the timeline as the primary view; so where in scene view you drop an object into a space, in Flash you drop an animation into a timeline.
The outcome is very different. With time moving forward in the scene view, IE in Unity play mode, the objects in the world move and behave in a linear fashion. A ball rolls forward until it finds the lowest point to settle in. With time moving forward in the timeline the animations within loop endlessly. Time goes from 0 to N and back to 0 to repeat.
This was absolute _magic_ for rapid iteration.
And yes, all the rest you discussed was goodly, as well.
And it was an absolutely great cartoon animation toolkit.,
What is the status of that project, is it still active? What do you think of this project?
https://developer.mozilla.org/en-US/docs/Mozilla/Projects/Sh...
It's entirely coincidental, but I love that I share the same name. For purely selfish ego reasons I wish it had succeeded.
That's not a dig at PICO-8, it's limited on purpose. But the strength of Flash was that it was extremely flexible and exposed an architectural style that lent itself very well to prototyping. PICO-8 does have all of its tools built into the same app, but it doesn't have anything at all like a movie clip system, it doesn't even have events or a timeline. I think it just has very different goals, it's a philosophy built around having a small, self-contained, understandable system -- not around having a unique workflow.
The closest programming/architecture analogy I draw to PICO-8 isn't Flash, it's the TI-83 graphing calculator. That platform also had a lot of influence over how I learned to program, and it had similar strengths to PICO-8 in how limited it was and how that forced you to get creative and allowed you to really deeply understand what was going on in your program.
Where I do see PICO-8 getting adjacent to Flash is in the community. I think when some people say they miss Flash, what they really miss is sites like Newgrounds and the surrounding indie scene. PICO-8 does capture some of that, it's a great environment to learn to code in, and it's a fun environment to work in. I just don't think it captures any of the tooling. When I say I miss Flash, I kind of miss the indie scene, but I miss the tooling more.
I'm honestly tempted to take a swing at the "open replacement" that you described in your original post..... Though I never actually used Flash back in the day, so I'd need to do some research
An interesting point here is that Adobe Animate still exists, which (in theory, I haven't used it) still has a lot of these features. But nobody uses it for game prototyping that I'm aware of -- and not just because it's expensive or (in my case) because people refuse to use subscription software. I've seen gamedevs do their animation in Animate CC, and then export it out to Unity. So there's something going on there.
I wonder if I went back and reinstalled Flash 8, if there are parts of it I would notice that didn't age well, or paradigms that needed to be rethought. But I still feel like that kind of workflow is something we could have again, and with enough thought put into it, it could be even better. I would welcome more people thinking about this kind of stuff or trying their hand at prototyping game engines that were designed around novel workflows.
There's fertile ground in this area if someone wanted to explore it and dig into it.
If you want to discuss this further, my email is in my bio!
Can we revive Orisinal? I used to spend hours on their games: https://wsa-global.org/winner/orisinal/
I'm glad it exists, there's a lot of 2000's-era web history wrapped up in Flash.
Or is this because of trademark or something?
"USENIX Security '20 - Everything Old is New Again: Binary Security of WebAssembly"
Most of the rest of unsafe uses are to skip rust checks that have already been asserted and for FFI which is unavoidable.
There are only a few unsafe uses whose invariants are not well defined. I only gave it a quick look but I doubt they're risky.
Even if an attacker manages to exploit ruffle, I wonder what could they do in a WASM sandbox in an isolated domain.
There are some scenarios when vulnerabilities in a wasm compiled program can be harmful too though. For example the web page embedding the emulated flash applet doesn't necessarily intend to give that app full access to that origin's context. For example it could exfiltrate some api keys or other security tokens of the logged in user of the containing page.
Yeah. Just like the 10,000 other Flash implementations. The problem is that SWF is very complex format and relies on proprietary codecs. Also, there are multiple runtimes to support. Like all attempts before it, simple cases will be covered but anything slightly more complicated will never work.
Time will tell I guess.
In the end, we ended up writing our own AS3->JavaScript transpiler[1]. The Apache Flex project has since done something similar, though by the time that was done, we were done. So my skepticism stemmed from just seeing these projects come out, get some quick wins from implementing a simple subset of swf, and then just go nowhere.
But I wish them well. I hope it works out.
[1]Well, not totally ours. We used the existing Falcon compiler front-end and we wrote the emitter to transpile to TypeScript (after implementing a subset of Flash SDK that we needed).
It looks like they decided to bundle an older Chromium version that still supports Flash.
I wonder if ruffle could have saved the embarassment, and worked as a safer stop-gap measure.
Back in university, my friends and I had a team hacking on Gnash to try implementing an OpenGLES renderer for a class project. We never got it finished, due to the lack of documentation and our poor reading of C code.
It doesn't take a specific Flash Player and run it in emulation. That seemed viable to me, the OS support needed wouldn't require any specific knowledge of Flash/ActionScript which is horizontally portable from/to non-flash things.
To be honest I'm slightly annoyed whenever a github submission mentions the programming language for no specific reason.
Rust is a great tool but it doesn't matter unless you want to participate in this project.
Additionally, there are biased for and against programming languages, and I guarantee that there is a whole set of people on HN that would be interested in this project because it is a language they like. Rust means you can run this software almost anywhere and it's going to be easy to install.
I tried Ruffle but unfortunately it still doesn't support all the original Flash features, so most of the website is unusable yet. But I wait for the way when they complete it and the website can be browseable again.
Flash was banned to protect the Google, Apple, Microsoft ap ecosystems. Todays mobile CPUs are an order of magnitude way more powerful than those of 10 years ago. The performance issue doesn't apply now.
As for bugs, they can be fixed and they could have been fixed with the passage of time.
The whole agenda of aiming to replace Flash with HTML5 and CSS was a dishonest fraud from the get go.
10 years on now and still nowhere near what was available 10 years ago.
No. There was always a lot of Flash hate around, but it was tolerated because prior to HTML5 set of standards and the massive investment in JS performance, there was no way to do certain things in HTML/JS, so there was space for Flash. Post 2010 it became hard to justify Flash because you could now replicate everything Flash could do (though maybe in a more clunky way).
>10 years on now and still nowhere near what was available 10 years ago.
I wouldn't say that. There is no good reason for Flash to exist anymore. The culture also changed. The younguns who were writing browser-based Flash games in 2004, are writing mobile games today, and the browser is not a popular gaming target anymore (with some exceptions here and there).
> The younguns who were writing browser-based Flash games in 2004, are writing mobile games today, and the browser is not a popular gaming target anymore (with some exceptions here and there).
Don't those games have to be sold though app stores where Google and Apple take their 30% cut?
On the question of a "more clunky way", how come 10 years after Flash was banned, despite improvements in hardware performance, HTML/JS capabilities and development tools have not evolved to surpass Flash?
Could that be because the companies that control the apps stores are the same ones in charge of the HTML/JS standards, and even neglect to implement some of the standards when they might make games and animation development "less clunky"?
That's not true. JavaScript is still a terrible language, but if you're building a full-fledged web application, you're going to be writing it in TypeScript or Dart - and those languages are much better than AS3, and they do have sophisticated tooling.
In terms of performance, I would say that as of maybe 3-4 years ago HTML/CSS/JavaScript surpassed Flash in every browser outside of IE (IE JavaScript performance is dog-shit, and Flash is still king there).
So if you're building what was traditional known as a RIA or even a game, the HTML/CSS/JS front-end stack is much more comprehensive than Flash/AS3/Flex. I say that as someone who was a fan of Flash, and who wrote hundreds of thousands of lines of code in AS3. Our company also leveraged alchemy/FlasCC for performance as well - which was transitioned to asm.js/WebAssembly (another way that Flash was really ahead of its time). Stage3D is easily replaced by WebGL. We're actually using a dart framework called StageXL, which mimics the Flash display list API because Flash display list (API and implementation) was really sophisticated for building vector animation-based apps (games or UIs).
I can't speak to the traditional use-case of Flash providing a WYSIWYG editor for creating vector animation and how that looks like in HTML, but I think people just prefer video now because vector animation can't be hosted on YouTube and can't be monetized in the same way. So sadly, the 'vector animation culture' became 'YouTube video content culture'
>Could that be because the companies that control the apps stores are the same ones in charge of the HTML/JS standards, and even neglect to implement some of the standards when they might make games and animation development "less clunky"?
No. For one thing, it was the app store companies, like Google, and Apple, that drove the exponential improvements in HTML/CSS/JS ecosystem to make it viable. In fact, companies like Google are still pushing these standards forward and increasing the capabilities of browsers.
I think you will agree that there is nothing that can be done in Flash today, that couldn't be done in HTML/CSS/JavaScript. The reverse isn't necessarily true.
One last bit, I don't know if you remember but there was a brief period in which Adobe attempted to monetize flash. They actually wanted a license fee for the right to use the high-performance opcodes (as provided by alchemy/FlasCC) without even providing something like an app-store. They backtracked pretty quick because it was an idiotic move.
We should probably also be thinking about how browser support may continue for JavaScript in the future too. It's a matter of time until WASM reaches mainstream adoption.
Flash-the-content needs to be preserved, and Ruffle seems like a promising step towards that.