On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(+1)

It's so pretty and sophisticated!

While I plan to keep studying your template, this is my own small brain splatter from the start of this jam: https://gopher.floodgap.com/gopher/gw.lite?=tilde.institute+70+312f7e73637265777...

What kinda ideas go into a template like yours?

(1 edit)

Thank you!

I can see your code is quite interesting as well, since it intermixes C code with CL code. What kind of FFI package do you use to achieve that?

My template, on the other hand, just relies on existing bindings for three aforementioned libraries (all of which are based on the ol’ boring CFFI). The idea was to just make minimal project skeleton with choice of available C middleware libraries, with automated builds included — I kinda geek about CI pipelines and stuff 😅

(5 edits)

Ah yeah I didn't put #-ecl(error "This is ECL only") in there yet. That's a day 1 thing ;p. I'm using the low level embeddable common lisp compiler sffi package, which is basically just this:

```

(ffi:clines "#include <stdio.h>")

(let ((some 0) (variables "!"))

 (declare (:string variables) (:int some))

 (ffi:c-progn (some variables)

  "printf(\"%d %s\", #0++, #1);" ; ugh, yes, you have to ennumerate them in C

  (print `(,some ,variables))))

;;(I should double check I got the string <-> automatic cstring thing right)

```

I have found that just using the ECL compiler (common lisp but it's just a C library) is more reliably portable than the c2ffi based cffi, which doesn't have a port to openbsd for example. So we are kind of opposite, in that yours preserves behaviours against many backends right? Whereas mine is just a minimally serviceable seat-of-the-pants.

Oh cool, I didn’t know ECL allows that. It is very resourceful CL implementation ineed ☺️

Well yes, my template tries to offer the same minimum functionality (that is black screen and FPS counter with custom font) on different backends, but surely they have some differences.

Having ultra-thin ECL-based skeleton is nice too 😊 I would argue that it would also be a notch faster than any CFFI-based solution.

On the other hand you end up using a lot of void pointers. But yes, I like it a lot. I guess the ideal outcome would be to grow an ECL quicklisp package to the point where it could be included in your template, which would be a lot of work!

I would definitely have a deeper look at ECL option afterwards. Also looking forward to your entry, I hope I’ll learn a thing or two :)

(+1)

the feeling is mutual!