View Issue Details

IDProjectCategoryView StatusLast Update
0003332The Dark ModDef / Setuppublic14.03.2013 02:08
ReporterSpringheel Assigned Tograyman  
PrioritynormalSeveritynormalReproducibilityhave not tried
Status resolvedResolutionfixed 
Product VersionTDM 1.08 
Target VersionTDM 2.00Fixed in VersionTDM 2.00 
Summary0003332: Some electric lights not working recently
Descriptionhttp://forums.thedarkmod.com/topic/14539-some-electric-lamps-not-working/

Sometime over the last few months, some of our electric lamp entities have stopped working. This is one of them:


Quote

entityDef atdm:lamp_electric_shaded_lit
{
"inherit" "atdm:static_electric_light_lit_base"
"model" "models/darkmod/lights/non-extinguishable/lamp_shaded.lwo"
"editor_setKeyValue model" "models/darkmod/lights/non-extinguishable/lamp_shaded.lwo"
"editor_displayFolder" "Lights/Model Lights, Static/Switchable/Electric/Outdoor"

"skin" "lights/lamp_shaded_colorme"
"skin_lit" "lights/lamp_shaded_colorme"
"skin_unlit" "lights/walllight1_unlit"
"texture" "lights/biground1_squarelamp_snd"
"editor_usage" "A lit wall-mounted electric lamp with a shade on top. Can be switched on/off."
"noshadows_lit" "0" //metal hood needs to cast shadow
}


By not working, I mean the light (which use to flicker and hum) is not cast, and the texture of the lamp looks black. There is no hum either.

Additional InformationHmm, there may be more to this. I created a new light_flicker_104 soundshader and sound to go with it, but the lamps still aren't working.
TagsNo tags attached.

Activities

Springheel

Springheel

01.03.2013 22:38

administrator   ~0005121

This is not a D3 asset issue. I checked out the lamps in the "light_entity" map. In 1.08, one of each pair of electric lights is lit and the other is off, and if you flip the switch it reverses. Now, however, none of the ones that use a sounndshader to control their flickering were lit at the start. However, if I flipped their switch, they would then turn on and off and flicker properly.

So it seems like something has changed in the way those lights are turned on and off within the past few months.
Springheel

Springheel

09.03.2013 00:58

administrator   ~0005130

Ok, doing some more experimenting.

When light entities are set to start_off 1, they looks normal, with correct unlit skin.

When light entities are set to start_off 0 (the default), the s_shader plays correctly, however there is no light, and the lamp glass is black--the lit skin is not visible.
Springheel

Springheel

09.03.2013 15:26

administrator   ~0005137

Last edited: 09.03.2013 15:51

View 5 revisions

Just to keep track of what I've tried:

Changing the "s_shader" to "element_fire_fireplace" results in the proper sound being played. However the lamp skin is still black and no light is shown.

The "texture" "lights/biground1_streetlamp_4fold_snd" exists in the TDM folder structure and has no evident problems.

Ok...maybe I've been chasing the wrong problem. Just tried a light entity that inherited from "atdm:static_electric_light_lit_quiet_base" -- no hum, no flicker, yet it didn't work either.

Hmm. When I swap the lit skin with something else, the skin shows up properly. Still no light though.

For comparison, atdm:lamp_electric_fancy_up_lit seems to work fine. So what is the difference???

Springheel

Springheel

09.03.2013 16:03

administrator   ~0005138

Last edited: 09.03.2013 21:40

View 4 revisions

Ok, some small progress. When I take "atdm:lamp_electric_grill_lit", and change two things, it works:

"inherit" "atdm:static_electric_light_lit_quiet_base"

//"texture" "lights/lightgratelight_snd"

Changing the inherit line by itself didn't do anything, but once I commented out the texture line, the light worked. Tried just commenting the texture line out by itself, but looks like both changes are needed (because otherwise it inherits a different _snd texture).

 The problem is definitely with the "_snd" textures. Any electric lights that use them don't work when lit (the sound plays by the lamp glass is black and there is no light lit). Any electric light that does not use one of those textures works fine.

grayman

grayman

13.03.2013 15:21

administrator   ~0005170

I spent some time on this and quickly got lost.

So instead, I'm trying to find the rev where the error first appeared. This might take a while, but it'll be easier to ferret out how to fix the problem.

So far, rev 13280 (Dec 17), just before I made my lantern changes, works correctly.
grayman

grayman

13.03.2013 18:42

administrator   ~0005172

Last edited: 13.03.2013 18:44

View 2 revisions

13282, the lantern changes, works correctly.

13300 is also good.

Error occurred somewhere after 13300.

Moving on.

grayman

grayman

14.03.2013 00:17

administrator   ~0005173

Last edited: 14.03.2013 00:57

View 2 revisions

The first rev that has the problem is the one where I checked in the player sound changes.

The only change that I can think of that would affect lights would be not playing sound until the attack button is hit. I removed that change and the problem is still there. (It would cause a problem if the amount of light was dependent on the volume of sound. If there's no sound, there's no volume, and the light thinks it's supposed to be off. The lights are set up on frame 0, so delaying the sound would cause the problem.) But it must be something else.

Since my changes were all for sound propagation to the player, nothing else I changed comes to mind.

But it's mine to track down.

Edit: It was my change to delay starting sounds until frame 1. There were two parts, and I only backed out one. With both backed out, the problem goes away. I'll build a new DLL and put the situation with hearing sounds at the "Hit Attack" screen back to the way it was.

grayman

grayman

14.03.2013 01:13

administrator   ~0005175

Sorry for all the bother. I had no inkling that player sound changes would shut down lights.

Fixed in rev 13350.

Src. rev 5710

It's a new tdm_game01.pk4, so make sure you delete darkmod/gamex86.dll before testing.
Springheel

Springheel

14.03.2013 02:08

administrator   ~0005176

I don't think anyone could have anticipated that connection.

Issue History

Date Modified Username Field Change
01.03.2013 20:36 Springheel New Issue
01.03.2013 20:47 Springheel Assigned To => Springheel
01.03.2013 20:47 Springheel Status new => assigned
01.03.2013 22:36 Springheel Assigned To Springheel =>
01.03.2013 22:36 Springheel Target Version => TDM 2.00
01.03.2013 22:38 Springheel Note Added: 0005121
06.03.2013 01:15 Springheel Status assigned => new
09.03.2013 00:58 Springheel Note Added: 0005130
09.03.2013 15:26 Springheel Note Added: 0005137
09.03.2013 15:33 Springheel Note Edited: 0005137 View Revisions
09.03.2013 15:39 Springheel Note Edited: 0005137 View Revisions
09.03.2013 15:42 Springheel Note Edited: 0005137 View Revisions
09.03.2013 15:51 Springheel Note Edited: 0005137 View Revisions
09.03.2013 16:03 Springheel Note Added: 0005138
09.03.2013 16:05 Springheel Note Edited: 0005138 View Revisions
09.03.2013 16:16 Springheel Note Edited: 0005138 View Revisions
09.03.2013 21:40 Springheel Note Edited: 0005138 View Revisions
09.03.2013 21:41 Springheel Assigned To => grayman
09.03.2013 21:41 Springheel Status new => assigned
13.03.2013 15:21 grayman Note Added: 0005170
13.03.2013 18:42 grayman Note Added: 0005172
13.03.2013 18:44 grayman Note Edited: 0005172 View Revisions
14.03.2013 00:17 grayman Note Added: 0005173
14.03.2013 00:57 grayman Note Edited: 0005173 View Revisions
14.03.2013 01:13 grayman Note Added: 0005175
14.03.2013 01:13 grayman Status assigned => resolved
14.03.2013 01:13 grayman Resolution open => fixed
14.03.2013 01:13 grayman Fixed in Version => TDM 2.00
14.03.2013 02:08 Springheel Note Added: 0005176