[ACS + Decorate] Atan's Tracer System

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!

[ACS + Decorate] Atan's Tracer System

Postby Arctangent » Tue Mar 31, 2015 7:43 pm

Something I've been wanting to try is making a tracer system that works with hitscans, and, well ...





I think I've succeeded.

Most of the system is ACS which is then called in Decorate, preferable by ACS_NamedExecuteWithResult because it can handle a fourth script parameter. The most basic usage can be done by adding the ACS and the BulletTracer actor directly to your project, then copying the modifications to the BulletPuff actor into the BulletPuffs you're using. More advanced use has brief documentation in the ACS source.

Download here.

Anyone's free to use this, just give credit to me somewhere.

Edit: Just realized a quick oversight meant that offsets were relative to the world, not to the firer's angle. While this could be worked around, I decided to fix this because it was kind of silly.
User avatar
Arctangent
squawky
 
Joined: 06 Nov 2014
Discord: SquawkyAtan#2371

Re: [ACS + Decorate] Atan's Tracer System

Postby Nash » Wed Apr 01, 2015 12:23 am

Wow, that's a good-looking tracer effect!
User avatar
Nash
 
 
 
Joined: 27 Oct 2003
Location: Kuala Lumpur, Malaysia
Github ID: nashmuhandes

Re: [ACS + Decorate] Atan's Tracer System

Postby Slax » Wed Apr 01, 2015 7:58 am

May wanna speed up the rate at which that stuff disappears. No more lasers.
Also, keep it invisible for a while after firing so it won't look like you're spewing said lasers out of your gut.
User avatar
Slax
Saucy.
... in loving memory ...
 
Joined: 19 Oct 2010
Location: Window office.

Re: [ACS + Decorate] Atan's Tracer System

Postby scroton » Wed Apr 01, 2015 11:32 am

Slax wrote:Also, keep it invisible for a while after firing so it won't look like you're spewing said lasers out of your gut.

You can use a dummy actor spawned with a_spawnitemex and an executewithresult script that returns the tid of the dummy actor and sets it to the player's/actor's user var and use the position of the dummy actor as the origin of the effect. You could also just calculate the offsets in the script itself.
User avatar
scroton
 
Joined: 27 Apr 2013

Re: [ACS + Decorate] Atan's Tracer System

Postby Arctangent » Wed Apr 01, 2015 12:24 pm

Slax wrote:May wanna speed up the rate at which that stuff disappears. No more lasers.
Also, keep it invisible for a while after firing so it won't look like you're spewing said lasers out of your gut.

That's all just for demonstration purposes; this system is pretty easy to modify ( it has infrastructure to support multiple tracer types, too ,so you could use it for a laser and still have bullet tracers ) so that the tracers appear and move to your liking.
User avatar
Arctangent
squawky
 
Joined: 06 Nov 2014
Discord: SquawkyAtan#2371

Re: [ACS + Decorate] Atan's Tracer System

Postby Sinael » Wed Apr 01, 2015 8:40 pm

I think something like that (if not exactly that) was used in Dakka, except Dakka did it better IMO.
User avatar
Sinael
Russian Ripman
 
Joined: 18 Oct 2011

Re: [ACS + Decorate] Atan's Tracer System

Postby RikohZX » Thu Apr 02, 2015 1:48 pm

It does seem like standing in something like the Underhalls water causes the tracers to come from your face rather than your body due to the hitbox wonkiness involved with all that. Definitely an interesting means of seeing hitscan patterns at work otherwise, though.
User avatar
RikohZX
 
Joined: 05 Sep 2012

Re: [ACS + Decorate] Atan's Tracer System

Postby Arctangent » Thu Apr 02, 2015 2:18 pm

RikohZX wrote:It does seem like standing in something like the Underhalls water causes the tracers to come from your face rather than your body due to the hitbox wonkiness involved with all that. Definitely an interesting means of seeing hitscan patterns at work otherwise, though.


I'm going to guess this is because fake 3D liquids don't affect the height of the player, just their view height. At least, that's the only reason I can think of causing that, considered by the default Doom flats are as solid as any other regardless of if they're animated or not.

Still, if you give the player's weapons a unique bullet puff, you can expand the include "Get Target Property" script to add an option to get the view height instead, then use that in the player's bullet puff's tracer call. The usage of the actor's height for a z-offset is not hard coded at all.
User avatar
Arctangent
squawky
 
Joined: 06 Nov 2014
Discord: SquawkyAtan#2371

Re: [ACS + Decorate] Atan's Tracer System

Postby WARCHILD_89 » Wed May 13, 2015 6:45 am

I used the tracer in Particle fire enhancer and recoded it to be fired as missile, so I do not have any Hitscans in any weapon of my mod AND I can define Damage and damage type by defining a new tracer inheriting from the basic one. The next step would be to add a 3d model to it. The tracer does also work with "Ketchuptest.pk3" (brutal doom style blood)


So you get nice looking tracers which have the hitscan particle effects when hitting a wall. Honestly I haven´t seen anything better yet, but your version is well for people who do NOT use the particle fire enhancer.


NOTE: What exactly were you trying to do? I did not get why ACS is used.....
Last edited by WARCHILD_89 on Wed May 13, 2015 6:58 am, edited 2 times in total.
User avatar
WARCHILD_89
DOOM NEMESIS / 3D MODELS / RESOURCE BACKUPS
 
Joined: 17 Nov 2013
Location: MIA between doomed dimensions

Re: [ACS + Decorate] Atan's Tracer System

Postby TheBadHustlex » Wed May 13, 2015 6:55 am

I'd make 'em a little thinner, they look like lasers right now. But otherwise not bad.
User avatar
TheBadHustlex
Better than stalin.
 
Joined: 03 Oct 2013
Location: 'stria

Re: [ACS + Decorate] Atan's Tracer System

Postby Arctangent » Sat May 16, 2015 5:39 pm

WARCHILD_89 wrote:NOTE: What exactly were you trying to do? I did not get why ACS is used.....


Basically, you execute the included script via a hitscan's bullet puff, then it'll draw a line of particles from the firer's location to the puff's. It's a bit more complicated than that, however, as the line "travels" over time, choosing the faster of a set speed or a duration ( so that long-range hitscans don't have the tracer hit five seconds after the bullet puff's already gone, while keeping the tracer from going too slow if the distance it has to travel isn't that long ).

TheBadHustlex wrote:I'd make 'em a little thinner, they look like lasers right now. But otherwise not bad.


Ideally, someone using these would define their own tracers that fit the weapons. There's documentation on how to do this in the source.

One of the things I made with messing with these was actually a laser, so y'know.
User avatar
Arctangent
squawky
 
Joined: 06 Nov 2014
Discord: SquawkyAtan#2371

Re: [ACS + Decorate] Atan's Tracer System

Postby WARCHILD_89 » Mon Jul 20, 2015 2:39 am

ok you seem to want to get some specific effect. Maybe it´s not cpu usage intensive?

My weapon tracers just work like missiles with different speeds, damage values and damage types. So when I fire e.g. my shotgun, it fires a bunch of tracers, spawning blood when hitting bleeding actors, junk when hitting eg an enemy tank with +NOBLOOD flag set and sparks when hitting a wall. I have no Puff types at all.

I remember my old laptop could not handle this and my fps got down.
User avatar
WARCHILD_89
DOOM NEMESIS / 3D MODELS / RESOURCE BACKUPS
 
Joined: 17 Nov 2013
Location: MIA between doomed dimensions

Re: [ACS + Decorate] Atan's Tracer System

Postby Thfpjct » Thu Jul 18, 2019 9:42 pm

There is some way to change the tracer position?
like, from where on screen it comes out?
Thfpjct
 
Joined: 19 Jul 2019
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: Intel (Legacy GZDoom)


Return to Resources

Who is online

Users browsing this forum: Doom_Boi, Woolie Wool and 4 guests