[Proof of Concept] Unity scripting with D

evilrat evilrat666 at gmail.com
Sun Jul 7 09:51:33 UTC 2019


I've been playing with Mono (.NET runtime) recently and over last 
few weeks created some basic wrapper that allows to call C# code.
So I've ported some of the Unity Engine functions, and made this 
simple game using that approach.
The game itself is a very basic "Asteroids" clone, and only 
serves as an introduction and as (crappy) system tests, it also 
might be useful to anyone new to Unity to start with API.
It is however riddled with anti-patterns and bad practices in all 
possible ways, so be aware.
At this moment only Windows x64 is supported.

Current wrapper code generation emits about 80k loc of mixins for 
a small portion of Unity API, and is far from optimal.

A bit more technical details can be found in Assets/Plugins/game 
readme file.


Sources
https://github.com/Superbelko/unity-d


More information about the Digitalmars-d mailing list