Raised This Month: $ Target: $400
 0% 

plugin snow


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
smiley92
Senior Member
Join Date: Jun 2011
Location: Romania
Old 12-13-2013 , 13:48   plugin snow
Reply With Quote #1

PHP Code:
#include < amxmodx >
#include <fakemeta>

#pragma semicolon 1
    
#define PLUGIN "Flares"
#define VERSION "0.0.1"

new const snowflakes[  ] = "sprites/snowflakes.spr";

new 
real_snow;
public 
plugin_init( ) {

    
register_pluginPLUGINVERSION"Askhanar" );
    
    
register_event"DeathMsg",  "EventDeathMsg",  "a" );
}

public 
plugin_precache(  ) {
    
real_snow precache_modelsnowflakes );
}


public 
EventDeathMsg(  ) {    

    new 
iVictim  read_data);
    new 
iKiller  read_data(  1  );
    
    if( 
iVictim  !=  iKiller ) {

        new 
Float:fOrigin], iOrigin];
        
peviVictimpev_originfOrigin );
        
FVecIVecfOriginiOrigin );
        
        
UTIL_CreateSnowiOriginreal_snowrandom_num4060 ), random_num1015 ), random_num510 ) );
    }
}



stock UTIL_CreateSnow( const iOrigin], const iSpriteID, const iCount, const iLife, const iScale ) {

    
message_beginMSG_BROADCAST,SVC_TEMPENTITY );
    
write_byteTE_SPRITETRAIL );
    
write_coordiOrigin] );                // start position (X)
    
write_coordiOrigin] );                // start position (Y)
    
write_coordiOrigin] );                // start position (Z)
    
write_coordiOrigin] );                // end position (X)
    
write_coordiOrigin] );                // end position (Y)
    
write_coordiOrigin] + random_num4060 ) );    // end position (Z)
    
write_shortiSpriteID );                // sprite index
    
write_byteiCount );                // number of snow
    
write_byteiLife );                    // life in 0.1's
    
write_byteiScale );                // scale in 0.1's
    
write_byterandom_num4055 ) );            // velocity along vector in 10's
    
write_byterandom_num1515 ) );            // randomness of velocity in 10'
    
message_end(  );

I have that plugin and not work properly.Coordonates position is not good.Can help make somebody to snow with that plugin better?
smiley92 is offline
Old 12-13-2013, 14:17
WopoXD
This message has been deleted by YamiKaitou. Reason: spam
mottzi
Veteran Member
Join Date: May 2010
Location: Switzerland
Old 12-13-2013 , 16:01   Re: plugin snow
Reply With Quote #3

What dou you mean with "postion is not good"? Explain a little bether please.
mottzi is offline
Send a message via MSN to mottzi
smiley92
Senior Member
Join Date: Jun 2011
Location: Romania
Old 12-14-2013 , 06:07   Re: plugin snow
Reply With Quote #4

Sprite with snow, don`t work good because positions of write_byte is not for that plugin.Now, I have that plugin, and origins is for another plugins, and don`t function properly, is snowing laterally.
smiley92 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 20:24.


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