Fork me on GitHub
#clojure-gamedev
<
2022-07-08
>
Trevor04:07:05

I'm real curious about Unreal.js https://github.com/ncsoft/Unreal.js It's a plugin for Unreal that looks to embed a V8 runtime that integrates with Unreal's API in an Unreal Blueprint. Many examples of using typescript exist, I wonder if CLJS would work as well? I wonder if even having a repl would be possible since it's a whole V8 runtime. Would love to hear if someone has tried this and if it worked out!

👀 1
tugh16:07:30

It would be great to have something like arcadia for unreal

xceno14:12:17

Well, I'm very late to the party here, but I tried to use unreal.js with CLJS. You have the ability to simply call into / execute js files, so compiling CLJS to JS and then using it in Unreal is certainly possible, but in the end it just wasn't wort it. I also tried to embed a jvm into an unreal executable and host clj there, which worked too, but again, the experience was rather meh. You can use libpython-clj though to script the unreal editor. So, long story short. It's always an uphill battle against the engine and you're way better off just writing C/Unreal C++ to get stuff done. There's a ton of work to do to make something like CLJ a viable scripting language. But maybe embedding a lisp like https://janet-lang.org/ would be nice. FWIW I stick to CLJ for the backend and tools and write C for Unreal