Jump to content
The Dark Mod Forums


Active Developer
  • Posts

  • Joined

  • Last visited

  • Days Won


stgatilov last won the day on March 18

stgatilov had the most liked content!


3023 Deity


About stgatilov

  • Birthday 08/26/1989

Contact Methods

  • Website URL
  • Jabber

Profile Information

  • Gender

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. I tried the script on the core assets, and find an interesting case called textures/darkmod/metal/flat/tiling_1d/gen_smooth_gold01 This material has time-dependent envmap color: { blend add maskalpha cubeMap env/gen1 red sintable[time*0.1] green sintable[time*0.1] blue sintable[time*0.1] texgen reflect } I wonder whether it was intentional or not. Here is how it looks: I suppose it would be worthwhile to manually review the modified materials, because in some cases the color adjustment was actually meaningful...
  2. If you did not delete the contents of the directory where you installed TDM with tdm_installer, all the log files should be there. Their filenames are suffixed with data&time, so they can only be removed manually. If you find them, you can just share all of them, I'll find the error in the logs.
  3. Yes, this behavior of DR would become a big problem after this change. Because all sound sources will be efficiently muted... Meanwhile, I think most of the maps were created before this behavior. So other opinions on setting zero sound spawnargs are welcome.
  4. I have DR 3.0.0. (I rarely update it since I rarely use it)
  5. I imported them into DR, still don't see any s_xxxDistance spawnargs there:
  6. So the sound has full volume on distances up to minDistance, and no volume at distances above maxDistance. I have not found any special meaning for maxDistance = 0 in the code, so I assume such a sound will never be heard due to zero volume. Also, there are some default values littered around the code. Most importantly, sound shader gets minDistance = 1 and maxDistance = 10 by default. Also I think I have seen min=0, max = 10 somewhere in the code. There is little difference between minDistance = 1 and minDistance = 0. Mostly the difference is that fading does not happen within 1 meter of the sound source. Supposedly, setting minDistance = maxDistance = 0 will cause sound to be completely muted. If you want a sound to always have full volume, I think you should set e.g. minDistance = maxDistance = 1000. Of perhaps set "global" flag instead, which disables distance computation completely. Although this probably has different effect (like maybe global sound passes through walls too). Or if you want it to be sharply disabled at 10 meters, then set minDistance = maxDistance = 10... but I see no point in sounds that can be disabled based on distance without any fade. Finally, as I have described at the very beginning of the post, "minDistance" "0" as spawnarg has no effect on current TDM versions. I don't see mindistance/maxdistance settings in these two prefabs in SVN. Maybe this were the issues that someone fixed recently. Or... could it be that you confuse spawnargs with sound shader settings? Actually, I don't see the distance settings on sound shaders either.
  7. As far as I see in the code, minDistance/maxDistance specify the range in meters where volume falloff happens. Let's introduce F(d) as piecewise linear function. Then: F(0) = F(minDistance) = 1 F(maxDistance) = F(+infinity) = 0 F(d) changes linearly from minDistance to maxDistance The sound gain is multiplied by F(d)^2 (i.e. falloff is turned quadratic). If we talk about real physics, the falloff from point sound should linear without any caps. The gain should be multiplied by (1 / d). However, real sound sources are never perfectly concentrated at a point. If a sound source has size S, then the volume at distances up to O(S) will look like constant. I suppose default minDistance is nonzero to replicate this effect. The existence of maxDistance is harder to justify physically. Perhaps it is here for optimization reasons (don't process sounds farther than this). As for quadratic falloff instead of linear, I think the simply wanted the sound to fade away to zero smoothly.
  8. I implemented a tool to replace spawnarg automatically. Here is the list of missions using the paradigm of settings zero sound spawnargs: I wonder: does it happen automatically in DarkRadiant somehow? Or everyone explicitly specify zero? And if you intentionally specify zero, what do you want to achieve this it?
  9. https://bugs.thedarkmod.com/view.php?id=6509 Which stages of debriefing (GUI and video) should happen first?
  10. Yet another breaking change, I'm afraid: 6346 Sounds have a bunch of parameters: minDistance maxDistance volume shakes soundClass The base value for each parameter is set in sound shader. However, it can be overridden with a different value in spawnargs (e.g. "s_volume" "-10") or in C++ engine code with SetSoundVolume (used extensively for footsteps). Unfortunately, Doom 3 engine has a special case: setting some parameter to zero means it will not override the base value. So there is no way to override sound volume with 0, because setting zero would mean "use value from sound shader", while setting 0.1 or -0.1 would mean "use volume = 0.1 or -0.1". This behavior causes confusion. It is especially bad when volume is set programmatically, because e.g. volume of player footsteps is computed as a sum of many modifiers (run, crouch, creep, in water, etc.) and it is hard to be sure you don't get zero sum in the end. The idea is to fix this mess and add a "don't override" special value in the system. Speaking of spawnargs, it would work like this: "s_volume" "13.4" = override with value 13.4 "s_volume" "0" or "s_volume" "0.0" = override with zero "s_volume" "" (empty string) = don't override Right now there are tons of zero values set in these spawnargs. It is not clear where the author intended to override with zero, and where he wanted to drop inherited override and use base value. I guess for compatibility reasons I'll have to replace spawnargs "s_volume" "0" with "s_volume" "" in all missions.
  11. And making it possible for the new electric lights to be broken adds a psychological problem: how will players know that they are breakable if in 99% missions they are not? Recall lootable paintings and frob-extinguishable unmoveable candles.
  12. A visually breaking change is planned for 2.13 (6354). Environment mapping is used when material contains a stage like this: { blend add cubeMap env/gen3 texgen reflect } Historically, there are two separate shaders for this case: one if the material has bumpmapping, and one if it does not. Note that if the material has diffuse or specular stage, then bumpmap is added implicitly. The shader with bumpmap was apparently "tweaked" by someone in TDM and got several major differences: it has fresnel term output color is tonemapped to [0..1] range using X / (1 + X) the color multiplier is hardcoded to (0.4, 0.4, 0.4) I'd like to delete all of these differences and restore the same behavior as in non-bumpmapped case. It is also the same behavior which is used in both cases in Doom 3 BFG (and supposedly in Doom 3 too). Speaking of points 1 and 2, nobody will notice the difference except in rare corner cases. The point 3 however is serious. It is also the main reason behind the change. Right now nobody can tweak the intensity of environment mapping: if you try to set red/green/blue/rgb, these settings are simply ignored. Now the problem is that the intensity of most environment mapping materials will change. In core files I see text like this (stainglass_saint_01) : { blend add maskalpha cubeMap env/gen3 // tone down the reflection a bit //I see no evidence that these values do anything red Parm0 * 0.2 green Parm1 * 0.2 blue Parm2 * 0.2 texgen reflect } Since the default parameter was 0.4, after the change this material will get 2x less intensity. The situation is even worse if rgb multiplier is not specified, since then it will change from 0.4 to 1.0, i.e. envmapping will become 2.5 times brighter. I can probably collect the list of all materials using environment mapping, but I'm not sure I'll be able to check them all one by one. Perhaps I can delete existing rgb settings, blindly set "rgb 0.4" and hope for the best.
  13. It would be great if you attach all the tdm_installer_NNNNNNNNNN.log files, maybe I'll see something interesting there. You can try to enable "Advanced Settings \ No multipart byteranges", maybe something in your networks breaks them. But yes, getting the full download is the easier solution if you don't intend to switch between various versions.
  14. I think yes. The root of the issue is always an opaque wall (in terms of areas/visportals) which does not cast shadows (in terms of lighting). Shadowcaulk is both opaque and casts shadows, so there is no contradiction.
  • Create New...