Lisp links thread
- teamonkey
- Sheepie Whore

- Posts: 12082
- Joined: Thu Jun 13, 2002 1:07 am 0
- XBL Gamertag: itsthetaste
- PSN: teamonkey_ca
- Contact:
Re: Lisp links thread
Brace yourself nebogeo, you've been reddited. 
Re: Lisp links thread
Ah, thankyou - I didn't notice that
Must be connected to the fact I just released a new version.
I've made some progress on using frtime with fluxus, and I've begun a simple little shoot em up - but I haven't done enough to really understand it deeply yet. I'll post some screenshots when I have them.
I've made some progress on using frtime with fluxus, and I've begun a simple little shoot em up - but I haven't done enough to really understand it deeply yet. I'll post some screenshots when I have them.
- teamonkey
- Sheepie Whore

- Posts: 12082
- Joined: Thu Jun 13, 2002 1:07 am 0
- XBL Gamertag: itsthetaste
- PSN: teamonkey_ca
- Contact:
Re: Lisp links thread
Cool. I really should have a go at compiling it for Windows at some point.
Re: Lisp links thread
Well, I've made some progress, you can move around, fire bullets and waves of enemy come toward you - the code is here:
http://www.pawfal.org/flotsam/frisbee/rocket.scm
and it looks like this:

Not very impressive, but it's not really the point atm.
I'm pestering Gregory Cooper who wrote FrTime a lot on the plt list, and it's slowly dawning on me how it works. It's very different from the imperative style - but it feels very neat and encapsulated, for example the code to describe the player's position on screen is an integral of a behaviour derived from the keyboard:
Strange but addictive.
http://www.pawfal.org/flotsam/frisbee/rocket.scm
and it looks like this:

Not very impressive, but it's not really the point atm.
I'm pestering Gregory Cooper who wrote FrTime a lot on the plt list, and it's slowly dawning on me how it works. It's very different from the imperative style - but it feels very neat and encapsulated, for example the code to describe the player's position on screen is an integral of a behaviour derived from the keyboard:
Code: Select all
(define player-pos
(vector (integral (hold (map-e
(lambda (key)
(case key
((#\a) -0.01)
((#\d) 0.01)))
keyboard) 0))
(- (integral (hold (map-e
(lambda (key)
(case key
((#\s) -0.01)
((#\w) 0.01)))
keyboard) 0)) 5)
0))
Re: Lisp links thread
paul graham has finally released arc, his new lisp, he says it's designed for exploratory programming:
http://arclanguage.org/
http://arclanguage.org/
- teamonkey
- Sheepie Whore

- Posts: 12082
- Joined: Thu Jun 13, 2002 1:07 am 0
- XBL Gamertag: itsthetaste
- PSN: teamonkey_ca
- Contact:
Re: Lisp links thread
So Naughty Dog have traditionally been a bit of a poster-child for "real-world things that have been done with Lisp" but them using GOAL to script games several years ago (and then stopping) is getting a bit tired.
But they've only gone and done it again on the PS3!
But they've only gone and done it again on the PS3!
Can't wait to see the slides.Apparently, they were missing GOAL too muchDan's presentation was
on how they used Scheme to write a significant part of their latest
game, called "Uncharted: Drake's Fortune". It's a very high profile
and high quality game that is attracting lots of attention right now
and that was very well received by critics.
They have used they own implementation of Scheme to build the game.
The Scheme code had multiple uses including:
- Generate the C++ used to describe their data structures
- Populate data tables at compile-time
- Ensure validity of data (the code generating it could interact with
their tools at compile-time)
- Write their in-game scripts that would be compiled down to bytecode
to be interpreted at run-time
In addition to programmers, designers and artists were also using
Scheme to create the game. Their presentation slides should be
available soon and will provide a bit more details.
Re: Lisp links thread
cool... seems a shame that sony bought them for their codebase then basically scrapped the lot, glad they've had the chance to write it the way they wanted to
Re:
Lisp in a single python expression (didn't copy the url but here's the code)
Code: Select all
#lisp.py
#
#An interpreter for a simple scheme like lexically
#scoped language implemented as single python expression.
#
#The interpreter is limited to the lambda special form and a
#sum function. The data types supported are positive integers
#and symbols.
#
import re
from itertools import *
iterpreter = (lambda s: (
(lambda g: lambda env, exp: g(g)(env, exp))
(lambda g: (lambda interpret:(
lambda env, exp:{
list:lambda exp:(
(exp[:1]==["lambda"]) and
(lambda env: lambda params:
(lambda nenv: [interpret(nenv, e)
for e in exp[2:]][-1])
(lambda x: dict(zip(exp[1], params)).get(x, False)
or env(x)))(env)
or (lambda pexp: pexp[0](pexp[1:]))([interpret(env, e)
for e in exp])),
str:lambda exp: env(exp), int:lambda exp: exp
}[type(exp)](exp)))(lambda env, exp:g(g)(env, exp))))
(lambda x:{"sum":(lambda params: sum(params))}.get(x, False),
reduce(lambda env, v:
(v==")" and
(lambda:((lambda i:env[:i]+[env[i+1:]])
(len(env)-env[::-1].index("(")-1)))
or (lambda:env+[v]))(),
[(i==2 and int(e[i]) or e[i]) for e, i in
[(e,sum([c*(i is not "") for i, c in zip(e, count())]))
for e in re.findall(r"(\()|(\))|(\d+)|(\w+)",s)]],
[])[0]))
s = "((lambda (a b) (sum a (b))) 1 (lambda () 8))"
v = iterpreter(s)
print v- teamonkey
- Sheepie Whore

- Posts: 12082
- Joined: Thu Jun 13, 2002 1:07 am 0
- XBL Gamertag: itsthetaste
- PSN: teamonkey_ca
- Contact:
Re: Lisp links thread
Here are the slides from Naughty Dog's GDC'08 presentation: http://www.naughtydog.com/corporate/pre ... lation.pdf
- teamonkey
- Sheepie Whore

- Posts: 12082
- Joined: Thu Jun 13, 2002 1:07 am 0
- XBL Gamertag: itsthetaste
- PSN: teamonkey_ca
- Contact:
Re: Lisp links thread
This appeared in my reddit feed today: http://erleuchtet.org/2008/03/project-o ... storm.html

Seems to be Linux only and available by SVN. Looks cool though!
perfectstorm is a real time strategy game study written in common lisp using OpenGL for graphics display and cairo for texture generation.
...
Since then, the game has grown and, with the developer count rapidly soaring up to two, includes the following features:
* User-definable units and weapons that can be plugged together
* Object-oriented very open design
* Some 20 different textures, with the possibility to add more very easily
* Fragment shaders for nice glows and flickering laser beams
* Pathfinding
* In-game developer console (aka REPL)
Future Plans
In the near future, i’d like to see the following things:
* Steering behaviours for units (currently work in progress)
* A first easily replaceable resource scheme
* Buildings
* More verbose GUI
* Dummy ai for first playtesting
Seems to be Linux only and available by SVN. Looks cool though!
Re: Lisp links thread
yeah that looks nice
Re: Lisp links thread
re: the thing i mentioned on page 6 that reminded me of Al-Jazira, i think i have found it:
http://archive.salon.com/april97/21st/i ... 70403.html
For sheer delight, though, it's impossible to beat Japanese artist Toshio Iwai's "SimTunes," in which animated "Bugz" crawl across screens you paint and make enticing rhythms and melodies as their tracks cross the color zones you lay out. It's a deceptively simple interface for a surprisingly complex syncopation tool that addictively links visual play with musical creation; you can play it free-form or use a variety of pre-supplied patterns. Part "PacMan," part light organ and part synthesizer, "SimTunes" is a pure-fun machine.
description and box picture look spot on, although none of the in-game pictures i've found look anything like i remember.
circa 1997. bloke went on to elektroplankton. i prefer the old, funny stuff... 8)
http://archive.salon.com/april97/21st/i ... 70403.html
For sheer delight, though, it's impossible to beat Japanese artist Toshio Iwai's "SimTunes," in which animated "Bugz" crawl across screens you paint and make enticing rhythms and melodies as their tracks cross the color zones you lay out. It's a deceptively simple interface for a surprisingly complex syncopation tool that addictively links visual play with musical creation; you can play it free-form or use a variety of pre-supplied patterns. Part "PacMan," part light organ and part synthesizer, "SimTunes" is a pure-fun machine.
description and box picture look spot on, although none of the in-game pictures i've found look anything like i remember.
circa 1997. bloke went on to elektroplankton. i prefer the old, funny stuff... 8)
Re: Lisp links thread
thanks koogy, that sounds cool...
just came across this joke generator written in CL
http://grok-code.com/12/how-to-write-or ... t-for-you/
just came across this joke generator written in CL
http://grok-code.com/12/how-to-write-or ... t-for-you/



