[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Hello!
- From: David Jeske <jeske@...>
- Date: Wed, 26 May 1999 19:12:20 -0700
On Wed, May 26, 1999 at 11:11:34AM -0300, Jeroen Janssen wrote:
> >I also have a game engine based on Lua. It's a 2d sprite based engine
> >which runs under Windows directdraw and linux/X. It does not "play"
> >yet, and my recent switch into "internet startup" life has left me
> >with much less time to work on it than I had hoped.
> doesn't that sound familiar :)
> are you planning to work on it anyfurther?
I guess I was a bit misleading. You can fly around and shoot at stuff,
and if you hit it enough, it will die, and there will be a little
explosion. However, that's the sum total of the game logic, and all
the collisions are based on very poor bounding boxes right now. (I
keep stalling on that pixel perfect collision detecter). :)
I certainly plan to work on it further. There are several ideas I have
brewing in my head. We'll see when I can find the time.
> I had a look at a snapshot a time ago and I liked the gfx console part of
> your engine (haven't got the time yet to figure exactly how I could that
Actually, the overlay is the biggest hack in there. The artist (Barry
Gillhespy) came up with that console, and I just slapped it in on
top. It actually reblits the whole console every frame. Quite a
testament to the speed of hardware blitting. :)
If you mean the text-console, yeah, it turned out okay. I'm not too
happy about offloading the font rendering to GDI on windows, because
it leaks memory too much (or at least you have to be really careful
with your GDI handles to get it not to).
> I'd be interested in any (example) source code you have available
> on using lua in your game engine. (both lua as 'normal' c/c++ code).
Sure, I'll make up a tarball for interested parties. It compiles out
of the box on Linux/X. Windows is, of course, a bit more of a
challenge. I'm using MSVC 4.0, and I use its makefile system.
> what are your main ideas about using Lua in your game engine? AI?
> what do you currently have implemented with lua?
I implement object physics, AI (of which there isn't any), key
handling, Sprite definition, and all Sprite state changes from Lua.
I'm actually really happy with how all the Lua code works. The C++
side to support it is a little nasty because I started it back in Lua
2.1, before some of the nicer C-side hooks. Namely, it all deals with
a single "userdata" type because that's all that was available back
then. I'd really like to update it to use tags.
David Jeske (N9LCA) + http://www.chat.net/~jeske/ + email@example.com