Jump to content
The Dark Mod Forums

Newbie DarkRadiant Questions


demagogue

Recommended Posts

1 minute ago, STRUNK said:

@grayman

Oh sorry, I forgot to mention the doors. If they are open the sound goes through, if the are closed the sound is dimmed of course.

The biggest issue was the sound comming through the wall ...

If you've properly visportaled the run from the emitter to the listener, you shouldn't hear anything through the walls. If you do, you prolly have a worldspawn leak somewhere between emitter and listener.

  • Like 1
Link to comment
Share on other sites

So I've got a lever and a light (the grill light model specifically). I want it so that when the lever is in its "off" position, there is a red light showing. When the lever is turned on by the player, I want that red light to turn green. How can I do this?

Link to comment
Share on other sites

did read it and it's talking about caulk right away ... I think I'm just gonna test without caulk (and with sealing visportals) to see what happens : )

 

Yeah, that's poor wording. Caulk is just an invisible material. Any brushes using solid material would do.

Edited by peter_spy
Link to comment
Share on other sites

@Destined @Springheel

OK, I've figured out the problem, which only occurs when invoking the updated stock-distributed trigger_look.script found in tdm_base01. If you are using one of the earlier custom versions from the forum, the problem will not appear. Specifically, the update replaced 2 calls to a locally-defined function "length" with calls to system function "vecLength", but neglected to prefix it with "sys." This caused a divide-by-zero error and effective ignoring of the "tolerance" spawnarg. Please someone correct this in 2.08. [Corrected, tested replacement file attached]

Also, please someone add to the wiki entry that a stock script is available, so you don't *have* to use a custom script (except in the short term to get around this bug). BTW, the wiki did describe how to set up the custom script... I just misinterpreted the relevance of that discussion. Thanks, Destined, for setting me straight.

trigger_look.script

Link to comment
Share on other sites

Oh snap! So now my only concern is that I'm using the grill light color_me model, so I hope that the skin on the model changes as the light changes. I'll play around with it after work and see what happens

Link to comment
Share on other sites

@Amadeus

I was curious and went checking out this colorme grill light .. and the model doesn't change from a lightsource that ist not it's own. If it was only that simple : (

I think I would solve it myself by recreating this model in DR (I haven't got into other 3d programs) and making the glass from some matt transparent material that would be affected by the colored lights I suggested.

I am really curious, and have been looking for a trigger or something that can target individual spawnargs and their values, for that could open a lot of posibillities, but I can't find it, and probaly there is no such entity. Probably some scripting and/or stim/response is involved in changing the colorme light with a switch.

@Everyone : Is there an easy way to change/target spawnarg values with a switch/trigger?

Link to comment
Share on other sites

@Amadeus as far as I can tell TDM doesn't do skin toggles on models via simple/electric light entities, only if the light entity is one of those with a particle, scriptobjects etc. Well, maybe you can get a simple light entity to exhibit that behaviour by giving it the spawnarg "scriptobject" "light_ext". Then target the lamp model from one of the lights and give the lamp model skin_lit and skin_extinguished spawnargs.

@STRUNK there's a script function and a stim/response effect to change spawnargs - setkeyval - but, from what I know, changing spawnargs ingame rarely does anything because they're read at map start (when everything spawns). There are some exceptions, for example adding a target to an AI will get it to start patrolling if it didn't have a patrol previously. Changing spawnargs ingame can also be handy for scripting, as scripts can read spawnargs and respond according to what the spawnarg is at that moment.

Link to comment
Share on other sites

hmmm, thanks for the suggestions guys. I'll give it a try tonight. Is there a way I can hide the model and then trigger it to appear (and of course, trigger the other model to disappear)?

Link to comment
Share on other sites

Lamp entities and particle lights (i.e. light_oilflame) can toggle hide on targeted models if the models have "hide" "1" enabled. One light targets one model: as one light is off, one model will remain hidden at map start.

Could try my above suggestion of giving your plain lights a scriptobject, otherwise maybe reconfigure a light_oilflame entity to act like an electric light (= no particle model, no extinguish sound, all stim/response disabled).

Edited by Dragofer
  • Thanks 1
Link to comment
Share on other sites

1 hour ago, STRUNK said:

@Amadeus

I was curious and went checking out this colorme grill light .. and the model doesn't change from a lightsource that ist not it's own. If it was only that simple : (

I think I would solve it myself by recreating this model in DR (I haven't got into other 3d programs) and making the glass from some matt transparent material that would be affected by the colored lights I suggested.

I am really curious, and have been looking for a trigger or something that can target individual spawnargs and their values, for that could open a lot of posibillities, but I can't find it, and probaly there is no such entity. Probably some scripting and/or stim/response is involved in changing the colorme light with a switch.

@Everyone : Is there an easy way to change/target spawnarg values with a switch/trigger?

To see how I did it in WS5, open ws5_commerce.map in DR and search for this entity:

Switch11

It targets other entities, and by examining the group, and looking at the routines Toggle11() and ToggleRoom() in ws5_commerce.script, you should be able to figure out how to trim it all down to work for your case. Ignore script references to the 'panel indicator' and the 'door'.

 

Link to comment
Share on other sites

@Amadeus

This actually works! : )

https://streamable.com/hpzy3

I got 2 sliding  doors, about the same size of the  grill light, with spawnarg "translate_speed" set to 2000 (so fast it looks like it doesn't move), one with spawnarg "open" set to 0, the other one set to 1, and trigger them both with the same switch. Have 2 of these grill lights, one green and one red and bind the green to a sliding door, and the red to the other, .. one of them is always "hidden" in the wall, and the other visable.

Spawnarg "translate"  set to 20, on x,y or z, depending on the orientation, seems enough to hide the model, and you can use the first suggestion I did to light up the surroundings with a seperate red and green light.

5 hours ago, STRUNK said:

@Amadeus

My guess is to have 2 light sources, one green and one red, trigger them both with the switch, and have one set to spawnarg start_off 0, and the other to start_off 1 ..

I used this model: models/darkmod/lights/non-extinguishable/grill_light_short.lwo

 

Edited by STRUNK
  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
    • nbohr1more

      Please vote in the 15th Anniversary Contest Theme Poll
       
      · 0 replies
    • Ansome

      Well then, it's been about a week since I released my first FM and I must say that I was very pleasantly surprised by its reception. I had expected half as much interest in my short little FM as I received and even less when it came to positive feedback, but I am glad that the aspects of my mission that I put the most heart into were often the most appreciated. It was also delightful to read plenty of honest criticism and helpful feedback, as I've already been given plenty of useful pointers on improving my brushwork, level design, and gameplay difficulty.
      I've gotten back into the groove of chipping away at my reading and game list, as well as the endless FM catalogue here, but I may very well try my hand at the 15th anniversary contest should it materialize. That is assuming my eyes are ready for a few more months of Dark Radiant's bright interface while burning the midnight oil, of course!
      · 4 replies
×
×
  • Create New...