I've been fiddling with the LWJGL [1] with a view to making a game for my children. It's slow going because when I learn more about Clojure I end up changing my mind about how I want things structured. OpenGL is all new to me as well - as is game programming in general.
As part of my explorations I came across scratch [2]. It has an interesting approach where every object seems to live in its own thread. That seems to make dealing with state a lot simpler. My initial approaches have been complicated by the fact that the event loop makes handling state kind of disconnected. It would be great to be able to express things in a more linear way. This is what I'm exploring now. [1] http://www.lwjgl.org/ [2] http://scratch.mit.edu/ 2009/8/30 Elliott Slaughter <elliottslaugh...@gmail.com> > > Hi, > > I'm visiting from the Common Lisp game-dev crowd and wanted to try out > Clojure for writing games. > > I saw some JOGL examples posted in this group, in addition to the > cloggle library which wraps some JOGL functionality. Cloggle is pretty > thin right now and uses glFunctionNames as they are, so I've added > some patches to convert glFunctionNames to Lispier function-names, and > tried to Lispify the interface in general [1]. > > I think I'd be fairly comfortable writing a graphics engine with my > patched version of cloggle. What I'm not so sure about is writing the > game simulation model. > > All game simulation models I've seen used graphs of mutable objects; > I'm not entirely sure how to move to a more functional model. One the > one hand, reallocating the game world on every frame seems excessive > (even if Java's GC is fast), and on the other hand putting refs > everywhere a value could potentially change seems equally excessive > (and probably detrimental to performance). > > I just saw zippers on the other libraries page, but haven't had the > time to read it and don't know if it meets my needs or not. > > If anyone has suggestions on simulating interactions between trees of > objects (especially on the Clojure way to do it), I'd appreciate it. > Comments on my cloggle patches also welcome. > > [1] http://github.com/slaguth/cloggle/tree/master > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---