Raised This Month: $51 Target: $400
 12% 

Adding lightning + sound to slay


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bobbobagan
SourceMod Donor
Join Date: May 2007
Location: New Zealand
Old 07-12-2009 , 10:30   Adding lightning + sound to slay
Reply With Quote #1

Hey all,

I have been attempting to modify slay.sp to add lightning + sound. I have taken the lightning effects and sound from the Uberpunisher plugin (http://forums.alliedmods.net/showthread.php?t=58660), and tried to add it in.

I managed to get the plugin to compile, but it only plays the sound... no lightning effect. See the attached slay.sp to see what I have done.

Does anybody know what I am doing wrong here?

Regards,

Bobbobagan
Attached Files
File Type: sp Get Plugin or Get Source (slay.sp - 195 views - 7.8 KB)
__________________

Last edited by bobbobagan; 07-12-2009 at 10:53.
bobbobagan is offline
Send a message via Skype™ to bobbobagan
bobbobagan
SourceMod Donor
Join Date: May 2007
Location: New Zealand
Old 07-14-2009 , 00:01   Re: Adding lightning + sound to slay
Reply With Quote #2

Bump. Please help me!
__________________
bobbobagan is offline
Send a message via Skype™ to bobbobagan
bobbobagan
SourceMod Donor
Join Date: May 2007
Location: New Zealand
Old 07-31-2009 , 03:34   Re: Adding lightning + sound to slay
Reply With Quote #3

bump again
__________________
bobbobagan is offline
Send a message via Skype™ to bobbobagan
TESLA-X4
Senior Member
Join Date: Dec 2008
Location: $Recycle.Bin
Old 07-31-2009 , 03:39   Re: Adding lightning + sound to slay
Reply With Quote #4

That's because you're setting up the TempEnts, but not sending them.
Code:
    TE_SetupBeamPoints(toppos, playerpos, g_Lightning, g_Lightning, lightningstartframe, lightningframerate, lightninglife, lightningwidth, lightningendwidth, lightningfadelength, lightningamplitude, lightningcolor, lightningspeed);
    TE_SetupExplosion(playerpos, g_ExplosionFire, 10.0, 10, TE_EXPLFLAG_NONE, 200, 255);
    TE_SetupSmoke(playerpos, g_Smoke1, smokescale, smokeframerate);
    TE_SetupSmoke(playerpos, g_Smoke2, smokescale, smokeframerate);
    TE_SetupMetalSparks(sparkstart,sparkdir);


    TE_SendToAll(0.0);
In effect, you only sent the last one (MetalSparks).
It should be:
PHP Code:
    TE_SetupBeamPoints(topposplayerposg_Lightningg_Lightninglightningstartframelightningframeratelightninglifelightningwidthlightningendwidthlightningfadelengthlightningamplitudelightningcolorlightningspeed);
    
TE_SendToAll();
    
TE_SetupExplosion(playerposg_ExplosionFire10.010TE_EXPLFLAG_NONE200255);
    
TE_SendToAll();
    
TE_SetupSmoke(playerposg_Smoke1smokescalesmokeframerate);
    
TE_SendToAll();
    
TE_SetupSmoke(playerposg_Smoke2smokescalesmokeframerate);
    
TE_SendToAll();
    
TE_SetupMetalSparks(sparkstart,sparkdir);
    
TE_SendToAll(); 
TESLA-X4 is offline
retsam
Veteran Member
Join Date: Aug 2008
Location: so-cal
Old 07-31-2009 , 07:03   Re: Adding lightning + sound to slay
Reply With Quote #5

Someone has actually done a separate plugin already that does this, might check it out..

http://forums.alliedmods.net/showthr...=admin+thunder
retsam 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 00:31.


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