Author Topic: A Valley Without Wind Pre-Alpha #7 -- Lighting, Lava, Deserts, and Interiors  (Read 13081 times)

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Original: http://christophermpark.blogspot.com/2011/03/valley-without-wind-pre-alpha-7.html

Here's the latest video:



The latest screens are collected on the A Valley Without Wind page.

What's New In This Video
This is the game after 10 weeks of development -- we missed a few weeks in there for videos because we were really tangled up with it!  Quite a number of the things in this video are worth pointing out, so read on below (note that the screenshots shown don't correspond to the actual video stills -- you'll need to watch the video itself to see that).

0:03 -- you can see the new lava flats region, although I'm thinking about adjusting some of those dead bushes so they're a bit nicer-looking.  You can also see the new Neutral Skelebot character, who works as an NPC or as a player-character (as all NPCs in this game do).  You might also notice that the enemies in this region are level 517, while the civ level is only 33, so it's pretty much instant-death if they catch me.  And my fireballs do approximately nothing, too -- this is an EXTREME example of playing at a higher region level than your character is supposed to be able to.

0:14 -- This is one of two tilesets for ice age interiors, but it's just a testing floorplan that I was using to verify all the ceiling stuff works well and is easily scriptable.  That was a huge amount of work in the last few weeks, but it's finally easy to define custom floorplans via our chunkscript system.  This makes it so that players can design their own floorplans which get randomized, too.  Unfortunately I never did have time to  actually start populating anything IN the buildings in terms of objects, furniture, etc, which is part of what delayed the videos; I really wanted to show that, but in the end other things were more pressing.  That's coming soon!

0:15 -- Notice the Neutral Skelebot standing there?  That's an NPC that I can talk to, and he'll say something to me as well as craft bear traps if I ask him (he's a Trapmaker profession character).  Still lots more to do with the crafting interface, which isn't shown, and obviously we need to be able to craft more than bear traps, but it's coming along!  A lot of the more involved NPC reactions (Hopes, Settlements, and Deeds are all based on that) will be our big focus of alpha; for now they're mostly about crafting, and you can take them over when your current character dies.

0:18 -- The reason the light faded to nothing is because the new "flash of light" spell had been cast right before this segment of the video, and so it was going back to the normal state of complete darkness after the flash.  Most buildings will be quite dark inside, and what you're seeing at this point of the video is the extremely dim "eyesight view" that you always have as a bare minimum inside.  Realistically, you won't want to play in that eyesight-only mode in dark places much, so you'll light up the darkness with actual lights of various kinds.

0:22 -- Case in point, here's a "moon lamp," which is an ice-age future lamp that never goes out and requires no power.  It creates a pulsing circle of full brightness that is fairly midsized as far as lights will go.  You can see that in my inventory I happened to have 10, and I was placing them like I would a bear trap or other deployable inventory item.

0:30 -- The world map has even more regions on it now, and the graphics for this we're now starting to do in a more vibrant, less-painterly style.  The conversion isn't complete for all tile types yet, but it is for the ones shown here, and the effect is much more dramatic and HD-looking.

These little tiles are just too small and full of detail to have a painterly effect; we leave that to in-game areas, now.  You'll also notice that there are now numbers on each tile -- these are the new "region levels," which control how difficult the area is, and the level of all the monsters in that region. You'll also notice that movement between the different map tiles is now smooth.

0:33 -- This is the new desert tileset, at least in its current incarnation.  All of the tilesets will be getting more varied and detailed with more objects, plants, and other variety as more work is done on them.  The four new regions -- desert, lava flats, temperate deciduous forest, and temperate evergreen forest -- are all "hostile" environments, which means two things.  One, they are twice as large in terms of general space compared to normal non-hostile regions.

And two, every time your character steps into one of the hostile tiles on the world map, you get sucked into them even if the wind counter has not yet reached zero.  By building wind shelters, you can move across even these hostile spaces with impunity, so you can essentially build "roads" of a sort through the deserts and forests.  The lava flats are pretty much always small enough to easily go around them, but they will have valuable things you can find in them, so that's a good incentive to intentionally visit them from time to time, hostile or no.

0:47 -- This is showing one of the Small Town regions, which is not new, but which is much improved compared to past weeks.  A lot of work has gone into improving how buildings are populated near to one another and other objects, and so things tend not to jumble up like they once did.  You can also see some of the new vehicles here, such as the giant bulldozers and the smaller sportscars.  The old Jeep is now gone; that was the one object that I'd based on a photograph rather than a 3D model, but now everything is based on 3D models originally.

0:53 -- We're back to the world map, and you can see a bit more movement around here because I'm moving around as a "ghost," which doesn't get sucked into regions involuntarily.  Ghosts are mainly something we use for testing, and I don't think they'll be playable in the public versions of the game.  You might notice that the "thawing ice age" region tiles still have the painterly look rather than the newer crisp look.  I think those are the last ones I haven't yet updated.

Normally all those dark forest and desert tiles would be hostile, remember, so my movement would either be a lot more circuitous or would be a lot more fraught with peril and side-tracks.  You won't normally move so quickly and so far on the overworld until you've spent a bit of time building up a wind shelter network.  So in a more established world, of course, you'll be able to move around just precisely this quickly.

0:59 -- Back to the lava flats again, this time a bit of a different view.  I'd like to point out the lava effect in particular as being something that's really cool that I'm proud of.  It comes across even better when you're looking at it in full-quality in-game, especially if you're not also moving.  Very dynamic.

1:07 -- Back to the ice age building interior again, to show off a different lighting effect.  When you cast light-emitting spells, they have this crazy, slightly-cartoony lighting effect around them.  I'm using ZWrite to accomplish the faux-lighting effects for the game, so I can't do smooth gradients  that blend together; so hence the more cartoony look instead, which I think looks cooler anyhow.  It took a lot to get this working right!

That reminds me -- the "eyesight effect" is something that only applies for your direct character in multiplayer.  You don't get to see your friend's line of sight, so if you are both tromping around in the dark, it remains just as dark as it would in single player.  That said, of course true light sources (like the fireball or the moon lamps) are seen by everybody just the same.  As I mentioned before, running around in the total dark isn't something you're expected to do all that often.  And since the power is just about universally out, most buildings that have roofs are pretty dark to say the least.

1:12 -- Now we see the dark forest for the first time; this is the temperate version.  This isn't full darkness, you might notice, but instead is just very dim.  You can still see the eyesight view from my character, although he's running fast and it's only dim instead of completely dark, so it's less noticeable.

What is more noticeable is that there are a couple of damaged skelebots chasing after me, and the regen effect that they are using on themselves also glows like the fireball.  A new skelebot that suddenly joins the chase would have no such giveaway, though...

1:15 -- That's me using the "flash of light" spell, which is that second icon on the bar (I've toggled it to bar 2/3, which has that, the bear traps, the moon lamps, and the shrink spell, which I'll talk more about later).

1:19 -- It's only showing "Lvl 5" so obviously about that new skelebot because I specifically switched to targeting him, FYI.  If I hadn't seen him, he could have caught right up to me quickly there.

And that's what's new in this video -- it's a packed video this time!  But there were even more new things that weren't visually shown here.  Read on for details on those.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
What's New, But Wasn't In The Video
These are in no particular order:

Process Improvements
There's been a ton of internal improvements, for one thing.  Previously, after the graphics were all done for a new building or object, it was taking me 20-30 minutes to get all the code values tuned and in place in the game, which was super annoying.  Now we've put in a new developer menu that can be opened with F7, and which lets me tune all of those things directly.  That often brings the process down to 30-90 seconds on average per object, I'm finding (though more on buildings, which needs doors placed, etc, but still not long.

The floorplans definitions have also been hugely improved so that the ceiling definitions (where corners, etc, are -- and what direction external doors far facing are) are now way more dynamic.  All that pretty much happens automatically now, and in most cases the chunk script simply needs to say "put a wall here" or "put a ceiling here, with little other info.  The first prototype I did had something like 20+ different definitions, so even I was making floorplan errors left and right, and it was a really tedious process.  If we want a lot of floorplans, this has to be easy to use!

Actually, that pretty much goes for all of the "process improvement" stuff that we put in place; the only way to get a large volume of stuff into the game is to make it easy to add said stuff.  A solid week of this last three week period has been working on process improvement stuff, so that will pay off big time next week and so on, but that's one of the reasons we didn't have more art content from these last three weeks themselves (though, looking back, there's more than I thought).

Actual Character Stats
Previously, we had only really temporary and non-properly-increasing stats for the characters for things like magical attack and defense, health, etc.  This has been internally completed now so that it's actually like it will be in the final game, although the stat balance will inevitably see a lot of tuning between now and 1.0.

Each individual character has their own unique "roll" however, as in a lot of RPGs, so every individual is unique in their stats.  Right now there are only two visual looks for them, but that will also be increasing in volume before alpha, and after.

Dynamic Character Names
Previously, characters didn't even have names in our working versions, but now they're pulling a first name and a last name from files that are per-graphic, and combining them at random.  So if you have 100 skelebot last names and 100 robot skelebot names, for instance, then that's 10,000 different unique skelebot names, and that's just for the skelebots.

As the "planet names lists" have been really popular with players in AI War, hopefully these character name lists will also prove popular with AVWW, and we should have just ridiculous numbers of character names by the time we hit 1.0.

Many, Many Region Improvements
The generation scripts for all the regions in general have been improved, leading to more varied and interesting regions even with just the assets already in place, and faster generation times particularly on really densely-packed region types like the junkyards or the grassland shanty towns.

Crafting!
The crafting interface and base mechanics are now in place.  Right now you can just craft bear traps out of scrap iron (actually, at the moment an NPC has to do it for you), but a lot more on this is coming soon.

Our system for crafting is really simple: in the crafting menu, you have a list of craftable materials, and you can select one to see all the possible recipes that involve that material, and whether or not you have all the scrap and any other craftable materials needed to make them.

Scrap doesn't have levels, but craftable materials do, and are more rare.  When an item is created from a recipe, it has the average level of all the materials that went into it (often that's just one single material and a collection of level-less scrap).

This will include a lot of variations so that you can really customize your loadout based on what sorts of craftable materials you find (that way your loadout is a bit more self-directed compared to games like Diablo or Borderlands where you just get what the game gives you), but it's not completely open-ended in the way that something like Magicka is.  And none of the recipes are secret or involve any fiddling with the interface, unlike Minecraft.

All of those other crafting systems are really awesome and work well in the contexts of their games, but we want to keep the focus on the adventuring itself.  It's possible we might have a system for slightly customizing individual crafting recipes in the future, but we're not sure.  That would probably be an alpha or a beta thing at the earliest, though.

Inventory Is Now Icon-Based, And Items Have Names And Descriptions
Getting our inventory from being base functional to actually having good usability.  I'll show screens and/or video of it once I have time to make it pretty, but it works quite well and is very quick to work with, which is a big plus.

NPC Dialogue
Think of how it is to talk to NPCs in Final Fantasy 6, or Chrono Trigger, or Zelda 2.  This is basically like that.  Each NPC says one single thing, and that's it.  If you come back after time, they'll eventually have changed to say something else.  In some cases, they'll say different things to different characters based on the context.

There won't be actual dialogue interaction of a significant sort (nothing in the Western RPG tradition), but once we are into alpha and we're working on the Hopes system, you will be able to hear more about the desires of an NPC, and help them out with those if you so choose.  And of course later interactions involving inviting them to Settlements and all that sort of thing.

Right now it's just the basic chat with them, and they can do some crafting for you, and that's probably what our end target for pre-alpha is going to be, as there's a lot of other more gameplay-centric content that needs development before we get into the more advanced NPC systems.

Perma-Death
Our system for perma-death is now fully in place -- when you lose one character, they are gone forever although their bag of inventory is dropped where they died.  Experience gain and civ level is global, and survives past any character.  After one character dies, or at the start of the game, you choose a new character and from then on are them (until they die).

At the start of the game you just get a trio of random characters to start with, and at the moment that's what happens after death, too, but later you'll be able to assume the roles of actual NPCs you've interacted with.  You'll also get permanent graves and such later on, but to some extent that's the very first part of the Deeds system, which is going to be one of the three foci of our time in alpha.

Improved Particle Effects
All of our particle effects have been altered and improved, particularly when shown against light-colored backgrounds.  They now include under-layers that let them work additively, but without "whiting out" against backgrounds that are too light.  In snow areas and inside ice age buildings, the effect is quite dramatic.

New Music
As always, there's a bunch of new music.  The new track from the video is the lava flats theme.  It's really good stuff!

Shrink Spell
One thing that we want to allow players to do, if they are inclined, is to customize their world.  You can't reshape terrain or raze buildings, but there are a ton of destructible objects (trees, shipping containers, broken vehicles, lamps, etc) all over the place.  You can destroy these... but what if you want to rearrange them?

That's where the shrink spell (pictured right) comes in.  It doesn't work on enemies or on indestructible objects (like buildings), but for any smaller objects it lets you shrink them down and put them in your magic bag.

They then show up in your inventory as "Grow Gems," which you can use to re-inflate the object at a place of your choosing -- another region, inside, whatever, so long as it follows the normal placement restrictions for that type of object (trees can't go on tile floors or on roads, straightforward things of that nature).

Right now the grow gems are a bit imprecise to use if the object can't be placed right in front of you based on those restrictions (it just moves to somewhere nearby in that case), and equipping a bunch of grow gems from your inventory would be a pain of a process to go through, but otherwise it's fully ready to go.

Later on probably in alpha, we intend to make a specialized placement mode and streamlined interface specifically for the shrink/grow process that will make that easier to do.  Bear in mind that this is a completely optional, aesthetic sort of activity to undertake in the first place.  But we know some players will really like this (and we think it's cool, too), so we want to make sure it works as easily as possible.

Shadow Improvements
In past weeks, players have still been complaining about two things related to shadows: that shadows cross other buildings, and that shadows would protrude into the sky.  I had thought that the first problem couldn't be solved at all, and that the second one couldn't be solved except by keeping large shadows away from the sky.

As it turns out, in the process of figuring out a lighting engine (I'm using the Z Buffer instead of using actual lighting, for various reasons), I also figured out a way to make shadows not fall on buildings at all, and also not to fall on the sky at all.

I'm not sure how well these specific screens show any such cases where that would happen, but I'm sure the video must.  I'm quite pleased how this unexpectedly turned out!  I didn't know anything quite like the Z Buffer existed -- well, I knew it existed, but not exactly how it could be used in the context of a 2D game like this.

Bunches Of Other Engine Improvements And Extensions
We have entrances to buildings, which is harder than you might think.  We have better scheduled saving of regions and "chunks" to disk, preserving performance and data.  We have a bunch of new shaders to support the faux lighting engine.  We support a bunch of new things that let us do the lava clouds.  The way that the world map is seeded is now quite a bit better.  We added preliminary support for having multiple floors in a building, but haven't finished coding that in yet.  A lot of collision stuff was extended or improved.

And so on.  I know I'm forgetting a bunch of things, but those are at the very least the highlights.  I've spent a lot more time than usual on programming this past three weeks,  but I'm going to be going into a bit of an art-creation kick for the next week or so, and then working tons more on the interiors.  There's still a lot I need to do there to really get that where I ultimately want it to be, with multi-floor buildings of various sorts with basements and all sorts of fun things.

What's Next?
I'm working on tons more art, as I just said, but also on the interiors still; those are the last big worldbuilding area where we have a significant chunk of "horizontal" development left to do.

Keith, in turn, has some more inventory and crafting horizontal development to do, as well as adding support for a few new things like firearms and physical weapons (swords, etc), as well as adding passive "augment" gems that will function in place of armor, improving various stats while you wear them (we're cutting the former idea of armor in favor of this).

Beyond that, I think it's mostly into vertical development for us all the rest of the way from here until we hit alpha in another 3-4 weeks.  There are tons and tons of traps, enemies, characters, dialogues, floorplans, objects, tilesets, spells, consumables, weapons, and so forth that we want to get in place even before we hit the first public alpha release, so it's going to be a hugely busy few weeks.  We have some really cool and unusual enemy designs that I'm quite excited about, so it will be fun to share those as we're getting to them.  Stay tuned!
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline tigersfan

  • Arcen Games Contractor
  • Arcen Staff
  • Master Member Mark II
  • *****
  • Posts: 1,599
Awesome! One question, in the video, on the world map, there are numbers on the tiles... what do those represent?

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Glad you like it!

Quote
these are the new "region levels," which control how difficult the area is, and the level of all the monsters in that region.

That was a lot of text up there, so easy to miss.  Were you inquiring beyond that?
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Teal_Blue

  • Hero Member Mark II
  • *****
  • Posts: 935

Crafting!!!!!   Yes!!!!!

:)

The video looks beautiful, the night and the day, the different new regions, the npc's! Everything looks very, very cool!!
Looking forward to alpha very much! 

-Teal


Offline tigersfan

  • Arcen Games Contractor
  • Arcen Staff
  • Master Member Mark II
  • *****
  • Posts: 1,599
Glad you like it!

Quote
these are the new "region levels," which control how difficult the area is, and the level of all the monsters in that region.

That was a lot of text up there, so easy to miss.  Were you inquiring beyond that?

Nope, I wasn't. I just missed that. Thanks.

Offline Zhaine

  • Jr. Member Mark II
  • **
  • Posts: 85
Heh, time since last update made up for by huge amounts of info this time!

Glad to know a lot of the background stuff (or horizontal development) is done and it's time for more content, looking forward to seeing that.

The vast majority of what I see in the vid I like and it's plain to see that some great progress is being made, so don't take this as overly negative, but I've noted some bits of constructive criticism. Feel free to ignore!

- The lava background is cool, but I feel the moving glowyness, while also nice, is too bright and gets in the way of the other visuals where it's brightest.
- The moon lamps look useful, but I don't like the way it overlaps the walls. For instance at 0:23. I'm guessing it may not be possible due to the way you've done lighting, but it would be great if it didn't shine 'through' walls and only lit the side it was on.
- Also, you mentioned using Zwrite to do the lighting, which means you 'can't do smooth gradients', however it looks like you've done that for the 'eyesight' mode if not the moon lamps and spells, or do I not understand what you mean by 'smooth gradient'? While the spells look kinda cool as they are as they're moving so quickly, it would obviously look a lot better if something stationery like a moon lamp had a smoother 'anti-aliased' edge to it's light radius. Maybe I've misunderstood and you mean to add this :p
- With the world map: due to the small size of the tiles and the compression on YouTube it's pretty tough to see how some of them look. This lead me to think two things:
-- Is there an easy way you can make the original vids available to download so we can see them without compression? As we'll be playing the thing fairly soon this may not be worth it!
-- Does the world map need to be this 'zoomed out'. I don't know how much you need to see in practice, but perhaps it might be cool to be a little 'closer in' on this screen, and then you can keep the same style on the world map tiles. Of course having made the decision to change the graphics around you've probably already considered this!

Hope this is useful. . .

Offline eRe4s3r

  • Core Member Mark II
  • *****
  • Posts: 2,825
Mhnmhnhmnhmhnhmnhmhnh... ZWrite... for light?

Tis.. tis.. not a good idea. It can't be colored, smoothed, graded and knows only ON and OFF (oh, and size), maybe worse - it makes the glow effects and spell effects look aliased.

I think... honestly, that this should be "rethought"

And i wouldn't be a resident art critic if i hadn't a better idea.

So heres my idea. Remove light - like the entire idea of light. Forget it. Add a "layer" that is on top of everything - we call this layer the "FOG of WAR". This layer desaturates and/or darkens (better a bit of both ;p) everything.

These moon blops and lights do not cast light - they remove FOG from the fog layer.
Now that the fog layer is removed - a 20% opacity glow sprite can be blended over to create illusion of glowing light. (but generally a full removal of the fog layer should be "full light" ;p)

For spells they can get "fog of war removing abilities" as well - so casting spell clears the Line of Sight (which even though i call it that, does not have to mean you can't see things beyond a certain range - the fog of war is a layer on top of everything that you "remove" opacity from to create more brightness. Again, it does not need to be a black wall.

I made a mockup - this is a simple 50% gray layer and "light" literally REMOVES OPACITY from it. As added bonus desaturation and colorization at the "light edges" is improving image quality vastly.

Well, thats my 2cts ;)
« Last Edit: March 28, 2011, 11:30:43 am by eRe4s3r »
Proud member of the Initiative for Bigger Weapons EV. - Bringer of Additive Blended Doom - Vote for Lore, get free cookie

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Heh, time since last update made up for by huge amounts of info this time!

That was the hope! :)

The vast majority of what I see in the vid I like and it's plain to see that some great progress is being made, so don't take this as overly negative, but I've noted some bits of constructive criticism. Feel free to ignore!

We're always happy to hear the thoughts of folks, even if we don't always agree.

- The lava background is cool, but I feel the moving glowyness, while also nice, is too bright and gets in the way of the other visuals where it's brightest.

It's intended to restrict visibility some, like blowing sand (except that it's blowing heat waves), so it's doing pretty much what it's intended to do.  We wouldn't normally go with an effect that restricts visibility in quite this sort of manner, but this is one of the most hostile environments, and it's meant to be one of many things there to put players a bit more off-balance than normal.

- The moon lamps look useful, but I don't like the way it overlaps the walls. For instance at 0:23. I'm guessing it may not be possible due to the way you've done lighting, but it would be great if it didn't shine 'through' walls and only lit the side it was on.

Yeah, that would be an incredibly difficult task.  I don't have any algorithms for doing line of sight lighting of that sort.  Even if I had used normal 3D lighting, by the way, this still would have been a problem because this is a 2D game.  So the only solution around would have been to do some sort of line of sight calculations, which are CPU-intensive.

Other 2D games with faux-lighting models tend to handle this by having really thick walls or earth, so that this effect isn't apparent.  That's not a concession I really want to make here, honestly.  LOS stuff might be of interest to pursue sometime in the future, and I'm not sure if I might do it or not, but that would probably be a beta thing or after, if at all.  I'm not even sure if I have the CPU power to spare at the moment, for instance.

- Also, you mentioned using Zwrite to do the lighting, which means you 'can't do smooth gradients', however it looks like you've done that for the 'eyesight' mode if not the moon lamps and spells, or do I not understand what you mean by 'smooth gradient'? While the spells look kinda cool as they are as they're moving so quickly, it would obviously look a lot better if something stationery like a moon lamp had a smoother 'anti-aliased' edge to it's light radius. Maybe I've misunderstood and you mean to add this :p

Oh, I did mean to go into that further, but I didn't.  The "smooth gradient" that you see for the eyesight actually is nothing of the kind.  In terms of the Z Buffer, it's incredibly jagged at the outside edges, but then I'm drawing a simple image inside that jaggedness that is black on the exterior extents, and then which has a gradient in the image inside of that.

That's all well and good when you have only one of those per the entire screen (as with your personal eyesight), but when you have multiple such effects, they will "stack" where they overlap, getting denser and harder to see through, rather than the opposite.  Kind of like force fields in AI War, if you're familiar with how those are at present.

That's why I'm able to fake a gradient for the eyesight, but not for light sources -- because there is only one eyesight effect ever, even in multiplayer, but there will often be many lights.

- With the world map: due to the small size of the tiles and the compression on YouTube it's pretty tough to see how some of them look. This lead me to think two things:
-- Is there an easy way you can make the original vids available to download so we can see them without compression? As we'll be playing the thing fairly soon this may not be worth it!

Well, that's part of what the screenshots are about: http://www.arcengames.com/w/index.php/games/avww-features

This one in particular:

-- Does the world map need to be this 'zoomed out'. I don't know how much you need to see in practice, but perhaps it might be cool to be a little 'closer in' on this screen, and then you can keep the same style on the world map tiles. Of course having made the decision to change the graphics around you've probably already considered this!

Short answer: yes, it needs to be that zoomed-out.  We tried a variety of sizes, at various screen resolutions, and this is the one that "felt right."  It's also quite efficient for RAM/CPU purposes, which is also nice.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Mhnmhnhmnhmhnhmnhmhnh... ZWrite... for light?

Tis.. tis.. not a good idea. It can't be colored, smoothed, graded and knows only ON and OFF, maybe worse - it makes the glow effects and spell effects look aliased.

I think... honestly, that this should be "rethought"

And i wouldn't be a resident art critic if i hadn't a better idea.

So heres my idea. Remove light - like the entire idea of light. Forget it. Add a "layer" that is on top of everything - we call this layer the "FOG of WAR". This layer desaturates and/or darkens (better a bit of both ;p) everything.

These moon blops and lights do not cast light - they remove FOG from the fog layer.
Now that the fog layer is removed - a 20% opacity glow sprite can be blended over to create illusion of light.

For spells they can get "fog of war removing abilities" as well - so casting spell clears the Line of Sight (which even though i call it that, does not have to mean you can't see things beyond a certain range - the fog of war is a layer on top of everything that you "remove" opacity from to create more brightness. Again, it does not need to be a black wall.

I made a mockup - this is a simple 50% gray layer and "light" literally REMOVES OPACITY from it. As added bonus desaturation and colorization at the "light edges" is improving image quality vastly.

Well, thats my 2cts ;)

That's more or less what I'm doing with the z buffer, except it does only know on/off, as you say.  The problem with the sort of effect you're describing is that there's no screen-resolution-friendly way to do that that I know of.  I'd have to store a texture that is the size of the entire screen, however big that is, and then do a ton of alpha value subtractions every frame, which would be doable, but likely more CPU-intensive than is feasible.  That would all have to be done on the CPU, and then all of that data gets sent to the graphics card as this potentially-massive texture that would potentially crash on monitors that are larger than the norm.

I've thought about using other sorts of things like a secondary camera in Unity with an "active texture" on it that is supposed to do this sort of thing, but it's not really feasible either because it doesn't support alpha.  So I'd have to be doing this in black and white like an alpha map perhaps, and then somehow translating that into alpha data in realtime... which also seems really inefficient.  And those sorts of textures aren't supported by all graphics cards, either.

In all of the other cases I looked at, they tend to either not work at all, or not work except on really nice graphics cards, or not work on larger monitors, or really just add a lot of CPU or GPU load to the whole affair.  Goodness! 

By contrast, the z buffer is really bleeding fast, works with any size of monitor, is supported by the oldest graphics cards anyone might have, etc.  The one downside: for the light itself, the edges can't be anti-aliased.  I'm totally cool with that.

And as far as "remove light entirely," that's definitely not going to happen. ;)
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline eRe4s3r

  • Core Member Mark II
  • *****
  • Posts: 2,825
But theres a certain game that did it before.. -> http://extreme.pcgameshardware.de/attachments/290280d1291196372-sammelthread-diablo-3-diablo2.jpg ;)

However, you are right in that it is screen resolution dependent (in case of d2) HOWEVER it can be done as a fullscreen shader and thus be entirely done in the GPU (in realtime). (side effect, you setup a fullscreen shader that can do a lot more than just fake fog of war effects, like bloom, real-time desaturation, distortion, warp - color shifts etc. ,p)

If you make it optional it wouldn't even inhibit performance. ;D

Edit. Also - the 1 downside you mention is a pretty dang large downside because it doesn't fit your art direction imo. Everything in AVWW looks so nicely smooth and "in flow" (and downright nice in HD) that i think a pixelated border around lights (and around spells when cast in darkness) would be very "out of style".
« Last Edit: March 28, 2011, 12:09:46 pm by eRe4s3r »
Proud member of the Initiative for Bigger Weapons EV. - Bringer of Additive Blended Doom - Vote for Lore, get free cookie

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
A fullscreen shader would work, but I don't know how to make it work based on the GPU only in terms of reacting to specific data that's there.  Given how we render to the GPU, I don't think all the needed data would be on the GPU at the same time.  At any rate it would be a pretty massive undertaking that I'm not going to get side-tracked into now.

In terms of making lighting optional, that's also the sort of thing that's non-negotiable.  Having it so that players can just turn on the lights in a dark room by a game setting means that the darkness is pointless.  It's just a visual thing, then, not relevant to gameplay.  Darkness in AVWW is very relevant to gameplay indoors, however, so that's not okay.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline BobTheJanitor

  • Master Member Mark II
  • *****
  • Posts: 1,689
I didn't want to be the first to complain about it, after complaining about the shadows too much already. But I do agree that the lights look very  rough and don't match well with everything else. If there's no way to do a smooth gradient on them, could you use some kind of trick like artists do when shading with inks? Some sort of cross-hatching or stippling effect to give the impression that the light dies off towards the edges?

Glad to see all the other continuing improvements, of course.

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
If there's no way to do a smooth gradient on them, could you use some kind of trick like artists do when shading with inks? Some sort of cross-hatching or stippling effect to give the impression that the light dies off towards the edges?

No, it will combine and turn to black when overlapping, as well.  The more light sources you get near one another, the blacker it gets on their overlap, rather than brighter, if there is anything in there at all.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline getter77

  • Jr. Member Mark II
  • **
  • Posts: 79
Bah, I got slim to nothing in terms of lighting oriented links that would potentially be relevant/helpful, no doubt greatly compounded by the discussion being ridiculously over my head.

All that comes to mind, is this recent competition game using the libtcod library and that libtcod is pretty much the leading thing in the Roguelike community when it comes to most lighting issues/tricks in a "forward looking" manner.

http://heroicfisticuffs.blogspot.com/2011/03/7drl-2011-reviews-light.html

Otherwise, I can deal with an eclectic lighting in a game....so long as the game plays IT up as opposed to being something that kinda sticks out as a "well, we got stuck on this" way.   Quirks can really feed into personality afterall.
The Roguelike Guy...also hopefully an overall skilled developer as time rolls on.

 

SMF spam blocked by CleanTalk