Wolfire Development Blog - Part 3!

Anything related to Wolfire Games and/or its products
David
Project Leader
Posts: 1995
Joined: Wed Nov 19, 2003 10:45 pm
Contact:

Post by David » Fri May 09, 2008 2:47 pm

The evolved movement thing is mostly for me to practice using machine learning techniques, and also see what crazy movements a ragdoll might come up with without any of our assumptions about how humans should move.

User avatar
Renegade_Turner
Gramps
Posts: 6942
Joined: Tue Sep 27, 2005 11:59 am

Post by Renegade_Turner » Fri May 09, 2008 11:03 pm

This might be REALLY asking for it, but how does it work? You repeat the process a number of times until the ragdoll figures out the best way of moving with the constraints you've placed on it?

David
Project Leader
Posts: 1995
Joined: Wed Nov 19, 2003 10:45 pm
Contact:

Post by David » Sat May 10, 2008 12:33 am

All genetic algorithms work by starting with a base population of random genotypes, and then evaluating their fitness, and populating the next generation with random variations of the most fit. In this case the genotype is a graph of oscillators that can be connected to the ragdoll joints, and the mutations change the oscillator parameters or the connections. Fitness is determined by finding how far they move, and dividing that by how much energy they use to get there. Each generation I pick the 20 best and fill the next generation with these winners as well as 4 mutated variations of each one.

User avatar
Renegade_Turner
Gramps
Posts: 6942
Joined: Tue Sep 27, 2005 11:59 am

Post by Renegade_Turner » Sat May 10, 2008 8:22 am

Right. I'm not going to pretend like I completely understood that (my mind's too feeble), but I understood enough to know what was going on. Sounds cool. lol

User avatar
Makrond
Posts: 498
Joined: Mon Jun 25, 2007 11:34 pm

Post by Makrond » Tue May 13, 2008 7:14 am

Eh, a good example of genetic algorithms being adapted to game AI would be NERO. If you've played that, then the whole concept should make a little more sense.

User avatar
Renegade_Turner
Gramps
Posts: 6942
Joined: Tue Sep 27, 2005 11:59 am

Post by Renegade_Turner » Tue May 13, 2008 10:20 am

Yeah, I've played NERO. It's pretty hard, but once you get used to it it's okay. I beat the last guy and the computer gave me back a CD copy of the Enter Shikari album as a present.

User avatar
Makrond
Posts: 498
Joined: Mon Jun 25, 2007 11:34 pm

Post by Makrond » Sat May 17, 2008 1:05 am

Looking at the evolved movement video again - would you possibly be able to make one where the ragdoll attempts to stand up - or fitness based on time standing / energy spent? I just want to see a ragdoll actually get up again.

David
Project Leader
Posts: 1995
Joined: Wed Nov 19, 2003 10:45 pm
Contact:

Post by David » Sat May 17, 2008 1:26 am

A couple more blog posts, one about the movement stuff, and one about controlled intersections.

I could change the fitness to encourage standing, but I think that normal behavior is already pretty well-studied, and can be done more easily by other means.

David
Project Leader
Posts: 1995
Joined: Wed Nov 19, 2003 10:45 pm
Contact:

Post by David » Sat May 17, 2008 7:37 pm

Yet another blog post, about 3D acoustics.

User avatar
Cmyszka
Posts: 317
Joined: Wed Aug 15, 2007 10:43 pm
Location: Wisconsin!
Contact:

Post by Cmyszka » Sat May 17, 2008 7:50 pm

Dang... that'll make the game a whole lot more intense. I can only imagine how realistic playing L2 with headphones on and experiencing all this would be.

With every update i get more hyped for it. I bet this really is going to go far beyond anything we've seen from wolfire, and that's saying a lot. ;)


EDIT: Oh wait... With this be put to use in L2 even? :oops:

User avatar
rudel_ic
official Wolfire heckler
Posts: 2193
Joined: Sun Aug 28, 2005 11:19 pm
Location: Hamburg City
Contact:

Post by rudel_ic » Sat May 17, 2008 8:13 pm

They've put a lot of those principles into GTA4.
It's really obvious when you're in multiplayer, approach a firefight by car, starting a few blocks away, blitz by and then get a building between you and the shooters.

A lot of modern games with high production values get these aspects right. The most common offender though is the sound travel delay, most games ignore it.

Are you using OpenAL for playback? There's a lot of what you're talking about already built into it, as you probably know. And you need no fancy soundcard, they've got a software renderer.

David
Project Leader
Posts: 1995
Joined: Wed Nov 19, 2003 10:45 pm
Contact:

Post by David » Sat May 17, 2008 8:20 pm

Yeah, GTA 4 is starting to do some pretty cool things with the sound rendering. I don't use OpenAL; I am doing all the mixing myself and then streaming it to the SDL audio wrapper. I don't think OpenAL really does much of this actually; it mostly just does the panning and distance attenuation. It has some support for doppler effects but is kind of hacked together based on explicit relative velocities, and not as a side effect of a realistic time delay method.

I haven't used OpenAL much recently though, did they improve it a lot?

User avatar
Makrond
Posts: 498
Joined: Mon Jun 25, 2007 11:34 pm

Post by Makrond » Sat May 17, 2008 9:03 pm

Damn that intersection stuff looks awesome - I'd love to see a Python script that would do that for UV coords in Blender.

User avatar
invertin
Sticky
Posts: 3828
Joined: Mon Oct 23, 2006 4:05 am
Location: IN A CAN OF AWESOME!

Post by invertin » Sat May 17, 2008 9:19 pm

All this sound talk reminds me of this screensaver I've got, fireworks fly up and explode. Pretty flashy, but there is a slight delay after the explosion before you hear it and the camera flies around, so the closer it is the less delay there is.

Which is probably the only computer program I've seen do that.

User avatar
rudel_ic
official Wolfire heckler
Posts: 2193
Joined: Sun Aug 28, 2005 11:19 pm
Location: Hamburg City
Contact:

Post by rudel_ic » Sat May 17, 2008 10:09 pm

David wrote:Yeah, GTA 4 is starting to do some pretty cool things with the sound rendering. I don't use OpenAL; I am doing all the mixing myself and then streaming it to the SDL audio wrapper. I don't think OpenAL really does much of this actually; it mostly just does the panning and distance attenuation. It has some support for doppler effects but is kind of hacked together based on explicit relative velocities, and not as a side effect of a realistic time delay method.

I haven't used OpenAL much recently though, did they improve it a lot?
Can't really speak for the recent version, I've used 1.0 for positional audio and doppler effects a while back. Maybe I'm giving it more credit than it's worth, I don't know.

Edit: Going by the API docs, there's Doppler, distance attenuation and positional audio.

Post Reply