News for hackers. Stuff that matters.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by jimbob45 on Tuesday January 18, 2022 @06:30PM (#29987681)
I’m floored and amazed. I’ll certainly look into contributing but…how did the devs acquire a language spec for GOAL? My understanding was that that was the major blocker of these types of projects for years.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by corysama on Tuesday January 18, 2022 @06:34PM (#29987721)
OP also posted https://blog.jakspeedruns.com/opengoal-project-update-septem... a while back. It has a section on "How is this possible?"
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by DylanBohlender on Tuesday January 18, 2022 @06:41PM (#29987802)
Whoa, that is crazy!

TL;DR for folks is that they left a lot of debug information in the build. The C code was compiled with no optimizations (and included debugging symbols), and GOAL uses a string-based table for global functions/variables/types, so they're starting with all those for free. Plus they don't think the GOAL compiler did too much tricky-to-undo optimization either.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by monocasa on Tuesday January 18, 2022 @06:44PM (#29987822)
It looks like they don't have a full goal spec, but are relying on the copious debug and runtime type information, as well as the simplicity of the original goal compiler (and arguably the simplicity of lisp itself) to come up with something close that's semantically equivalent.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by kayamon on Wednesday January 19, 2022 @02:03PM (#29998394)
There's a lot of snippets posted over the years on various forums. Nothing much, a few pages to get a hint of the syntax and the basics. Once you've picked apart the loader/runtime[1] the dynamic nature of the Lisp runtime system allows the system itself to hint a lot at how things originally went together. (e.g. type information is always present, state machines are explicit and easy to spot)

[1] http://www.codersnotes.com/notes/disassembling-jak/ (my old article this is based off)

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by rgbrgb on Tuesday January 18, 2022 @06:35PM (#29987732)
Just curious... what makes you look at this and want to contribute? I'm interested in why people do these unlicensed emulation projects at all and it sounds like you have at least one answer as your motivation.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by ensan on Tuesday January 18, 2022 @06:55PM (#29987931)
This is not an "unlicensed emulation project". In fact, it's not emulation at all.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by jimbob45 on Tuesday January 18, 2022 @06:47PM (#29987849)
As far as I know, GOAL/GOOL remains the only time Lisp has ever successfully been used in a video game. Given Lisp's near-mythic status of productivity, it at least piques my interest to see how ND might have used it creatively in the codebase.

That and I've always wanted to check out the language after Andy Gavin (ND founder) talked it up on here [0]

[0]https://news.ycombinator.com/item?id=3152131

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by dleslie on Tuesday January 18, 2022 @07:36PM (#29988300)
Abuse, a 1996 PC side scrolling shooter, had a good chunk of it written in lisp.

https://github.com/antrad/Abuse_1996/tree/master/data/lisp

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by pcwalton on Tuesday January 18, 2022 @08:14PM (#29988587)
Zork ZIL was pretty Lispy (example at [1]). Whether it qualifies as "a Lisp" depends on your definition.

[1]: https://github.com/MITDDC/zork/tree/master/zork

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by anthk on Wednesday January 19, 2022 @09:43AM (#29994166)
Zork's ZIL targeted the Z-machine, now implemented on everything.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by DonHopkins on Tuesday January 18, 2022 @10:48PM (#29989747)
Zork ZIL was based on MDL, which was a Lisp derivative with "More Datatypes than Lisp", developed at the Dynamic Modeling Group (on the MIT-DM PDP-10 running ITS) by MIT's Project MAC (which the MIT AI Lab split off from).

https://en.wikipedia.org/wiki/MIT_Computer_Science_and_Artif...

https://en.wikipedia.org/wiki/Incompatible_Timesharing_Syste...

HN discussion: Zork source code, 1977 (github.com/mitddc)

https://news.ycombinator.com/item?id=23108626

https://github.com/MITDDC/zork

About MDL:

https://en.wikipedia.org/wiki/MDL_(programming_language)

>MDL (programming language)

>Paradigms: Multi-paradigm: functional, procedural, reflective, meta

>Family: Lisp

>Designed by: Gerald Sussman, Carl Hewitt, Chris Reeve, Bruce Daniels

>Developer MIT Project MAC

>First appeared: 1971; 51 years ago

>Final release: 105 / 1980; 42 years ago

>Typing discipline: Dynamic, strong

>Scope: Static, lexical

>Implementation language: MDL

>Platform: PDP-10, VAX, Apollo/Domain

>OS: ITS, TENEX, TOPS-20, BSD, AEGIS

>License: Open-source

>Influenced by: Lisp

>Influenced: ZIL, Planner, Scheme, Common Lisp, Java, Prolog, Smalltalk; actor model, interactive fiction

>MDL (Model Development Language, or colloquially also referred to as More Datatypes than Lisp: or MIT Design Language) is a programming language, a descendant of the language Lisp. Its initial purpose was to provide high level language support for the Dynamic Modeling Group at Massachusetts Institute of Technology's (MIT) Project MAC. It was initially developed in 1971 on a PDP-10 computer on a time-sharing operating system named Incompatible Timesharing System (ITS). It later ran on TENEX, TOPS-20, BSD, and AEGIS.

>The initial development team consisted of Gerald Sussman and Carl Hewitt of the Artificial Intelligence Lab, and Chris Reeve, Bruce Daniels, and David Cressey of the Dynamic Modeling Group. Later, Stu Galley, also of the Dynamic Modeling Group, wrote the MDL documentation.

>MDL was initially called Muddle. This style of self-deprecating humor was not widely understood or appreciated outside of Project MAC and a few other early citadels of information technology. So the name was sanitized to MDL.

>MDL provides several enhancements to classic Lisp. It supports several built-in data types, including lists, strings and arrays, and user-defined data types. It offers multithreaded expression evaluation and coroutines. Variables can carry both a local value within a scope, and a global value, for passing data between scopes. Advanced built-in functions supported interactive debugging of MDL programs, incremental development, and reconstruction of source programs from object programs.

>Although MDL is obsolete, some of its features have been incorporated in later versions of Lisp. Gerald Sussman went on to develop the Scheme language, in collaboration with Guy Steele, who later wrote the specifications for Common Lisp and Java. Carl Hewitt had already published the idea for the language Planner before the MDL project began, but his subsequent thinking on Planner reflected lessons learned from building MDL. Planner concepts influenced languages such as Prolog and Smalltalk. Smalltalk and Simula, in turn, influenced Hewitt's future work on the actor model.

>But the largest influence that MDL had was on the software genre of interactive fiction (IF). An IF game named Zork, sometimes called Dungeon, was first written in MDL. Later, Reeve, Daniels, Galley and other members of Dynamic Modeling went on to start Infocom, a company that produced many early commercial works of interactive fiction.

>In 1980 Marc Blank and Joel Berez adapted the MDL language to create a subset called ZIL (Zork Implementation Language) which was used extensively by Infocom to create their award winning games.

     <DEFINE EXIT-TO (EXITS RMS)
             #DECL ((EXITS) EXIT (RMS) <UVECTOR [REST ROOM]>)
             <MAPF <>
                   <FUNCTION (E)
                      #DECL ((E) <OR DIRECTION ROOM CEXIT NEXIT DOOR>)
                      <COND (<TYPE? .E DIRECTION>)
                            (<AND <TYPE? .E ROOM> <MEMQ .E .RMS>>
                             <MAPLEAVE T>)
                            (<AND <TYPE? .E CEXIT> <MEMQ <2 .E> .RMS>>
                             <MAPLEAVE T>)
                            (<AND <TYPE? .E DOOR>
                                  <OR <MEMQ <DROOM1 .E> .RMS>
                                      <MEMQ <DROOM2 .E> .RMS>>>
                             <MAPLEAVE T>)>>
                   .EXITS>>
The MDL Programming Language Primer, Michael Dornbrook, Marc Blank:

http://publications.csail.mit.edu/lcs/pubs/pdf/MIT-LCS-TR-29...

The MDL Programming Language, S. W. Galley and Greg Pfister:

http://ifarchive.org/if-archive/programming/mdl/manuals/MDL_...

The MDL Programming Environment, P. David Lebling:

http://ifarchive.org/if-archive/programming/mdl/manuals/MDL_...

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by rgbrgb on Tuesday January 18, 2022 @07:03PM (#29988020)
Cool, thanks for sharing that.

I had no idea Andy Garvin was on hn, but makes sense :)! I had a vague memory that Super Mario 64 also used lisp and when I googled, I found him again [0].

You've likely seen this, but I recently watched and loved this extended interview with him about making Crash Bandicoot [1]. Really made me want to look more into making video games.

[0]: https://news.ycombinator.com/item?id=2474833

[1]: https://www.youtube.com/watch?v=pSHj5UKSylk

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by Jach on Wednesday January 19, 2022 @07:55AM (#29992973)
Yeah it's rather amazing what Lisp applications in the 90s contributed to. https://en.wikipedia.org/wiki/N-World is the software mentioned in the comment, the modern equivalent being Blender. The Credits section of that page has some great classics like SM64, FF7, Banjo-Kazooie...

It also had great tutorials and documentation: http://www.aaronjamesrogers.com/misc/nworld/N-World-Intro.ht...

It's a shame that its successor Mirai https://en.wikipedia.org/wiki/Mirai_(software) just kind of vanished. Its main claim to fame is Gollum's face. Chronologically it's not that different from Blender, which also imploded around the same time in the early 2000s, but Blender was able to go open source and survive and have another 20 years of development to get where it's at today. I don't know that the world would look all that different if Mirai had been able to take a similar path, but at least there'd be a cool modern 3D modeling tool in Lisp.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by mbrodersen on Wednesday January 19, 2022 @08:03PM (#30002859)
I worked on Banjo Kazooie and the claim that N-World was used for it is incorrect. We used Maya for all modelling. They did a demo to the BK team once and it went really badly for them. What they demoed to us was so far from being competitive with Maya that it was almost laughable.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by Jach on Wednesday January 19, 2022 @09:12PM (#30003492)
Thanks for the correction! I guess another instance of Rare just doing it better than Nintendo ;) I've been trying to track down any source for the original rumor without success, the random IP seems to have made it up. Did you ever get to see much of their later Mirai tool? Though I would also believe Maya was quite far ahead at that time too.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by mbrodersen on Friday January 21, 2022 @08:42PM (#30032299)
No the demo went so badly for them that we never invited them back. I kinda felt sorry for them. They had no clue how uncompetitive they were compared with the tools we were already using. One of the two demo guys kept going on about how better it was because it was using Lisp. While also acknowledging that it was missing pretty much all the features we needed. The “it’s easy to implement yourself because Lisp!” argument was laughable given that Maya already had the features we needed and used every day.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by Jach on Saturday January 22, 2022 @03:31AM (#30034827)
> They had no clue how uncompetitive they were compared with ...

Sadly not that uncommon in Lisp advocates for a number of different things even today... though I think that's been slowly changing as more Lispers either become aware of what's out there, or come with experience of what's out there and bring that knowledge with them to Lisp. The reverse direction seems to happen at least as slowly -- I've commented before that a JRebel setup is very close to bringing the still largely unique interactive development mode of Lisp over to the Java world, but it's also in important ways not fully there and may never be. Meanwhile many other languages don't even care about that development style at all.

> The “it’s easy to implement yourself because Lisp!” argument was laughable

I guess this would be kinda analogous to when Blender first added Python support, if they told everyone to just do expected things themselves. It may be true that such-and-such task is relatively easy to implement (if indeed it's possible to do at all without changing something about the application itself) but it's also just a terrible thing to focus sales on when the value seems like it'd mostly be measured by how useful the tool is to non-programmers.

I hadn't really looked much at the "Wide Open World" doc on the archive since it's not mentioned in the other docs except vaguely in like one spot I had to search for, but if a customer had heavy scripting needs to accomplish things not already provided or easily done with the graphical tools, now the customer's not only being sold on a graphics tool but also on learning to program in Lisp using their bundled xemacs. And as you note it's even worse when that work is already done in another tool that can't be integrated with. Though I see they provided an FFI so there could be a possibility of integrating C code the customer or others wrote. If a customer was expecting to have to do a bunch of new custom stuff regardless of tool maybe it'd have made more sense... But now at least I have an additional insight into why they weren't very successful.

I'm appreciating anew a lot of things the last products I worked on got right in terms of providing a good enough and frequently improving out of the box set of components and workflows while paying some attention to competitors to see what key things were lacking on either side, while streamlining development and deployment of custom components, and also providing a platform for customers to share their own custom work with each other either openly or by putting a price on it.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by mbrodersen on Saturday January 22, 2022 @09:18PM (#30043005)
Not only that but Maya already supported custom code. I wrote a few plugins for Maya to export models and animations to our own optimised-for-N64 format. I wrote it in C (BK was all written in C). Maya also had (has?) a scripting language (called MEL I think?) that other teams used. It apparently made it super easy to do even advanced stuff. So given that, the “Lisp advantage” made even less sense. I must admit (again) that I felt really sorry for them. It is hard to watch somebody failing that badly doing a demo. But I will also say that making a sales call without first figuring out what they were up against (Maya) was a bad move. They had no clue what they were competing against. I think you are right that the “Lisp is awesome” thinking let them down the wrong path.
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by p_l on Tuesday January 18, 2022 @08:47PM (#29988829)
GOOL-level code used to be maybe not common, but also not uncommonly implemented in some form of a lisp (these days it's pretty much all Lua). Naughty Dog continued using Lisp for those purposes at least throughout Uncharted series.

There are some indie games done in Lisp, including at least one small Visual Novel released on Steam and another currently in development (2d platformer called "Kandria").

Several games, both indie and not, used Lisp as development tool - this includes games like "What Remains" (hn link: https://news.ycombinator.com/item?id=20930986 ) as well as numerous tools used IIRC at Nintendo.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by bigbillheck on Tuesday January 18, 2022 @06:56PM (#29987940)
> As far as I know, GOAL/GOOL remains the only time Lisp has ever successfully been used in a video game.

'Abuse' had a substantial lisp component.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by mbrodersen on Wednesday January 19, 2022 @07:59PM (#30002820)
> Given Lisp's near-mythic status of productivity

I have seen a lot of claims of this but no real evidence? And I know Lisp quite well (having implemented my own versions of Lisp for fun). If Lisp truly is way more productive than other languages, why haven’t we seen lots of Lisp software out-competing software written in other languages? Surely a few Lisp guys could outcompete everybody else if Lisp is as super productive as claimed.

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by s-lambert on Tuesday January 18, 2022 @11:38PM (#29990027)
Lisp was used for some code for the original NES, there was a presentation about it but it looks like only the reddit thread[0] linking to it still exists.

[0] - https://www.reddit.com/r/programming/comments/6e6zwn/i_had_n...

Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by marcofatica on Tuesday January 18, 2022 @07:20PM (#29988177)
I believe one of the generations of Age of Empires has it's AI written in lisp
Re:OpenGOAL: Port of Jak and Daxter, written in GOAL, a cust... by 60654 on Tuesday January 18, 2022 @07:33PM (#29988281)
Age of Empires 1 had AI scripts that were written as production rules in a very Lisp-like syntax. (You can still find some online.)

Not sure if they integrated a full Lisp or Scheme system, but since the rules were not arbitrary source code, nor doing unification, etc., they could have just hand rolled a custom reader, and written the rule engine itself in C...