For anyone interested in how I gathered these: I noticed a versioning pattern from the snippets he was sharing online. I started poking around and tried to put together a git history of changes by guessing version filenames on oculus' s3 bucket.
So if you do `git log --reverse -p c9bd14f361cc4e537425f6d634367415059ad5e3..HEAD` you can see a snapshot of some of his vrscript development
That's not just sad, it is really strange. Seems enterprise would never learn from the mistakes of the past. Javascript is new Java - it's getting bigger every year, its syntax almost confusing and often feels inconsistent, sometimes it doubtlessly does utterly stupid things.
Most experienced developers dislike the language. Beginner developers also find it confusing. Days of low barrier entry to JS are long gone.
Clojurescript, Elm, ReasonML, Purescript, etc. there are multiple better options.
Yet instead of embracing PLs that can fix many of the drawbacks, big enterprise keeps insisting on it. Sigh...
Doesn't seem strange at all for a company pushing a technology for mass adoption to choose one of the most common languages which possibly has the most eyes in the world on its performance metrics, keep in mind VR has to hit framerates up to 90fps.
Facebook has already made that mistake with PHP. They are still paying the hefty price for that. Language popularity at a given time doesn't guarantee a higher ROI in the future. For the next couple of decades, CS experts will be debating over languages that optimized for programmer's productivity, optimized for performance and languages that offer correctness (probably via type systems and other mechanisms). Javascript today doesn't fit any of these categories, and although it is quickly evolving, it still hasn't shifted towards any of those sides. It has become more performant than initially, but yet not fast enough (e.g.: for native apps). Sadly the story is old, happened many times - happened to Joe Armstrong and Erlang at Ericson, that happened at MIT when they switched from Scheme to Python. It happens whenever companies ignore their engineers and arguments they make, but eagerly listen to their Marketing and Sales teams.
Honestly, I would love to see faces of those stupid imbeciles who after hearing all John Carmack's arguments that tool X is making him very productive, later tell him that he cannot use that tool.
I can't get these to run with Racket v7.2.0.3. Undefined functions are called that are not in the code in your repo. For example: set-local-client-state!
He also did a live coding demo showing off this VR scripting concept. Having such a fast iteration cycle is very compelling. Hopefully at least some Javascript version of this will exist, even though this seems like a perfect application for a Lisp.
I initially read the title as "John Carmack's VBScript Samples" and I was very perplexed as to when would have John Carmack ever had to mess around with that...
They are switching to JS from Racket, which is a shame.
It would be great if one could just do
#lang javascript
and use the same stuff. Truffle/Graal is a much better and complete and performant alternative to Racket now for implementing languages. You write a normal AST interpreter and add annotations for optimizations.
John wanted racket to be the main scripting language for vr apps that are lightweight and don't need a lot of horsepower. https://youtube.com/watch?v=ydyztGZnbNs
So if you do `git log --reverse -p c9bd14f361cc4e537425f6d634367415059ad5e3..HEAD` you can see a snapshot of some of his vrscript development