Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- by: LinkiNPark 21.09.2012
- */
- #include a_samp
- #define public:L_%0(%1) \
- forward %0(%1); public %0(%1)
- new
- L_ctext[] = {
- 0xFF151500, 0xFF151511, 0xFF151522, 0xFF151533, 0xFF151544,
- },
- Text: L_text, Float: L_hp[ MAX_PLAYERS ][ 2 ] ;
- public OnFilterScriptInit()
- {
- L_text = TextDrawCreate ( -5.00, -5.00, "."), TextDrawBackgroundColor ( L_text, 0xFF151544);
- TextDrawFont ( L_text, 1), TextDrawLetterSize ( L_text, 0.000, 51.099);
- TextDrawColor ( L_text, -1), TextDrawSetOutline ( L_text, 0);
- TextDrawSetProportional ( L_text, 1), TextDrawSetShadow ( L_text, 1);
- TextDrawUseBox ( L_text, 1), TextDrawBoxColor ( L_text, 0xFF151544);
- TextDrawTextSize ( L_text, 643.00, 0.00);
- return 1 ;
- }
- public OnFilterScriptExit()
- {
- TextDrawHideForAll ( L_text ) ;
- return 1 ;
- }
- public OnPlayerUpdate( playerid )
- {
- GetPlayerHealth( playerid, L_hp[playerid][ 0 ]) ;
- if ( L_hp[ playerid ][ 0 ] < L_hp[ playerid ][ 1 ] )
- {
- if ( !GetPVarInt(playerid, "hp" ) ) SetPVarInt(playerid, "hp", true ), Red ( playerid, 4 ),
- L_hp[playerid][ 1 ] = L_hp[playerid][ 0 ];
- }
- else L_hp[playerid][ 1 ] = L_hp[playerid][ 0 ] ;
- return 1 ;
- }
- public:L_Red ( playerid, indx )
- {
- TextDrawBoxColor( L_text, L_ctext[ indx ] ), TextDrawShowForPlayer( playerid, L_text);
- if ( !indx ) return SetPVarInt(playerid, "hp", false ) ;
- SetTimerEx ( "Red", 65, false, "ii", playerid, indx - 1 ) ;
- return 1 ;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement