Defold Popularity - Discussion

I totally agree and you all know I prefer Lua :grin: Just letting you know that some people are seeing it as a stoper. As we already have Typescript and Haxe extensions it might be just worth taking care of them :wink:

Something like you stated above was also mentioned as the most important reason for people to choose engine like Unity - there are proofs that it is battle tested. They are seeing that the engine has a lot of flaws BUT people made games with it, so I can. It doesn’t matter someone spent a ton of work to accomplish a thing BUT it is possible to do this in that engine :grin: a really strong conviction!


Haxe is quite old and Motion Twin used it for years to produce very popular Flash games. Others did as well. It does show in part that a single notable success can uplift a gamedev tool more. If we have one of the next Mincraft / Terraria big games made with Defold we would suddenly have hundreds to thousands of new people a day trying to learn Defold. This kind of thing will happen eventually. :slight_smile:

Part of the reason Lua seems to get bashed is because it’s old and has been bashed a lot, so just like Java people repeat the bashing without actually have real and recent experience with it. Minecraft was made with Java and without a doubt it being made with Java is what part of what enabled its success. World of Warcraft has all of its UI powered by Lua for years, and that too is an element in its success, because the users can make the core game better for the audience in ways those kinds of mods/plugins enable.


We have @aglitchman! :heart_eyes:

And also I was following progress of Chemaria by @gamzwithjamz, but he decided to pause the project for now :frowning:

Wow! And a lot of other games:


A few problems I’ve fixed in the hxdefold repo already. Other issues are more fundamental. Haxe being not the first class language results in an additional step compiling to Lua, and the compiler is not perfect, there are a few edge cases where the generated code becomes wrong, generating syntax errors or runtime errors. If you are good with Lua, it’s easy to see a workaround. Another issues is inability to use breakpoints and debug Haxe code. However you can debug the generated Lua code. But all these issues are outweighed by the benefits Haxe provides. Static typing is a very powerful tool to write vast stable code, which is crucial on big projects. Compared to Lua, I almost never get runtime errors. Navigating Haxe code is a breeze, compared to Lua, where you have to basically search by keywords in all files, especially if you are using the messaging system. Especially if you are reading someone else’s code. Full autocomplete is a bliss.
Plus Haxe has a very nice collection of game oriented libs.
What worries me a bit is that Haxe has integer type, but Lua in Defold doesn’t, maybe I would encounter a bug about that in the future, maybe not.
If Defold provides better C++ API, it would be possible in the future to compile Haxe to C instead of Lua, gaining stability and performance (and loosing a few hundreds of KB if Lua runtime is excluded). Or integrating the Hashlink Haxe VM as an extension.
Unity has a similar tool that compiles C# code into C.

Haxe is not popular only because of Dead Cells. It’s popular because of the Flash legacy and many other frameworks using it. Dead Cells uses the heaps engine, which I am currently using on my job, it’s a very interesting, but niche engine, very unpopular. I think I am the only person from the community in a few years who managed to run heaps on Android, because the old sample Android project was outdated and never finished.

So to sum it up again. I’d really like to see in Defold a statically typed language as a first class language and a friendlier IDE, easy to extend by community, like Godot’s IDE.


Thanks Sergey for this summary!

Are these problems in the translation from Haxe to Lua+Defold something that can be solved or is there no 1:1 translation in some cases?

Yes, I guess this is a problem. How does it work for other languages that Haxe transpiles to? Is there a symbol map or some other lookup from the transpiled code to the original Haxe code?

What would be required here? Additional editor script hooks?

We’re moving slowly on the path of exposing more of the engine SDKs but I’m not sure if we’ll ever expose all of it to the SDK. Maybe.

1 Like

Maybe. I’ve pointed out a few in the Haxe repo issues. Please take a look

Unfortunately I don’t know. I’ve been working only with Haxe-Lua and HashLink so far.
Looks like source map is only implemented for JS so far

At the moment I am pressing a hotkey in VSCode to generate the code. Ideally there should be a hook to build the Haxe source when running with the Defold (CMD-B), I think at the moment build hook is only working when bundling?

1 Like

Another idea popped up in my head is to collaborate with the author of the Gamefromscratch YouTube channel, he likes Defold and has many subscribers. A good channel of promotion.


I am pretty sure the content is highly influenced by community and GFS already covered Defold (but it was a while ago and surely things are outdated) - I don’t know how to convince GFS to cover it again :smiley: If there will be a small, new, very interesting feature - I am sure it will be noted on the website and in Discord, like partnership with Rive was, but also it should be huge and interesting enough to make a video about it :smiley:


Like an interview maybe. QnA session.


I think this is an excellent idea! I am here thanks to Gamefromscratch!


:blush: I’ll do my best! But the game won’t be another Minecraft clone because the clone won’t bring Defold any popularity.


Defold needs to have fulfilled profiles with up-to-date information on software review websites. They have very high visibility in search engines results.


I emailed Mike yesterday after I saw the video covering Rive and Defold to offer my participation in an interview or Q&A session. What a strange coincidence!


Pitching in to the transpiler conversation with a few of my own thoughts:

  • I would love types in Lua in Defold. Optional types (not having to type my whole project in a go) and being as close to Lua as possible is preferrable. Teal seems like the closest fit to this.
  • The main friction point to using a transpiler in Defold is the fact that it breaks the “zero-setup” paradigm of opening the editor and just building. Using external tools complicates things too much, especially for the non-technical people that might open the project. And I would prefer to avoid commiting transpiled code to Git.
  • Transpiling in a build time hook is also a bit unacceptable in development, since it could take a long time to transpile the whole project and we do small incremental changes between Cmd+B’s quite often. Some sort of incremental compilation for during development is needed. Having built-in support for that in the editor/bob would be great.
  • I personally like the way Teal hooks into the package loader and makes it that you can just require Teal files like usual. That kind of workflow would be great in development. I think that could be made to work by sticking Teal files in custom_resources. The problem is that custom_resources doesn’t support a glob like **/*.tl and would force me to keep all of my .tl files together, which sucks. This also doesn’t solve not being able to write .script/.gui_script, etc. files in Teal (would require an additional require()). Some research is required into how Defold loads .script files.

I will like to share my own views on this interesting topic.

First of all, I doubt that the choice of the language has much to impact how good an engine is for game development. Two prominent examples in this case that come immediately to my mind are

  • Game Maker : The inbuilt language of Game Maker (GML), though easy, lacks several features . I have also read several posts that says that GML teaches practices that are not effective in the long run. (Though I’m not sure on this one)

  • Cocos Creator : This is another popular engine that uses Lua, and is very popular when it comes to developing games for mobile and Web.

Although I do agree that Defold would greatly benefit from the presence of a typed language. Teal looks like a great option for this

Secondly, I also agree with this quote that Defold definitely needs to focus on Desktop platform more.

Third and a very important point is that Defold needs some drag ‘n’ drop solutions that can drastically improve game’s looks, like Unity’s Post Processing Stack especially since new comers do not want to get their hands dirty in Render Scripts and Shaders.
A possibility addition for an inbuilt solution for 2D and 3D Lights will also second this.

Fourth Point, which has already been raised many times before in this discussion is the presence of Video / Written tutorials for Defold would be a great plus point for extending Defold’s userbase.

This is a great idea !

Fifth and the most important point that I have felt is that Defold would greatly benefit from would be Editor Extensions. The Editor at its its core is written in Clojure, which is an entirely new topic to learn if you wish to extend the editor. It would be good if there was a way to extend it using NEs or Lua. The community could then build upon it to implement some attractive features like animation editor, state machine editor and so on, which are very attractive to beginners


Thanks to everybody commenting and discussing how to make Defold more popular! We really value all of your opinions and while we do not answer each and every post I can assure you that the feedback provided here is discussed and we will turn some of the feedback into actionable items for our roadmap.

Again, thank you so much Defold community! :heart:


This is a major point that I forgot about. I’ve seen a lot of interest in playing with the render script, adding lighting, playing with the camera, etc. The current philosophy is to only provide the most foundational features to users out-of-the-box, with extensions available in the asset portal.

Although I personally really like this philosophy, I do think it forces issues like dynamic lighting and other “extremely common” features from being accessible to your everyday Defold developer. This is probably also a tempting reason to go with some other engine. If other engines offer an easy solution to these more common problems, then I’m sure newcomers would rather go for the easy solution rather than try to implement them manually in Defold.


I agree, but I also believe that this could easily be solved with ad-hoc starting templates, like the 3d one already in Defold (that does include Rendercam for example). This is more maintainable even by the community and would ease new comers into the engine.


For those interested in being up and running as soon as possible, TypeScriptToLua looks like a better solution: it comes with type definitions ready for serveral APIs along with an exceptional intergration with VSCode, whereas tl still lacks both…

…still, I agree with you that on the long run tl would be even better, because while TypeScript has been built with JavaScript in mind, tl is (and always will be) pure Lua. To see what I mean we can just take a look at TypeScriptToLua docs, which spend two whole pages on how to tackle with differences between Lua and JavaScript. All of those ‘caveats’ just don’t exist with tl.

But, in my humble opinion, the most pragmatic solution would be turning Luanalisys into a CLI tool. This way every developer interested in getting type safety in Lua will be able to do it by just adding comments to the existing code and then running the tool as he sees fit, regardless of the engine/editor he’s using.

In short:

  • no extra source files (just comments on the existing ones);
  • no need of explicit support from code editors (run directly in the console or through an editor script);
  • as portable as a CLI tool could be.

That’s it!


Probably the only way to make Defold a real alternative for professional developers (who know how to make money with games but need efficient and optimized tools to build them) - and then for hobbyist developers who want to follow them.

Personally, I decided to use Defold 2 months ago because
1/ Top performance on mobile (because mobile first), lightweight/clean, etc.
2/ Great forum / community
3/ A few examples of successful mobile games (Puzzle Pet Saga and Family Island) => not much but still waaaaaay better than nothing (Godot => nada)

=> In this list, games made with Defold should be sorted by “success” (sorry for hobbyist developers), or at least popular/profitable games should be more highlighted (with “impressive” figures like the number of downloads, etc.), so potential Defold users wouldn’t wonder if there are successful games made with Defold.