Raised This Month: $ Target: $400
 0% 

[CS:GO] Beam of Parcticle


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
TheZipa
Junior Member
Join Date: Mar 2018
Old 12-21-2021 , 08:06   [CS:GO] Beam of Parcticle
Reply With Quote #1

Hi, I have a need to make a beam that consists of a particle and for this I have 2 points: the starting position and the ending one. Particle is an emitter that leaves a trail behind. Simply put, I want to make a ray from a trail of particle from point A to point B.

How can I operate with a particle so that a ray is formed from the starting point and the ending point?

PHP Code:
stock void SpawnParcticle(const char[] effect, const char[] targetname, const float pos[3], const float endpos[3])
{
    
int particle CreateEntityByName("info_particle_system");
    
    
DispatchKeyValue(particle "start_active""0");
    
DispatchKeyValue(particle"effect_name"effect);
    
DispatchKeyValue(particle"targetname"targetname); 
    
DispatchSpawn(particle);
    
    
//TeleportEntity(particle, pos, NULL_VECTOR,NULL_VECTOR);
    
TeleportEntity(particleendposNULL_VECTOR,NULL_VECTOR);
    
    
ActivateEntity(particle);
    
AcceptEntityInput(particle"Start");
    
    
char szBuffer[128];
    
FormatEx(szBuffersizeof(szBuffer), "OnUser1 !self:kill::%0.2f:-1"g_fLife);
    
SetVariantString(szBuffer);
    
AcceptEntityInput(particle"AddOutput");
    
AcceptEntityInput(particle"FireUser1");

This function so far just creates a particle at the endpoint and simply deletes it after a while

Last edited by TheZipa; 12-25-2021 at 09:36.
TheZipa is offline
Marttt
Veteran Member
Join Date: Jan 2019
Location: Brazil
Old 12-21-2021 , 10:18   Re: [CS:GO] Beam of Parcticle
Reply With Quote #2

You may need to target it with cpoint1_parent (1-63) attribute.

Check [ANY] Neon Beams
__________________

Last edited by Marttt; 12-21-2021 at 10:26.
Marttt is offline
TheZipa
Junior Member
Join Date: Mar 2018
Old 12-21-2021 , 13:04   Re: [CS:GO] Beam of Parcticle
Reply With Quote #3

Quote:
Originally Posted by Marttt View Post
You may need to target it with cpoint1_parent (1-63) attribute.

Check [ANY] Neon Beams
Could you show an example, please?
TheZipa is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:59.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode