🚜 UrhoⲦαתk: Web IDE

:hammer_and_wrench: https://Urho3D-Tank.Arnis.dev/

:art: https://Tank.LucKeyProductions.nl/

Wouldn’t it be cool to have a CodePen-like Urho3D web environment for script?

  • Yes… yes it would be cool
  • No, it would be lame
  • Huh?

0 voters

@Miegamicis Any thoughts on the feasibility and implementation?

@Miegamicis Any thoughts on the feasibility and implementation?

One thing that I haven’t yet checked/implemented is the ability to do resource reloading in the web builds, but I have been thinking about it by using browser local and session storage. But don’t see any reason why it couldn’t work. Everything else is straightforward, I would estimate that it could take couple of weeks to make,

You got my attention on this, maybe I could draft some sort of POC for this. :boom:


Once functional, it should be relatively easy to extend it to an open community-driven arcade network, with the possibility to even link scripts as consecutive mini games or otherwise interconnected virtual worlds.

You have the weirdest ideas.
If the script subsystem works on HTML then the editor would be viable. But for storage, you could add auto package loading to the editor and have people share .paks here on the forums. When I made my snake pak the editor had little regarding to package support and has to load them via console.

1 Like

Ah yes, I hadn’t even thought about the editor. Indeed there’s many different possible forms, modules and levels of complexity to consider within this potential ecosystem.

Initially I think it would be neat if the Urho3D website were to host the latest version(s) of the player along with a concealable text area and/or upload button for running scripts.

Ooooh, and (it) just (gets weirder;) imagine being able to embed scripts as a onebox on the forums! :crazy_face:


Any Discourse thread could be its own (themed and curated) arcade. This would ask for a preview image - defaulting to Urho3D logo with play button - which would be the only resources loaded until it is clicked, and could possibly define the (clamped) ratio of the frame.

It doesn’t get more ambitious than this! You pass a package(?) to the web build and it downloads/load scene.xml automatically. Once the urhobox project works out you have the most portable game engine ever!


Version 0.0001
Not a designer but some ideas about the layout would be great. For now focusing only on base functionality


Next day: “Done!:wink:

Got repo?

@Miegamicis This thing needs a name. What do you think of the Tank?
It’s something that contains fish and can be rolled out because it also holds an engine. :slightly_smiling_face:

Of course, if anyone else has (better) naming suggestions, please do share them.

Next day: “ Done!:wink:

Well there’s still a lot of things that needs to be added + debugging and finetuning will take the most time I think.

Got repo?

Since I used already existing templates and libs the repo is bit of chaotic, will make it public sometime this week when there’s something useful to actually use.

This thing needs a name. What do you think of the Tank ?

Sounds good.

1 Like

btw I used this code editor https://microsoft.github.io/monaco-editor/
Looks like it has a support for LUA and maybe we can provide it for AS too.

Yea I know, seemed like a big leap though.

I can handle chaos, it’s other people’s logic I don’t follow… but I’ll just sit back, then. :slightly_smiling_face:


GitLab uses Ace.

GitLab uses Ace .

Since the editor is not yet fully integrated into the project, switching and testing out other options are easy. Already tried bunch of them but somehow didn’t notice the Ace editor. Will give it a spin.

Also I’m using VueJS to put this all together.

What a beautiful list of sponsors I’ve never heard of. :relieved:

The first tank design - by Leonardo da Vinci - was inspired by a turtle, btw. Bringing us back to the ocean.

…and Discword… :telescope:

demo: https://urho3d-tank.frameskippers.com/
Still work in progress, but at least it’s somewhat useful, very rough around the edges but maybe you’ll understand how it works sooner or later.

Don’t be shy to point out bugs!


Quick mockup:

So almost 2 weeks have passed since I and @Modanung began working on a POC for this amazing idea. There was some bumps along the
way but I believe the result for it is pretty impressive. You can check it out here: https://urho3d-tank.arnis.dev/

There are 3 seperate repositories for this tool:

  1. The actual IDE: Urho3D-Tank-Web-IDE
  2. The engine sample with required JS bindings: Urho3D-Tank-Web-IDE-Sample
  3. The Tank design repo: luckeyproductions/tank

Some technical details:

  • IDE uses ACE editor
  • Current implementation supports JSON, XML, GLSL, AngelScript file editing
  • All edited/created files are stored locally in the browsers local storage so you can save your progress between sessions
  • You can download your progress as a ZIP archive which will contain all your edited files and the actual sample so the project can be used outside the Tank.

How to use it?
As a starting point I recommend opening already existing AS samples in the editor. Once you save it (either by pressing CTRL+S or using the UI save button) it will automatically mark it as an edited file, meaning that it will be automatically uploaded to the engine and the sample will be launched.

In the same way you can change any GLSL shaders, materials and some XML, JSON files but some changes may require you to restart the sample (by using the “Restart” button in the UI)

Some problems that are not yet solved:

  • Scripts and shaders heavily rely on the built in filesystem to resolve the include statements. This means that the editor does not fully support creating new files which are linked together using the #include statements. Some changes to FileSystem are required to allow adding in-memory-only files to it. This is the main reason why LUA is not yet supported.
  • There is of course some delay once the sample has been launched to allow the browser to upload all the required assets to the engine, maybe we should implement some sort of a loading screen in the sample before all assets are loaded and hide it once it’s done

Possible future improvements:

  • Usage of multiple browser windows to allow running the sample in one of them, and the code editor in the other with the help of websockets
  • Project sharing between users - this would require some sort of backend database solution, but it’s very doable
  • Code complete for the GLSL, AngelScript and LUA files with the actual data from the engine.
  • Binary file support to allow uploading textures, models, etc. dynamically
  • File preview window - models, textures, materials

Overall I’m very happy with the results. The code might not be top quality, but this is just a POC to see if the proposed idea could work.

What are your thoughs on this? Is is usable? Would you use it? Is there something that you’d like to see in it?


I think this is an amazing project that brings a lot of attention to the project. One could done a “play.urho3d.io” where anyone can see the engine in action and start prototyping.

This is also great for sharing knowledge and debating implementations, since we can just link to a snippet from the forums, chat, discord, whatever.


Been working on this project lately and I have few updates for it:

1. Javascript files are now supported
If you add file with .js extension to the project structure, scripts are automatically launched on save.

2. Resource loading over HTTP/HTTPS (in javascript files). Currently supports all files mentioned here


3. Resource loading from base64 encoded string (in javascript files)

Module.AddResourceFromBase64("Textures/StoneDiffuse.dds", content);

4. Sample used by the WEB IDE created as a separate subsystem
All the functionality which is exposed in the IDE is also available for other platforms too, repo - Urho3D-Dynamic-Resource-Subsystem

Live demo