Jump to content
The Dark Mod Forums

Moonbo

Member
  • Posts

    1113
  • Joined

  • Last visited

  • Days Won

    58

Everything posted by Moonbo

  1. Hey Araneidae, let me know if you can't figure it out and I'll be happy to give you a hint :-). There's also a Let's Play on Youtube in case you get totally stumped.
  2. Hey SimpleN00b, I'll just have to put you on the beta testing team when the time comes :-). @7upMan, sadly the next book is going to be sci-fi so, not thief related. I won't complain if you buy it though!
  3. Sadly, I don't think it does.
  4. Thanks, Grayman .
  5. Hey guys, I should have been much more explicit about the situations where I used this optimization. It was in places where I had a lot of lights on multiple levels and you could see the levels at one time. So, the pit area of Requiem looked like this: I had 4 lights in close proximity to each other on three floors that were stacked one on top of the other, with a big hole running through them: So in this case if the lights overlapped through the various floors/ceilings then I had a serious performance hit (because the levels were visible simultaneously). That's what this method solves for - instances where you need to avoid having light overlaps through geometry. A more common example (like RJFerret mentioned) would be two levels of a house connected by a grand stairway where at certain angles you could see both floors at the same time. I'll update the OP to be more exact.
  6. Hey Sotha, very true. This is only one solution to light overlaps causing performance problems. There are others . @ Biker, I'll try to set up an article on the wiki sometime later today.
  7. Hey simplen00b, I've done my best to match them up, but can you show me where you think they'd hit w/ an arrow or something. I'm having trouble seeing it with my minds eye. Thanks!
  8. I spent some time working on my WIP map today and ran into a situation with a multi-layered structure with oil lamps on each floor. The problem was that I could see both levels of my structure simultaneously and the radii of my lights was too tall and I got a lot of overlapping lights between the floors of my structure, leading to bad performance. I was able to solve the problem using a method similar to one I used in the "pit" portion of Requiem and since it works so well I thought I'd share it. Note that proper use of visportals will most often solve overlapping lights, since you can lock some of your lights behind a closed visportal where they won't render. So only use this method if you have geometry which makes that impractical. Overlapping lights (i.e. lights whose radii light up the same objects/geometry) are one of the most common performance killers in TDM. Unfortunately the standard light entities have two issues which make it a common problem, especially if you're lighting up geometry where you can see through more than one room/floor at the same time: a) For the sake of realism, the light entities need to be attached very close to a wall (for torches) or ceiling (hanging lamps). This means that a large part of the light radius is going to be poking out the other side of whatever wall/floor you attach it to. If you have any other lights nearby, like in the next room or the next floor, you'll get overlap. b ) The default light texture on light entities (usually biground_torchflicker or biground_candleflicker) produce a relatively weak light which means you need a relatively large radius to compensate. The result is that the radius of your lights is normally going to be much wider/taller than the geometry you're trying to light up. The following is a step-by-step walkthrough of one solution to this problem. This solution is meant to be used in situations (like mansions or multi-level structures) where you have many lights in proximity and need to make sure they're not touching each other for performance reasons. A drawback to this method (besides the time it takes to set it up) is that it will generate more entities in your map than if you just used standard lights. I start off with a two-story structure with two wall mounted lamps, one on each floor: 1) When you select the lamps in Dark Radiant you just see the model. You don't see the light that it will generate. But when you load up your map, the light is present. What's happening is that the entity has a default light attached to it which is spawned when you load the map. You can find it by looking at the lamp entity in DR and checking for the "def_attach" spawnarg. For these lamps that spawnarg is set to "light_candleflame", which is the light entity that's spawned on the lamp when we load the map. All of these various light entities can be found under Lights->Light Sources in the entity viewer. 2) Now that we've identified which light is being spawned by our lamps, the next step is to add the spawnarg "def_attach -" to the lamps. This removes the default light, so that if you were to load up the map, no light would be emitted by them. 3) Next create a 'light_candleflame' entity, position it on the lamp, and use the "bind" spawnarg to connect your light_candleflame to your lamp entity. Now if you load up the map, your lamp will look and act just as a normal lamp entity would. But since you can now see the light that's being cast in DR, you now can customize the spawnargs of the light. By itself this is a great way to eliminate light overlaps because you can just tweak the radius of your light (as well as color, whether it casts shadows, etc) instead of relying on the default light entity radius. At this point, after creating my custom lights and tweaking their radius a bit, here's how everything looks in Dark Radiant. You'll noticed that I've still got the light radii overlapping through the ceiling. In looking at this situation the only way I can have these two light not overlap each other is to move the lamps up and down the walls until they're farther apart. Sadly I can't do that without the lower lamp ending up hovering over the floor. Not only that, but if I move the lights farther apart the light will no longer significantly illuminate the ceiling even if I boost the light's brightness to 100. Let's solve the first of these problems: how do I get these two lights to not overlap without moving my lamps farther apart. The solution is to create a second light. 4) First, create a 'light_extinguishable' entity (found under Lights->Base Entities) and give it a radius such that it's just barely touching the ceiling and the floor. Give it the same light texture/color/ etc of the light_candleflame, and bind it to the lamp with the 'bind' spawnarg. If you want shadows to be cast from the direction of the lamp, move the light center on this new light to above the lamp (the light center determines where it looks like shadows are coming from. You can select it by clicking on a light and going into vertex mode. Then just move the vertex at the center of the light around). 5) Give the original light_candleflame that we created a radius of 1 1 1 . This will make the light so tiny that it won't cast onto any geometry. The reason we don't just erase it all together is because a) it creates a light flame particle for our light and b ) it will generate smoke etc when our light is extinguished. Once done to both lamps, this is what it should look like: Voila. We've now got two lights on top of each other that don't overlap and will act exactly the same as a normal lamp entity would in game (i.e. extinguish, turn back on, etc). Now let's solve the final problem: this setup is great but if I load it up in-game, the lights are very dim across the ceiling and floor, even if I boost the light brightness to 100. Because only the very edge of the light's radius touches the ceiling and floor, the illumination will be quite dark. The solution is to create a custom light texture. Most lights in TDM cast a light texture, basically a 2d image painted along the light. The light textures for most lamps/candles are based on the "biground" light texture, which ends up making the lights pretty dim. There's another light texture called "brightround" which when applied will make the same light incredibly bright. My custom light texture is a brightround which flickers like a torch. 6) Create a custom material file with the following contents (or just use the one I have with the test map): //This is a brightround with a torch flicker. Very useful if you want to avoid light overlaps because you //can have a much brighter looking light at a much lower radius than with the standard torchlights. lights/brightround_torchflicker { lightFalloffImage makeintensity( textures/lights/brightround ) { forceHighQuality // no shadow down or up map textures/lights/brightround colored zeroClamp red ((.05 * sintable [(time * ( 2 + Parm3 ) ) ]) +.95) * Parm0 green ((.05 * sintable [(time * ( 2 + Parm3 ) ) ]) +.95) * Parm1 blue ((.05 * sintable [(time * ( 2 + Parm3 ) ) ]) +.95) * Parm2 } } 7) Select our light_extinguishable and open up the light editor (by default press L). In the light editor apply the brightround_torchflicker texture to our lights. You'll notice that when you do this the lights become, much, much brighter. In fact you may need to lower the light's brightness (also in the light editor) to get them looking normal. Tweak the brightness to your satisfaction and you should be good to go. Here's how the lights look in-game. You now have two working lamps stacked on top of each other without any overlap. The same trick can be used to have non-overlapping lights on either side of a thin wall, etc. Hopefully it'll be useful in your mapping endeavors . LightSolution.pk4.txt
  9. Nice, congrats on solving it. And sorry for telling you that monster-clipping wouldn't fix it . I would still recommend cleaning up the offending geometry though.
  10. No. You need to actually snap the angled brushes to grid to solve the problem, adding another brush on top of the offending brushes (even if it's textured w/ monster clip) won't solve it.
  11. I wouldn't be too worried, if these crashes started happening just recently, then that's because of recent brushwork. Just focus on new additions and you should be fine :-). Also, it's almost always going to be angled brushes, so that will narrow down what you need to look for.
  12. I had this issue several times when building Requiem. It always turned out to be a problem with brushwork not snapping to grid. The pause for a few seconds after dmapping is over is when dmap is compiling the AAS (to decide where the AI can go) and apparently unaligned brushwork can cause it to spazz out. Whenever I found the offending brushes and snapped them to grid (ctrl+G) the problem would go away. If you have func_statics made of brushes (especially those with angled geometry) I would revert them to worldspawn, snap them to grid, and then turn them back into FS too. I found that the best way to pinpoint the offending brushes was to find the earliest version of the map that didn't have the problem and then look at what brushes I had added in the subsequent version. Alternatively, start deleting big chunks of geometry (in a separate save obviously) until you don't get the crash anymore and that way you can track down what's causing the problem.
  13. Hm, the other simple solution I can think of is to raise the roof of tavern to be up to the top of the sky (or tall enough that you can stick a caulk/portal_sky pillar up to the ceiling and there's no viewpoint where the player will notice it). You could also just have one massive VP intersecting that section into two pieces (so the visportal would just run the length of the tavern).
  14. Is it possible to just make the speaker radii small enough that they don't overlap across the tavern?
  15. Haha, yes, it should feel right at home to Lich hunters everywhere .
  16. Not to get everyone's hopes up but... My main focus is still on writing my next novel, but it looks like I've got another FM in me . It won't be as ambitious or large as Requiem was, but here are a few screens of what will hopefully be a small two-level campaign. Crits and suggestions for improvement are welcome as always!
  17. Hey RJFerret, Just finished this mission, and really enjoyed it. Pros: Great sense of place. - With the unique setting and attention to detail, I really felt the world you were creating and wanted to find out more about it. Worldbuilding at it's best :-). Solid fundamentals - with the exception of getting stuck in the geometry once or twice (and one place in the mines where the game locked up for a few seconds), everything from the sound, to the performance, to the patchwork was solid and pleasant to look at/listen to. Clever Gameplay - From the setup of the AI in the camp to was fun and interesting. Cons: Level design/loot goal setup - Could have used more hints - I'm probably not the cleverest of players but I couldn't find the artifact without reading the spoiler in your first post. Also, Really nice first mission, especially how you built the world and created a strong sense of place. Looking forward to more!
  18. Moonbo

    Happy New Year

    Happy New Year everyone!
  19. Hey Springheel, And thanks for the write-up, I'm glad you enjoyed it. Thanks too for all the work you do for the Dark Mod community Springheel!
  20. For highlighting the door, you can use a spotlight instead of a point light, or you could have some glowing mushrooms in a flowerbed by the door. You might want to make the floor uneven too, and add some puddles. Right now it looks very dry, even w/ the rain coming down. Scene looks good though!
  21. Because the issue was fixed by turning some geometry into FS, I think it was likely just a hiccup with how the engine renders worldspawn. I had several instances with complicated geometry causing some really strange visual glitches (world polygons not rendering, textures turning pitch black, etc). By turning part of the geometry into func_statics, it simplified the worldspawn and the visual glitch went away. So probably this isn't a "bug" per-se as much a limitation of the renderer.
  22. Why not try getting rid of any caulk on the offending brushes, also you can try moving the light origin slightly off-center. If all else fails, also try erasing the brush/patch and rebuilding them, of turn them into a FS.
  23. Not to toot my own horn, but you might like to play Requiem. It's only one map, but it might scratch your #3 itch a little.
  24. Same here.
  25. Thanks Fieldmedic . And I have no idea why you're depressed, A Night to Remember is one of the best looking FMs I've ever played! As for the build time, from start to finish it took about 10 months to make Requiem (working pretty flat-out most of that time).
×
×
  • Create New...