Jump to content

Project: Extinguish small lights with a blow


snatcher
 Share

Recommended Posts

EDIT: You can find a demo in this post (v0.7)

----------------------------------------------------------

Welcome.

Feel free to participate but I ask you to restrain from discussing whether we should or should not do it. We are going for it in this topic. For the practical or philosophical debate please head to: Should small static oil lamps be extinguishable up close?

----------------------------------------------------------

THE IDEA: To have the ability to extinguish small lights with a swift but quiet blow.

THE VISION: When no item is selected in the inventory, and upon pressing the use key, Corvan performs a swift but quiet blow that can extinguish small lights located within the radius of the blow.

EDIT - Potential side issues to take into account in the future

  • It shouldn't work under water
  • It shouldn't work when carrying a body
  • It shouldn't work when holding any object

----------------------------------------------------------

OIL LAMPS: When I started playing TDM I was frustrated to find out I could not extinguish small oils lamps located right in front of my face. What the? Candles yes but oil lamps no? It turned oil lamps where created during a time the development of the game had a big momentum and oil lamps where offered to mappers without a second thought. Mappers started using oil lamps - under the assumption that only water arrows can extinguish them - and by the time people started wondering why oil lamps could not be extinguished with the fingertips or with a blow the matter was deemed "too late" for any change.

I believe that having the ability to easily extinguish ANY small light can improve the experience in the long run and I am set out to change course in this regard, regardless of how some members of this community feel about it.

Wesp5's Unofficial Patch offers a workaround that I am not fan of because the moment you put a light out the oil lamp remains frobable thus making the implementation inconsistent. Besides, oil lamps could perfectly trigger an action (ie: unveil a hidden secret) but since all oil lamps are frobable players don't get the required feedback.

THE FLINT: When I started playing TDM I was impressed by AI. I clearly remember the moment I put a candle out but moments later I found it was lit. What the? I put the candle out again and waited in the shadows. A builder comes in, puts a flint out a relights it. I was amazed. I need to get one of those flints, I thought. A few missions later I finally got to have one.

The flint was the key: I started toying with the flint and I realized at its core the flint basically is a stim of fire. I changed the stim of fire for a stim of water and voila, I could extinguish lights with the modded flint. The problem now is that the modded flint extinguishes all lights and fires, large and small but hey, things are heading in the right direction.

I am not yet ready to publish any files but I already need a lot of help from experienced modders and developers. Here is my main concern at this point:

Do you think it would be possible to detect if a stim is colliding with large lights?

Or

Do you think the impact of a stim can be limited to certain entities?

Or

Any other ideas to limit the impact of a water stim to small lights only?

Cheers!

Edited by snatcher

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

Why would a flint put out fire? That makes even less sense that the slow matches TDM uses right now to relight fires again. As for making oil-lamps not frobable after they have been extinguished, I see if I can fix that in the patch...

Edited by wesp5
Link to comment
Share on other sites

6 minutes ago, wesp5 said:

Why would a flint put out fire?

I didn't explain myself well or you didn't understand where we stand today and what the goal is. Check "The vision".

5 minutes ago, wesp5 said:

As for making oil-lamps not frobable after they have been extinguished, I see if I can fix that in the patch...

I suggest you to proceed carefully. Mappers, in example, could make wall-mounted oil lamps trigger other actions therefore oil lamps should not be forced to be non-frobable.

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

1 hour ago, snatcher said:

I didn't explain myself well or you didn't understand where we stand today and what the goal is. Check "The vision".

Ah, I understand now. So the flint will be just an invisible internal tool or do you plan a hand animation of some kind? Otherwise I don't see much difference to the current solution and also the problem that I think it's hard to have no inventory item selected, or did you mean nothing selected that has another function? As for the frobable extinguished lamps, I'll have to check how that works with candles...

Edited by wesp5
Link to comment
Share on other sites

No animations, no. It's a virtual blow using the mouth therefore players will only get to hear a blow sound. If the player is close enough to the small light, and looking in the right direction, the light will be extinguished.

The "modded flint" or the blow will be an internal, built-in tool ready for action only when nothing else is selected. Empty inventory > press use > blow. We have the dedicated key to "Clear Inventory" so it can be selected rather easily.

That's the idea anyway. Question is, does the engine allow for all this to be scripted.

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

All flames are setup to be extinguished when they come into contact with water stims (steam is something different than stim). You can't give something a water stim that should only extinguish some flames.

Link to comment
Share on other sites

Players are trained to extinguish small light sources by interacting with them - if this element is important for whatever reason you could consider just altering the extinguished sound on your item defs to be the sound of the player blowing. 

That or use action script on the small flame source to create the water stim and sound effects you want instead of letting the player create it at will.

Given many “visions” are being developed in parallel perhaps you should consider aggregating them in something like an unofficial patch development thread.

Edited by Wellingtoncrab
Link to comment
Share on other sites

51 minutes ago, Dragofer said:

(steam is something different than stim).

Steam replaced with stim the OP. Thanks.

53 minutes ago, Dragofer said:

You can't give something a water stim that should only extinguish some flames.

Clear. I am not sure what "magnitude" is exactly for but I played with very low magnitude values and didn't notice any improvement. A single particle of water (or gas) - it seems - is all that's required to extinguish large or small fires/lights.

I started thinking since about collisions and limitations by class, object, entity....

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

12 hours ago, snatcher said:

single particle of water (or gas)

The Stim&Response system has nothing to do with particles. It's a signaling system. If an entity with a response to water is within the radius of the water stim, the response gets triggered. Think of it like a sound for example.

The magnitude might only be important for specific stims, and the respective information would be needed to be evaluated by the response action. I am not sure whether there is a stim currently using this, though.

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

Can we tell if Corvan is directly looking at a particular entity / object / type? I mean, would it be possible to detect if, in example, below types are within a 30cm radius cone from Corvan's eyes?

light_candleflame
light_candleflame_moving

If this is possible we could always get the blow sound but trigger the stim only if the requirement is met.

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

Do you see this working?

  1. No items in inventory (secondary:  not under water, not carrying a body)
  2. Player presses use key
  3. Blow sound
  4. If an object class or list of objects is/are within a radius (secondary: vision cone) of the player, then trigger the stim

Let's not over-complicate anything (secondary requirements or extras). We first need a working example.

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

In the meantime I figured out why you can frob extinguished oil-lamps: you need to be able to do that in case the player or a guard relights them latter and you want to turn them out again. So is there a way to hide the frob highlight if a oil-lamp is unlit or even make it not frobable then? Also I can't remember a secret switch being triggered by a oil-lamp...

Link to comment
Share on other sites

6 minutes ago, wesp5 said:

In the meantime I figured out why you can frob extinguished oil-lamps: you need to be able to do that in case the player or a guard relights them latter and you want to turn them out again. So is there a way to hide the frob highlight if a oil-lamp is unlit or even make it not frobable then? Also I can't remember a secret switch being triggered by a oil-lamp...

I toyed with your implementation a couple of weeks back and I couldn't figure out anything (strictly sticking to functions and variables at hand). I then started thinking about alternatives.

5 minutes ago, wesp5 said:

Also I can't remember a secret switch being triggered by a oil-lamp...

Most probably but extinguished torches are often used as triggers in crypts so we should expect the unexpected.

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

By "blow" I'm guessing you mean an exhalation rather than hitting the light source with your hand, if that's wrong then ignore me

If that's right I can understand why it shouldn't work underwater but not when carrying a body/holding an object, neither of which would limit the protagonists ability to blow out a small light source such as a candle, maybe not an oil lamp which as I remember have a mechanical means of lowering/raising the wick to extinguish the flame

Link to comment
Share on other sites

1 hour ago, snatcher said:

I toyed with your implementation a couple of weeks back and I couldn't figure out anything (strictly sticking to functions and variables at hand).

It's easy to set the oil-lamp to only be frobable when lit or to make it not frobable when extinguished, but then you can't frob the relighted lamp anymore.

Link to comment
Share on other sites

Posted (edited)

EDIT: please check this post for the newest version.

---------------------------------------------------------------------------------

Here is a TOTALLY ROUGH example.

How to use:

  • Add download contents to TDM (I recommend using a Mod Enabler)
  • Launch a mission
  • Open the console and spawn two items:
spawn atdm:playertools_blow
spawn atdm:playertools_flint
  • Pick them up
  • Switch between items for one action or the other

Please note you can extinguish any flame, large or small. This is a sample to get a feel of the idea. Nothing else.

 

BlowFlint_Sample_v0.1.zip

Edited by snatcher
  • Like 2

TDM Modpack v1.8 (25/09/2022) - Visit:

Snatcher's Workshop - Mods for The Dark Mod

Link to comment
Share on other sites

3 hours ago, wesp5 said:

So is there a way to hide the frob highlight if a oil-lamp is unlit or even make it not frobable then? Also I can't remember a secret switch being triggered by a oil-lamp...

You can add a line to the tdm_lightholder script's extinguish/relight functions to disable or enable frobability.

You can also check whether the lamp has the "frobable" "1" spawnarg set. This indicates the mapper wants the player to frob the oil light, i.e. for a secret, so you should do nothing in that case.

Link to comment
Share on other sites

2 hours ago, snatcher said:

Thanks for participating.

Excuse my English: yes, by "blow" I mean an exhalation.

The "use" key is reserved when carrying / holding an object so unless a better idea pops up we will have to make some concessions.

Well we can open unlocked doors while carrying a body, why not use the same mechanism, frob/interact as I remember ?

It would still leave carrying objects as an exclusion but they're easier to put down & pick up again, it can be difficult to drop a body if space is tight also they can be noisy when they get dropped

Link to comment
Share on other sites

1 hour ago, Dragofer said:

You can add a line to the tdm_lightholder script's extinguish/relight functions to disable or enable frobability.

I already did that and it works fine, only you can't extinguish the lamp if you ignite it again. This will probably happen very rare if ever so it would be a good enough solution, but then having the lamps highlight up on frob doesn't really disturb me anyway! For a real solution we would need to enable frobing again after stim_fire and I have the same problem like snatcher here, because unless I can differentiate fire sources, fireplaces and torches will suddenly become frobable too...

Edited by wesp5
Link to comment
Share on other sites

9 minutes ago, wesp5 said:

I already did that and it works fine, only you can't extinguish the lamp if you ignite it again. This will probably happen very rare if ever so it would be a good enough solution, but then having the lamps highlight up on frob doesn't really disturb me anyway! For a real solution we would need to enable frobing again after stim_fire and I have the same problem like snatcher here, because unless I can differentiate fire sources, fireplaces and torches will suddenly become frobable too...

Did you also add a line to the ignition function? It sounds like you only modify frobability with extinguishing.

For letting this apply only to small exposed oil flames you can check whether the light's model spawnarg is "light_oilflame.prt".

Link to comment
Share on other sites

42 minutes ago, Dragofer said:

Did you also add a line to the ignition function? It sounds like you only modify frobability with extinguishing.

For letting this apply only to small exposed oil flames you can check whether the light's model spawnarg is "light_oilflame.prt".

I did add a line to ignition functions, but this only works on lamps that can be turned off and on, so it's not really needed as I will keep them frobable anyway. Normal oil lamps need a fire stim to be relit though and I haven't dared yet to change anything there because the stim code looks even more difficult than the normal one ;)! It's in tdm_light_holders.script, no?

Edited by wesp5
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.

 Share


  • Recent Status Updates

    • nbohr1more

      Anyone have any luck with light.setShader( string ) ? It seems to make whichever light you apply it to full-bright on the initial invoke?
      · 0 replies
    • thebigh

      I'm starting to think we need another mapping contest.
      · 9 replies
    • kano

      Don't you hate it when there's a quality discussion on a forum somewhere online about something, but then two disagreeing users derail and transform it into a back-and-forth poo slinging competition at one another?
      · 9 replies
    • Diego

      Oh look the status updates are back! 
      · 2 replies
    • JackFarmer

      After watching the first three and a half episodes of "The Sandman" last night, I realize once again that overly imaginative narratives are not for me. Also, the main actor looks like he has a toothache.
      Which makes me wonder, is there a Dark Mod mission with a medieval dentist?
      · 4 replies
×
×
  • Create New...