Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Haloless0320

Flashlight in GZDOOM

Recommended Posts

Now that I think about it, this might be possible. I'm not very good with DECORATE and probably shouldn't be saying anything, but if there's a way to have the "gun flash" effect be sustained while the flashlight weapon is activated then that would be pretty cool.

EDIT: Actually, there's probably an even better way to do a flashlight in GZDoom than using gun flash. :P So never mind that...anyway, I think a working flashlight would be a great substitute for the lite-amp goggles, which make everything fullbright and therefore are lame.

Share this post


Link to post

Enjay's method is a stream of superfast (speed 184) projectiles with a dynamic light attached to it. It works rather well as long as you don't make too sudden movements in wide areas, where the non-instantaneous nature of the light breaks severely the illusion of a true flashlight.

Share this post


Link to post
Haloless0320 said:

Well I saw Enjay apply it in Burghead Liberation.So I'm wondering how he did it.


Uhm, open the wad and take a look then.

Share this post


Link to post
Jimmy91 said:

Couldn't you apply the dynamic lights to bullet puffs instead?

This is what I did in SpaceDM5 map20; it worked out pretty well.

Share this post


Link to post

Yes, however then you don't have a light beam -- you have a light that lights only at the point of impact, and not along the way as well.

Share this post


Link to post

The bullet puff method works better than the stream of projectiles method that I used in many, but not all circumstances.

If you use the stream of projectiles they don't move quick enough and as you wave from side to side it looks like you are hosing the area with light.

The puff method uses an instant hitscan attack (so it behaves a bit more like real light) but you have to remember to stop the attack causing enemies to bleed (which it will do even without damage) and one problem that can't be gotten around: the flashlight will still activate hit-activated lines/switches. That can't be disabled with hitscan attacks but it can with projectiles. So, your hitscan flashlight might end up opening doors, or smashing windows etc. And, as Gez said, you don't get a beam, just a point of light magically appearing where the attack hits.

Share this post


Link to post

@Kristus:XWE wouldnt let me open it.
@Enjay:Now that I think of it I remember there was a wad that Wild Weasel did named Cash.wad
In that wad you were able to buy a shotgun with a flashlight attached.It ran in EDGE I wonder if it can be converted to run in GZDOOM.

Share this post


Link to post
Haloless0320 said:

@Kristus:XWE wouldnt let me open it.
@Enjay:Now that I think of it I remember there was a wad that Wild Weasel did named Cash.wad
In that wad you were able to buy a shotgun with a flashlight attached.It ran in EDGE I wonder if it can be converted to run in GZDOOM.

The way I did it in ww-cash.wad was an invisible bullet puff with a dynamic light attached to it, and that puff was generated by having the weapon constantly firing a hitscan attack during its Ready state. That can easily be mimicked in GZDoom.

Share this post


Link to post

How do you make the size of the light static, as opposed to allowing the user to go into the options and change the size?

Share this post


Link to post
WildWeasel said:

That can easily be mimicked in GZDoom.

Yup, that's exactly the effect I was talking about. Unfortunately the inability to stop the flashlight activating impact lines reduced its usefulness for me. I requested an additional flag (or some other method) be added to the hitscan decorate pointer to disable its line activating properties but I don't think it has been yes/no'd yet. Perhaps it may just not be feasable.

Share this post


Link to post

This is all Greek to me...I need to read up on the Zdoom wiki some more.
But I am guessing you do this with XWE and not wHacKed 2.(Or maybe both?)

Share this post


Link to post

That helped a little,I still suck at scripting.Where do you think I should start?
The last game I scripted was a project I was working on for RPG maker 2000.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×