Arcen Games

General Category => A Valley Without Wind 1 & 2 => AVWW Mods & Maps => : Bluddy April 24, 2012, 10:40:02 AM

: Crowd-sourcing animation?
: Bluddy April 24, 2012, 10:40:02 AM
One of the complaints that's been leveled against the game's looks is that the animation is stiff. This is one I tend to agree with, and we all know the reason for it -- it takes time and money to do animation and there are many many characters in the game. I've been thinking though: there are probably a few people on the forums who are pretty good with pixel graphics and could try to slowly fill in the gaps in the animation. The key here is that this is something that can be done slowly over time. Preferably, one animation at a time could be added per character, so that you don't suddenly have one character that's fully animated while others aren't animated at all.

What do the devs think of this idea?
Also, could you explain the way the characters were rendered, and how we could go about filling in the gaps (if it's possible?) I see that while running has a full dictionary of movements, the other 'animations' are just static pictures.
: Re: Crowd-sourcing animation?
: x4000 April 24, 2012, 11:15:25 AM
I don't think it's feasible.

1. The character models can't be distributed free of charge, so individual animators would have $400+ to shell out to help at all, and then $20+ per character after that. I can't imagine anyone volunteering.

2. Accepting free art is always tricky. If it stands out from the rest of the art, all the other art is forevermore committed to looking the same way. Relying on volunteers to do this seems super risky.

3. In general, I don't want any more frames of animation added to characters. Just adding two new animations per character/monster would triple loading times in my estimation, and send ram usage spiraling upwards.

In general, if people want high-fi graphics, Arcen is not the company for them. We exploit the performance gains and low ram use of having lower-fi animations. Even if we had unlimited money and a staff of 200, I don't believe that you can make games of this scale and variety while also trying for either full 3d or large-framecount-sprite 2d graphics. Not on current generation hardware.

That's part of why nobody else does games like this, or they just do them in pixelart. There are ways around some of those constraints with background loading/unloading, but that makes framerates choppy. And there are ways around some of them with certain styles of hand-drawn multi-component character art. But that requires extremely skilled artists paired with a completely new character animation subsystem to go along with it. If we had unlimited money, perhaps that would be what I'd pursue. But I don't think crowd sourcing that would work; art creation is enormously intensive and personal, and even if we had that many talented artists who were fans, their styles wouldn't be likely to match each other. And if they ever left, I'd be unable to add more characters/monsters.
: Re: Crowd-sourcing animation?
: Bluddy April 24, 2012, 11:35:12 AM
OK well if the character models can't be distributed for free, that kills the idea right there :)

I was thinking it shouldn't be too hard to position a character model in the positions needed for animation and then rendering it. Using the same character models would also mean that it would be fairly standardized: an animation either looks good or it doesn't, and you can't have too much free rein when you're using an existing character model, so you wouldn't feel like a hundred different hands drew the graphic or something like that.

I appreciate the technical limitations Chris, but I also noticed that you tend to be fairly conservative in this regard. That's cool, I mean, it seems like you're an engineer at heart, so every performance drop hurts and I identify with that being an engineer myself, but AVWW is barely pushing anything near the limits of the current GPUs other than perhaps the 1024x1024 size textures which weren't supported up until a few years ago. I think that in general, if there's a will there's a way, especially since we're not talking about stuff that's so far out of the technical limitations of current hardware, and since the game is not really at the 'teetering point' where adding some stuff is going to kill performance on everybody's computers. At the very worst you could have the full animation be only for high end computers, which is what the AAA game companies do anyway.

But like I said, the $400+ entry fee is the real problem here, so the other stuff doesn't really matter.
: Re: Crowd-sourcing animation?
: x4000 April 24, 2012, 11:44:27 AM
Yep; if it were a matter of just positioning the character models for animations, that would be something that would be reasonably standardized.  To do that requires Daz 3D, though, which is expensive if you don't have it.  And then to get the props needed for each character varies in price, but could be anywhere from $5 to $60 depending on the current prices.  I bought all those things on incredible discount originally, so most characters only cost me $6 to $10 total, but that was at $2 a prop instead of the usual $18, that sort of thing.

In terms of the hardware limitations, we are bumping up against them actually.  RAM use, not GPU use, is the concern.  And loading times.  Nothing about having more animation frames would even impact render performance (or GPU load) remotely at all.  Once you were in the game and it was running, it wouldn't matter if we had 10,000 frames of animation or 25, the load on the GPU and the performance is literally the same -- because either way, you're only drawing one frame from one sprite dictionary at a time.

But the process is a 32 bit application with the RAM limitations that implies, and any new art asset that is added has to be streamed off the disk every time you switch regions or load the game or encounter a new character for the first time.  You get a linear increase in load times when you add more frames.

Anyway, hopefully that explains my comments on the technical limitations more -- I'm not being overly conservative, we've literally had crashes relating to RAM use and right now are just maintaining a healthy distance from that point by virtue of the region switching thing.  If each monster/character graphic was using 5X as much RAM, we'd have to introduce some sort of new intra-region RAM dump points (which is tricky because we can't see exactly how much unmanaged memory is even in use, unlike with the managed memory; we could come up with ways to infer it in terms of textures specifically, but that's messy and incomplete).

And you're right, I'm definitely an engineer at heart, and approach problems that way.  If there's not a 2:1 buffer from failure I'm not happy.  And even now there's only like a 1.5:1 buffer from failure from RAM use via textures, so I'm definitely not being paranoid in an unwarranted sense.  Just ask c4sc4 or a few others who actually had the crashes prior, heh.
: Re: Crowd-sourcing animation?
: keith.lamothe April 24, 2012, 12:07:02 PM
Yea, in order for a game like this to have lots more animations per character (and smooth ones) I figure it'd either need:

- A very sophisticated approach to dropping textures you don't need very shortly after no longer needed them, and getting them back off disk before you need them again to avoid flicker/pop-in.

or

- Full-on 3D rendering so the animation is actually done by moving the parts of the model around at runtime, thus drastically reducing the amount of additional texture memory needed for animation.  But that has all kinds of other performance costs (and of course would be a completely different game), and there's no way we could draw the characters in nearly as much detail except on really beastly computers.
: Re: Crowd-sourcing animation?
: Bluddy April 24, 2012, 11:40:18 PM
Yeah I just did the quick math and realized each dictionary costs you 1024x512x4 = 2MB. And you have about 40ish characters in the game, so that's 80MB right there just for a running animation.

The real killer is these 32-bit textures. You could probably convert them to 16 bits without too much trouble, which would halve the space needed. You could then stuff in another dictionary per character, and that dictionary could contain all the other animations you'd want, which would be pretty short. I mean if you're talking about a firing animation, you want that to be about half a second at most so that there's no real delay. A hit animation would only need a few frames more than what you have right now to seem fluid enough. And you could even have a minimal idle animation.

Now that I think about it, why do you have 2 running animations per character?
: Re: Crowd-sourcing animation?
: x4000 April 25, 2012, 10:09:35 AM
We only have one running animation per character -- but what you were seeing there is some older cruft from during beta.  Only the first one is used or included in the latest versions if you install fresh.

In terms of having them be 16bit, we can only import from PNGs using unity; and those are higher-res.  We can then downsample to a lower compression if desired, but that makes things look very muddy and terrible.  We could directly alter the format in memory, but that's very slow and would easily quintuple the loading time for each existing image we have, let alone new ones.  Yikes, eh?
: Re: Crowd-sourcing animation?
: Bluddy April 25, 2012, 11:07:53 AM
PNGs aren't the greatest format for textures. I know that from having worked on the PSP version of ScummVM. On the PSP though, I could use PNG palettes to create paletted textures for some stuff, and that was amazing -- it'd reduce the image size by 4. Unfortunately modern video cards no longer support paletted textures.

Since the dictionary images are fairly simple (color-wise) you could truncate them to a 16 bit format. Simply taking the top 5 bits of each channel and a single bit for alpha will do the trick. GL_RGB5_A1 would be the result. Even though the OpenGL page says it's better to compress the textures than to truncate them, in your case it isn't true, since texture compression looks really bad in 2d games. Truncating the channels though will produce output that's very close to the original in most of the cases, since the color complexity isn't very high for those dictionaries. To test this, I just took a couple of dictionaries and saved them as 16-bit RGB5_A1 bmp. They're virtually identical.

Doing this truncation would reduce the memory size by 1/2 for all characters. You wouldn't want to do this for some enemies that have a lot of color variation, but it should be fine for skelebots, people etc. And the operation itself is very cheap.
: Re: Crowd-sourcing animation?
: x4000 April 25, 2012, 11:13:11 AM
Unity only supports "load from WWW" (aka their streaming method) with PNG files.  However, once loaded it puts them into a native format.  I forget which one exactly, but I think it's ARGB32 or similar.  So perfect quality but quite large.  There's not much more that I can do unless I wanted to package all the files into the unity build (making distribution a nightmare), as well as have it so that unity loaded all the images from disk pretty much at game load (meaning that RAM usage would spike despite the more efficient format, and there would be definite upper bounds on the amount of textures we could ultimately put in the game, unlike now).

If they supported slightly different things then I'd definitely import differently, but so it goes.  They focus on their main use cases for their developer customers, and we're definitely off the beaten path.  So unless this becomes the next Terraria or something I don't know that I'll be able to browbeat them into doing what I want.  But if we do get that sort of clout, I already have a list of things I intend to use it for with Unity. ;)
: Re: Crowd-sourcing animation?
: tigersfan April 25, 2012, 11:24:50 AM
If they supported slightly different things then I'd definitely import differently, but so it goes.  They focus on their main use cases for their developer customers, and we're definitely off the beaten path.  So unless this becomes the next Terraria or something I don't know that I'll be able to browbeat them into doing what I want.  But if we do get that sort of clout, I already have a list of things I intend to use it for with Unity. ;)

Like locking the mouse onto the monitor I'm playing the game on? :)
: Re: Crowd-sourcing animation?
: eRe4s3r April 25, 2012, 11:42:30 AM
Well crowd sourcing sprite-rendered animations is out of the question I'd say. I don't think there are many people on the web who do animation work of that kind, most are just modelers who sorta learn it on the way, but they are not the ones doing for-free work of this magnitude usually....

That said, maybe at some point sprite animations can be done by deformation and dynamic IK (with sprites but not in dictionaries) It'd take some trial and error to get this working right but the end result would be worth it. It would be a viable thing to think about when the next game is made by Arcen.. because unless something changes anytime soon 3d-character making is still expensive .. primarily in time it takes to make it and thus cost ;p

But now that said that, I think the current character animation renders still could do with some touching up in photoshop.... and that's relatively easy to fiddle around with.
: Re: Crowd-sourcing animation?
: Bluddy April 25, 2012, 12:42:48 PM
BTW looks like Daz 3D is FREE for a limited time. Looks like there's no catch either. So that reduces the barrier to doing this by $400.
: Re: Crowd-sourcing animation?
: Bluddy April 25, 2012, 12:50:38 PM
OK it's not for a limited time. It's their business model. Still.
: Re: Crowd-sourcing animation?
: x4000 April 25, 2012, 12:54:41 PM
Yep, then it's just down to the costs of the stuff for the characters themselves.  I still can't see anyone doing the art even if it costs them "only" $20, though.  That's them paying more than the cost of the game to then do work for free for a game we're making money on.  And the price of DAZ 3D then goes back up in a few weeks or a month or whatever.


I dunno.  One thing is certain, though: this thing is selling like hotcakes at the moment, and the main complaints from people who actually like the game have been that they want to see more enemies, more missions, etc.  The worry about too much repetition.  Getting bogged down in redoing existing art assets is the sort of thing that could lose us all our newfound fans if we really let that distract us, while at the same time I honestly don't think that a few extra animations are going to impress the people that hate the graphics.

That's been something I struggled with from alpha on: if I only tweak this to the art, then they'll like it.  Etc, and repeat.  And now it's a year later, the graphics are worlds better than they were in a pretty indisputable fashion, even if you think they still look like crap (which I know you don't, I meant the metaphorical you).  And those people's opinions haven't shifted at all.  Know what?  Those folks just aren't my customers.  I can't please everybody, but I could run this ship into the ground while trying.

Right now there's a ton of momentum for the game, it's outselling what AI War did 3:1 and we were up to #5 on the Steam top sellers list last night and are currently sitting at #9.  The press are largely really enthused, and word of mouth seems to be spreading as well as lots of of fan mail coming in folks who are talking about how they love how the game harkens back to their childhood in the 90s.  Etc.

Two days ago my fear was not being able to capture new customers due to the art or whatever other factors.  Now my fear is losing the momentum of new customers by not just completely delighting the sort of people who clearly have a taste for this sort of thing.  So new enemies, new missions, ever-polished mechanics, and other fun stuff to explore is at the top of my list.  The art just doesn't even register for me at this point anymore, to be honest; if there are incremental upgrades that can be done that make sense, then my stance would largely be the same on those upgrades as it was during the beta. 

But even there, during the next couple of weeks what most needs to happen is for all these new fans to see Arcen beta release schedules in their full glory, if you know what I mean. ;)  Just figured I'd explain where my head is at.  Aside from the technical discussion that this started out as, a lot has changed just out in the world in general.  The folks talking about bad graphics have mostly seemed to be limited to a very few small corners of the Internet thus far, thankfully.
: Re: Crowd-sourcing animation?
: Bluddy April 25, 2012, 01:11:00 PM
Awesome! I'm SO glad to hear that it's going well.

Just to clarify, my attitude in this thread was never one of "OMG we have to satisfy the people who crave good animation, let's do whatever's needed to get it done." It was supposed to be more like "this is something that could be improved and could be fun for some community members to work on but is clearly not particularly important... is it even feasible?" Mostly I think I was just picturing myself doing some fun animation in my spare time and enriching the game in the process. None of the discussion here was meant to occupy too much of your time though, or to distract you from more important stuff.

Congrats again!
: Re: Crowd-sourcing animation?
: x4000 April 25, 2012, 01:14:47 PM
Cheers!  I really appreciate it -- all of it.  Of all the people who have contributed to the beta, I don't think anybody else had a singularly larger impact than you.  The suggestion-acceptance-rates don't really show that, but the whole refactoring period in November was all sparked by your commentary.  And the same has been true of a great many other issues and ideas, since, as well.

I just had realized I hadn't taken a chance to thank you for that yet, and so wanted to let you know what an impact you've made. :)
: Re: Crowd-sourcing animation?
: Bluddy April 25, 2012, 04:01:47 PM
Thank you. That means a lot to me.

It's a real pleasure on my end interacting with you guys. I absolutely love how transparent you are, to the point that we use the same bug management tool that you guys are using -- it's an amazing experience, as others have already commented. And I love how you were able to take my original remarks - which were probably said in too harsh of a tone - and use them constructively. I also really appreciate that you and Keith aren't afraid to try something completely new, or to not follow the predefined genre constructs. It takes a lot of guts and creativity to do that, especially when you're not backed by a huge company. Your passion for what you do shines through, and it's been really cool to be a part of the process of making AVWW.

Anyway, onwards to AVWW 2.0 (as soon as you've recovered from the craziness, that is)!
: Re: Crowd-sourcing animation?
: keith.lamothe April 25, 2012, 04:11:47 PM
(as soon as you've recovered from the craziness, that is)!
Ah, no, you've got it the other way around: it's the craziness that makes all this happen, we just need to correct our momentary lapse into sanity! ;)

And yes, thanks for all the help :)
: Re: Crowd-sourcing animation?
: x4000 April 25, 2012, 04:47:40 PM
Cheers, Bluddy.  I don't have anything more to add, in particular.  But you've really rapidly become an integral part of this community and we're both really happy to have you here. :)
: Re: Crowd-sourcing animation?
: tigersfan April 25, 2012, 06:09:22 PM
Cheers, Bluddy.  I don't have anything more to add, in particular.  But you've really rapidly become an integral part of this community and we're both really happy to have you here. :)

Make that three of us. :)
: Re: Crowd-sourcing animation?
: zebramatt April 26, 2012, 10:53:11 AM
Wow, this turned into a bromance, huh?

I'm happy for you guys  :D
: Re: Crowd-sourcing animation?
: x4000 April 26, 2012, 12:58:02 PM
 :P
: Re: Crowd-sourcing animation?
: nanostrike May 04, 2012, 12:17:25 AM
Is it possible to modify/substitute in new, custom character models?  I know there was a post about replacing some of the in-game art, and I was wondering if it was possible for characters too?
: Re: Crowd-sourcing animation?
: Coppermantis May 04, 2012, 01:52:02 AM
Given that all the character art is just PNG images in runtimedata/images then I would say yes.
: Re: Crowd-sourcing animation?
: zebramatt May 04, 2012, 03:33:10 AM
Yup, and you can add it as a texture pack, so you're not replacing anything permanently (and it's persistent across releases).

You know you can install this as a texture pack, right?

Texture Pack Support

There is now a dropdown in the Graphics tab that allows you to select from any installed Texture Packs, if any are installed.

Here are the instructions for how to create texture packs if you have an interest in doing that:
To add a texture pack, simply add a folder here in the AVWW/RuntimeData/TexturePacks folder.
The name of the texture pack in the game will be the name of the folder. So if you make a folder called BobsTextures, that's what it will show up as in the game.

HOW TO REPLACE A TEXTURE USING THE TEXTURE PACK:
Inside your texture pack folder, simply duplicate the contents of the Images folder that you want to replace. Don't bother moving over images that you aren't doing custom versions of -- the game will first look into the active texture pack folder and then will look into the base images folder if nothing was found.
So, for instance, if you want to replace the keyboard cursor (normally located at AVWW/RuntimeData/Images/Misc/KeyboardCursor.png) you would add AVWW/RuntimeData/TexturePacks/BobsTextures/Images/Misc/KeyboardCursor.png.
That would alter the keyboard cursor, but no other parts of the game. You can do that for as many or as few images as you like.

HOW TO REPLACE A PARTICLE EFFECT USING THE TEXTURE PACK:
Inside your texture pack folder, make a Configuration folder. Then make a Particles.xml file that is a copy of the main Particles.xml file in AVWW/RuntimeData/Configuration/Particles.xml.
Simply make <g pattern="Fireball"></g> entries for particle effects that you wish to change. Don't worry about trying to do them all -- just do the ones you're actually making changes to. The others will load from the main Particles.xml file just fine, but your custom particle definitions will selectively override whatever you wish.
Did you know? When you have the game open, you can hit Ctrl+F4 to reload the Particles.xml files at will. That way you can make a small tweak, hit that key combo, and then test your change immediately without having to restart the application.

TIPS:
Generally speaking, you need to keep the images to the same size and dimensions as the original. Any wildly different image sizes won't look at all correct in-game, especially when it comes to sprite dictionaries (animations).
That said, when it comes to things in the Backdrops and Ground folders, those can be set to pretty much whatever size since they are repeating tiled graphics.
: Re: Crowd-sourcing animation?
: Bluddy May 04, 2012, 09:40:45 AM
I have a question. When you load textures from disk, do you store/cache them as PNGs in memory, or do you translate them straight to textures?
: Re: Crowd-sourcing animation?
: x4000 May 04, 2012, 10:12:15 AM
I have a question. When you load textures from disk, do you store/cache them as PNGs in memory, or do you translate them straight to textures?

It's not something we handle directly; however, unity loads them into a texture in unmanaged memory.
: Re: Crowd-sourcing animation?
: Bluddy May 04, 2012, 10:17:14 AM
I have a question. When you load textures from disk, do you store/cache them as PNGs in memory, or do you translate them straight to textures?

It's not something we handle directly; however, unity loads them into a texture in unmanaged memory.

That's what I thought. The thing about this is that this is very wasteful of memory, since Unity converts each PNG to a texture. This is why you get such extreme memory allocations for the graphics. What you really want to do is cache the PNGs in memory yourselves -- just store the data. PNG compression is great for the type of graphics you have, so if you store them in memory, you get massive savings. What you want to do is only convert the PNGs to textures dynamically (ie feed them to Unity) when you need them.
: Re: Crowd-sourcing animation?
: x4000 May 04, 2012, 10:24:16 AM
I have a question. When you load textures from disk, do you store/cache them as PNGs in memory, or do you translate them straight to textures?

It's not something we handle directly; however, unity loads them into a texture in unmanaged memory.

That's what I thought. The thing about this is that this is very wasteful of memory, since Unity converts each PNG to a texture. This is why you get such extreme memory allocations for the graphics. What you really want to do is cache the PNGs in memory yourselves -- just store the data. PNG compression is great for the type of graphics you have, so if you store them in memory, you get massive savings. What you want to do is only convert the PNGs to textures dynamically (ie feed them to Unity) when you need them.

Nope, quite the opposite.  The compression of PNG may be great, but to use it at all requires decoding it and sending that to the GPU.  Wasteful of CPU cycles and RAM.  Unity stores the textures in a lightly compressed format that can be directly read by modern GPUs.  I forget the exact one it's using, but it's one of several that are standard in pretty much most games.  Storing the PNGs natively and then converting them once per frame to something the GPU can draw would probably be lucky to get you one frame a second on a lot of computers.

And anyhow, it's all beside the point because we're not able to change things at that level with the engine in the first place; if you'd like the unity engine recoded you'll have to talk to them rather than me. ;)
: Re: Crowd-sourcing animation?
: Nanako June 10, 2012, 05:22:42 PM
It seems like the problem here is that you've used frame by frame animation. WHY ?

I'm writing a game in flash just now, and it stood out to me immediately that this was a bad idea to do animations. Luckily flash has a built in feature (though perhaps you could code something similar) for 2D armatures. I have an image of a character's arm, head, torso, etc, that are pieced together into the whole, and all animations exist simply as transforms of that armature. one character is a set number of images that will never change no matter how i animate it. I'm not exactly alone in doing something like this, either, it's quite common in many flash games.

flash does have support for runtime armatures as well, which incorporates a lot more math, but that wouldn't be necessary. to me it's purely an authortime tool for making animations that move and flow convincingly, and keep the resource use low.
: Re: Crowd-sourcing animation?
: eRe4s3r June 10, 2012, 09:28:03 PM
I would think it's because originally this was top-down pseudo 2.5D and there, these animations really made sense and is how these game were done for eons. However for side-scrollers I agree that the fluidity and diversity of the animations should have taken precedence because you are constantly seeing them. And I think that whatever one sees 99% of the time should be of the highest possible quality.

That said, for this kind of game the animations should either have been /drawn sprite based or fully 3D because that would have allowed IK and rag-dolls. I guess so would have the 2D version of that (each limb separate with a layering function and as bone attachments)
: Re: Crowd-sourcing animation?
: x4000 June 11, 2012, 09:46:46 AM
It seems like the problem here is that you've used frame by frame animation. WHY ?

I'm writing a game in flash just now, and it stood out to me immediately that this was a bad idea to do animations. Luckily flash has a built in feature (though perhaps you could code something similar) for 2D armatures. I have an image of a character's arm, head, torso, etc, that are pieced together into the whole, and all animations exist simply as transforms of that armature. one character is a set number of images that will never change no matter how i animate it. I'm not exactly alone in doing something like this, either, it's quite common in many flash games.

flash does have support for runtime armatures as well, which incorporates a lot more math, but that wouldn't be necessary. to me it's purely an authortime tool for making animations that move and flow convincingly, and keep the resource use low.

Generally speaking, unless you have a really good artist doing cartoon-style art, my experience has been that the armature-based animation looks very, very cheap and bad.  Like a puppet.  Frame-by-frame animation gives you much more flexibility when you are working with something that started out as a semi-photo-real 3D model in particular.

Not to knock the armature-based animation, as I think that that can lead to the most superior results of all -- presupposing that you have some very talented artists on-hand who can draw in a suitably non-photoreal fashion.