Scala native language binding for Godot game engine

Hello,

I have recently published my POC of scala language binding implemented using scala-native and SBT plugin.

Repo: https://github.com/optical002/godot-scala-native

Features that it supports right now:

- A gitter8 template for quick 'Hello World' setup https://github.com/optical002/godot-scala-native-template.g8

- Integrated (inside sbt plugin) godot plugin, which manages sbt builds

- Generator for all of Godot node types and built-in types (e.g. Color, Vector2, Rect2, ...)

- Support building new nodes from case classes without additional annotations for example:

case class PlayerNode(var hp: Int) extends Node2D  

- Has some of the export annotations like '@export_range'

- Supports hot reloading even after changing Node properties.

- No 'Entry' class is needed like in other language bindings, just write Nodes and other logic directly.

- No extra .gdextension file creating yourself, auto-generates it from an sbt task.

What it is lacking at the moment:

- Build time isn't the best, first initlial build can take up to like 16 seconds (There are many places for improvements)

- After the .so library gets moved into gd project scala widget in godot says it has finished compiling, but new properties does not immediately appear in inspector, since there is a hidden godot reload mechanism in place (Need to expose it via godot plugin)

- And lost of polishing up, still a 0.1.0 version

reddit.com
u/optical002 — 10 days ago
▲ 35 r/scala

Scala native language binding for Godot game engine

Hello,

I have recently published my POC of scala language binding implemented using scala-native and SBT plugin.

Repo: https://github.com/optical002/godot-scala-native

Features that it supports right now:

- A gitter8 template for quick 'Hello World' setup https://github.com/optical002/godot-scala-native-template.g8

- Integrated (inside sbt plugin) godot plugin, which manages sbt builds

- Generator for all of Godot node types and built-in types (e.g. Color, Vector2, Rect2, ...)

- Support building new nodes from case classes without additional annotations for example:

case class PlayerNode(var hp: Int) extends Node2D  

- Has some of the export annotations like '@export_range'

- Supports hot reloading even after changing Node properties.

- No 'Entry' class is needed like in other language bindings, just write Nodes and other logic directly.

- No extra .gdextension file creating yourself, auto-generates it from an sbt task.

What it is lacking at the moment:

- Build time isn't the best, first initlial build can take up to like 16 seconds (There are many places for improvements)

- After the .so library gets moved into gd project scala widget in godot says it has finished compiling, but new properties does not immediately appear in inspector, since there is a hidden godot reload mechanism in place (Need to expose it via godot plugin)

- And lost of polishing up, still a 0.1.0 version

u/optical002 — 12 days ago
▲ 17 r/scala

I made a simple implementation of CE inside Rust

Hello!

Today I had a though while deepening my understanding in rust, that maybe it could work if we had from cats typeclasses in rust. Came up with a couple of ideas for basic typecalsses like Semigroup, Functor, Monad.

Previously found that someone had done a macro which mimics the haskell's do notation, and was thinking maybe it's possible to do that with my now typeclasses to write for comprehension from scala, and it was pretty similar, which I was surprised.

Afterwards I chatted with claude about possibilities, would that work, and he came up with an interesting anwers that it might. And started evaluating how long would it take me to be able to make a librario which can run similarly to CE IOApp, and yeah, it's way too long, I have ctwo little children a job and other game dev project which I want to do.

So based on that I decided to embrace the claude and see what it can do, mostly it did pretty fine, had to do some fine tunning and direction and guided it via implementation of what to do. Which took about 4-5 hours to complete fully.

So now I am able to write an IOApp in rust with for comprehension!

I was thinking so what about the preformances, so I came up with a single benchmark to test against rust most popular async library 'tokio'. So I did a prime number calculation.

Surprisingly results were the same 8ms vs 8ms and after increasing the count of primes to calculate by 10 times, I got my cats implementation on average ran 210ms and tokio 221ms, which is a small gain, but still got surprised there as well!

I got everything in this repo https://github.com/optical002/rust-cats

But though I don't know how I feel about it's syntax, in here you can check how benchmark was implemented to see the rust CE syntax https://github.com/optical002/rust-cats/blob/main/benchmark/src/bin/prime_sieve_cats.rs and the 'count_primes_in_range' fn has similar thing to tagless final from scala.

What do you guys think about this, does this look promising and is worth investing time, or it looks too verbose for rust and not worth continuing?

I prefer the scala syntax TBH now that I'm looking at it, but this does not have a GC and no JVM cold start...

u/optical002 — 27 days ago
▲ 1 r/INAT

[RevShare] Looking for a 2D artist for ‘Merge 2’ game

Hello, I’m a game developer and I can build pretty much anything, the only thing I lack is art and animations.

I did a market research on merge 2D games on mobile, and I’ve gathered data around what it should be. Everything at the moment is in my head, but I can document it pretty easily.

I will have a list of art/animations required to produce this game.

If this goes well I’m thinking of starting a mobile game company going forward, and you would be a cofounder for that company which we could build up from ground up.

I have worked for 7+ years in professional mobile game development as a developer, game designer and everything else. I pretty much know the ropes of how to get it started.

DM me or reply in the comments if you are interested in building a Merge 2 game and a company out from it!

reddit.com
u/optical002 — 1 month ago

A lightweight Lobby/Leaderboard/Matchmaking API

I'm thinking of building an API which would allow you to create lobbies, handle matchmaking, and track leaderboards — all in one lightweight service aimed at indie devs.

It would have features like:

* Create and manage lobbies and groups

* Group and player matchmaking

* Define custom matchmaking rules (skill-based, region, ping, etc.)

* Leaderboards with configurable scoring

* A web interface to inspect live state, and modify data directly with admin access

It would be **self-hostable** — so no vendor lock-in, you own your data. But for those who don't want to manage a server, there'd also be a **hosted version** available.

**Two questions:**

* Would you use something like this?

* How much would you pay per month for the hosted version?

reddit.com
u/optical002 — 1 month ago