AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   kill SVC_TEMPENTITY (https://forums.alliedmods.net/showthread.php?t=131807)

Flipper_SPb 07-09-2010 08:07

kill SVC_TEMPENTITY
 
I created a laser for one player:

PHP Code:

    message_begin(MSG_ONESVC_TEMPENTITY_player);
    
write_byte(TE_BEAMENTS);
    
write_short(ent);            // start entity
    
write_short(player);            // entity
    
write_short(sprite);    // precached sprite
    
write_byte(10);                    // starting frame
    
write_byte(15);                    // frame rate
    
write_byte(250);                    // life in 0.1's   so 30 should = 3 seconds
    
write_byte(60);                    // line width
    
write_byte(0);                    // noise amplitude
    
write_byte(255);                // r, g, b
    
write_byte(128);                // r, g, b
    
write_byte(0);                    // r, g, b
    
write_byte(255);                // brightness
    
write_byte(30);                    // scroll speed
    
message_end(); 

How to remove it on demand?

hleV 07-09-2010 10:36

Re: kill SVC_TEMPENTITY
 
PHP Code:

message_begin(MSG_ONESVC_TEMPENTITY_player);
write_byte(99); // check hlsdk const
write_short(player);
message_end(); 


Hunter-Digital 07-09-2010 14:12

Re: kill SVC_TEMPENTITY
 
Use constants so people know wth that is.... #99 is TE_KILLBEAM, it will kill all beams attached to entity.

hleV 07-09-2010 15:12

Re: kill SVC_TEMPENTITY
 
That's why I added "// check hlsdk const". I didn't write this code now, but a long time ago and didn't bother looking for a named version of the number.

Flipper_SPb 07-09-2010 18:04

Re: kill SVC_TEMPENTITY
 
Thanks.


All times are GMT -4. The time now is 07:09.

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