Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //===================================== Spree System ====================================================//
- function GetPlayerSpree(player)
- {
- return status[player.ID].KillingSpree;
- }
- function SetPlayerSpree(player)
- {
- status[player.ID].KillingSpree = 0;
- }
- function IncPlayerSpree(player)
- {
- status[player.ID].KillingSpree = GetPlayerSpree(player);
- }
- function DecPlayerSpree(player)
- {
- status[player.ID].KillingSpree = GetPlayerSpree(player);
- }
- //==============================================================================
- function StartKillingSpree( player )
- {
- if ( GetPlayerSpree( player ) >= 5 )
- {
- local kills = GetPlayerSpree(player);
- if ( kills == 5 ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!!!" );
- else if ( kills == 10 ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!! " );
- else if ( kills == 15 ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!! " );
- else if ( kills == 20 ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!! " );
- else if ( kills == 25 ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!!! " );
- else if ( ( kills >= 30 ) && ( kills % 5 == 0 ) ) spi( "[Spree] - " + player + " is on a killing spree with " + kills + " kills in a row!!! " );
- }
- }
- //==============================================================================
- function EndKillingSpree( p1, p2 )
- {
- if ( GetPlayerSpree( p1 ) >= 5 )
- {
- if ( p2 == 255 )
- {
- EMessage("[Spree] - Noob " + p1.Name + " he has ended their own killing spree.");
- DecPlayerSpree(p1, GetPlayerSpree(p1));
- }
- else if ( p2 != 255 )
- {
- EMessage( "[Spree] - " + p2.Name + " ended " + p1.Name + "'s killing spree of " + GetPlayerSpree(p1) + " kills in a row.");
- DecPlayerSpree(p1, GetPlayerSpree(p1));
- IncCash( p2, 1500 );
- PrivMessage( "[Spree] - You have ended the killing spree of " + p1.Name + "", p2 );
- }
- }
- }
- //============================= End Of Spree System =====================================================//
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement