ZScript Particle-Based Tracers

Sprites, textures, sounds, code, and other resources belong here. Share and share-alike!
Forum rules
Before posting your Resource, please make sure you can answer YES to any of the following questions:
  • Is the resource ENTIRELY my own work?
  • If no to the previous one, do I have permission from the original author?
  • If no to the previous one, did I put a reasonable amount of work into the resource myself, such that the changes are noticeably different from the source that I could take credit for them?
If you answered no to all three, maybe you should consider taking your stuff somewhere other than the Resources forum.

Consult the Resource/Request Posting Guidelines for more information.

Please don't put requests here! They have their own forum --> here. Thank you!
Post Reply
User avatar
DenisBelmondo
Posts: 379
Joined: Fri Jun 06, 2008 6:26 pm
Location: Two-Key Return
Contact:

ZScript Particle-Based Tracers

Post by DenisBelmondo »

Spoiler: Screenies
Before I go on, I gotta come clean. I am not completely sure if the code is completely sanitised and commented to be optimally helpful but I felt bad making people wait so I decided to just release it because making comprehensive documentation is a project in itself but I'm sure you fellas are smart enough to figure out how this works. The bullet class actually lerps between its previous coordinates and its current coordinates and draws a trail of particles in between with their individual sizes being proportional to its end position, meaning it makes a little tail at the end instead of being a long brick of particles. Though, this particular implementation is not without its caveats. The faster the bullet goes, the longer the trail is going to be because of the larger difference between xyzprevious and xyz.

If you wish, you can replace the particles with classes whose sprites are PUFFA0 but I figured out that it really chokes your PC, especially when additively rendered so if you use this in a project I advise you use the particles as opposed to actors. I also hope you don't mind crediting me. Thanx a bunch and have a ball.

Download link
Last edited by DenisBelmondo on Wed Oct 06, 2021 3:01 pm, edited 2 times in total.
User avatar
Nash
 
 
Posts: 17434
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: ZScript Particle-Based Tracers

Post by Nash »

Very cool but I imagine it won't look the same if the user sets their particle preference to round or smoothed. :D Still, good work!
User avatar
DenisBelmondo
Posts: 379
Joined: Fri Jun 06, 2008 6:26 pm
Location: Two-Key Return
Contact:

Re: ZScript Particle-Based Tracers

Post by DenisBelmondo »

Yeah an unfortunate drawback of the particle based tracers... if there was a SPF_FORCESQUARE I would definitely flip it on since the round and smooth styles don't look quite right in my opinion. Anyway, thanks so much!
User avatar
Matt
Posts: 9696
Joined: Sun Jan 04, 2004 5:37 pm
Preferred Pronouns: They/Them
Operating System Version (Optional): Debian Bullseye
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia
Contact:

Re: ZScript Particle-Based Tracers

Post by Matt »

Round version of this... now I want Bokeh Doom. Brütal Bökeh Doom.
User avatar
tsukiyomaru0
Posts: 295
Joined: Sat May 29, 2010 6:20 pm

Re: ZScript Particle-Based Tracers

Post by tsukiyomaru0 »

I actually think round looks better than squared. Otherwise, I really like this coding, it is actually very simple.
AlphaSoraKun
Posts: 409
Joined: Fri Feb 10, 2017 2:17 pm
Preferred Pronouns: He/Him
Graphics Processor: nVidia (Modern GZDoom)

Re: ZScript Particle-Based Tracers

Post by AlphaSoraKun »

Really nice.
User avatar
vólentiæn
Posts: 101
Joined: Fri Mar 25, 2016 10:44 pm
Location: Neuss, Germany

Re: ZScript Particle-Based Tracers

Post by vólentiæn »

well done... these look amazing
User avatar
Xeotroid
Posts: 436
Joined: Sat Jun 23, 2012 7:44 am
Graphics Processor: nVidia with Vulkan support
Location: Czech Rep.

Re: ZScript Particle-Based Tracers

Post by Xeotroid »

With particles set to smooth and bloom enabled, this looks particularly great!
dodopod
Posts: 66
Joined: Wed Oct 04, 2017 2:00 pm
Contact:

Re: ZScript Particle-Based Tracers

Post by dodopod »

Would you mind if I incorporated this into my weapons library? I was trying to implement my own tracers, but these look much better.

edit: I've gotten into a tinkering mood, so it'll probably be pretty heavily modified. That probably doesn't matter, but some people really hate it when others touch their work.
User avatar
Reactor
Posts: 2091
Joined: Thu Feb 03, 2011 6:39 pm
Location: Island's Beauty, Hungary

Re: ZScript Particle-Based Tracers

Post by Reactor »

Superb work, DenisBelmondo, you surely did a marvelous job! I was wondering, can it be tweaked some more, so it could be used for energy weapon shots? Like a Quake 3-style rail beam-like tracer for weapons like the Prism rifle.
User avatar
DenisBelmondo
Posts: 379
Joined: Fri Jun 06, 2008 6:26 pm
Location: Two-Key Return
Contact:

Re: ZScript Particle-Based Tracers

Post by DenisBelmondo »

Thanks a bunch you guys.

@dodopod Yeah go right ahead! So long as you provide credit and leave my little comments in the scripts.

@Reactor You should be able to make an energy weapon if you "override" the color table with values that represent various shades of energy blue or red. A more true-to-Q3 railgun iirc can be achieved if you set the particle spread and speed to 0 in a_railattack().
User avatar
DenisBelmondo
Posts: 379
Joined: Fri Jun 06, 2008 6:26 pm
Location: Two-Key Return
Contact:

Re: ZScript Particle-Based Tracers

Post by DenisBelmondo »

hey all, sorry for the bump. apparently google drive updated something about their security protocol bla bla bla and rendered all old drive links invalid. updated the first post with "The Good Link".

P.S. this mod was made before i knew anything about proper object oriented design. i should overhaul this with a Version 2 Rewrite, so look out for that.
User avatar
Redneckerz
Spotlight Team
Posts: 1050
Joined: Mon Nov 25, 2019 8:54 am
Graphics Processor: Intel (Modern GZDoom)

Re: ZScript Particle-Based Tracers

Post by Redneckerz »

DenisBelmondo wrote:hey all, sorry for the bump. apparently google drive updated something about their security protocol bla bla bla and rendered all old drive links invalid. updated the first post with "The Good Link".

P.S. this mod was made before i knew anything about proper object oriented design. i should overhaul this with a Version 2 Rewrite, so look out for that.
Great stuff man :) I am not sure how much it adds, but maybe this could be in official GZDoom as an option?
User avatar
ramon.dexter
Posts: 1520
Joined: Tue Oct 20, 2015 12:50 pm
Graphics Processor: nVidia with Vulkan support
Location: Kozolupy, Bohemia

Re: ZScript Particle-Based Tracers

Post by ramon.dexter »

Yes, thank you for this great stuff man :D
Post Reply

Return to “Resources”