Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // This is a comment
- // uncomment the line below if you want to write a filterscript
- //#define FILTERSCRIPT
- #include < a_samp >
- #include < zcmd >
- #include < foreach >
- #include < sscanf2 >
- #define Version 1.1
- #if defined FILTERSCRIPT
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print(" Essential By TheDucc loaded");
- printf("Versiunea %d",Version);
- print(" \a");
- print(" \a");
- print("--------------------------------------\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- #else
- main()
- {
- print("\n----------------------------------");
- print(" Essential by TheDucc Exit");
- print("----------------------------------\n");
- }
- #endif
- public OnGameModeInit()
- {
- SetGameModeText("Essential v1.0");
- return 1;
- }
- public OnGameModeExit()
- {
- return 1;
- }
- stock GetName( playerid )
- {
- new
- i[ 30 ];
- GetPlayerName( playerid , i , 30 ) ;
- return ( i );
- }
- CMD:kill( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- m_SendMessage( playerid , -1 , ""O" Ai murit " ) ;
- SetPlayerArmour( playerid , 0.0 ) ;
- SetPlayerHealth( playerid , 0.0 ) ;
- return ( true ) ;
- }
- CMD:healall( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- Healh SetPlayerHealth
- new
- str[80] ;
- foreach(Player, i )
- {
- Healh( i , 100.0 ) ;
- format( str , sizeof ( str ), ""O"[Admin] "W"%s[%d] A dat Heal all ",GetName( playerid ), playerid ) ;
- m_SendMessage( i, 1 , str ) ;
- }
- return ( true ) ;
- }
- CMD:armourall( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- Armour SetPlayerArmour
- new
- str[81] ;
- foreach(Player, i )
- {
- Armour(i , 100) ;
- format( str , sizeof ( str ), ""O"[Admin] "W"%s[%d] A dat Armour all ",GetName( playerid ), playerid ) ;
- m_SendMessage( i, 1 , str ) ;
- }
- return ( true ) ;
- }
- CMD:clearchat( playerid, params[ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- if( IsPlayerAdmin( playerid ))
- {
- foreach(Player, i )
- {
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , " " ) ;
- m_SendMessage ( i , -1 , " " ) ; m_SendMessage ( i , -1 , ""O"Chat Clear !!" ) ;
- }
- }
- return ( 1 ) ;
- }
- CMD:ann( playerid , params[ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- Announce GameTextForPlayer
- if( IsPlayerAdmin( playerid ))
- {
- new
- TextAnnounce [ 100 ] ;
- foreach(Player, i )
- {
- if( sscanf( params," s[100] ", TextAnnounce ) )
- {
- m_SendMessage(playerid,-1,""O"INFO: /ann [Text]");
- }
- Announce( i, TextAnnounce, 6000, 6 );
- }
- }
- return ( true ) ;
- }
- CMD:jetpack( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- m_SpecialAction SetPlayerSpecialAction
- #define \
- JetPack_Spawned SPECIAL_ACTION_USEJETPACK
- m_SpecialAction( playerid , JetPack_Spawned ) ;
- m_SendMessage( playerid, -1 , ""O"Jetpack Spawned" ) ;
- return ( true ) ;
- }
- CMD:kick( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- No_Exist_ID INVALID_PLAYER_ID
- if( IsPlayerAdmin( playerid ))
- {
- new
- Player;
- foreach(Player,i)
- {
- if( sscanf( params," u ",Player ) )
- {
- m_SendMessage(playerid,-1,""O"INFO: /kick [PlayerName]");
- }
- else if( Player == No_Exist_ID )
- {
- m_SendMessage(playerid,-1,""O"ERROR: Acest player nu este conectat");
- }
- else
- {
- new
- str[82];
- m_SendMessage(i, -1,""O"----------------- KICK INFO ------------------------");
- format(str,82,""O"[KICK] "W"%s[%d] a primit kick de la adminul %s",GetName( playerid ),playerid,GetName( playerid ));
- m_SendMessage(i,-1,str);
- printf("str");
- Kick(Player);
- }
- }
- }
- return ( true ) ;
- }
- CMD:ban( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- No_Exist_ID INVALID_PLAYER_ID
- if( IsPlayerAdmin( playerid ))
- {
- new
- Player;
- foreach(Player,i)
- {
- if( sscanf( params," u ",Player ) )
- {
- m_SendMessage(playerid,-1,""O"INFO: /ban [PlayerName]");
- }
- else if( Player == No_Exist_ID )
- {
- m_SendMessage(playerid,-1,""O"ERROR: Acest player nu este conectat");
- }
- else
- {
- new
- str[83];
- m_SendMessage(i, -1,""O"----------------- BAN INFO ------------------------");
- format(str,83,""O"[KICK] "W"%s[%d] a primit ban de la adminul %s",GetName( playerid ),playerid,GetName( playerid ));
- m_SendMessage(i,-1,str);
- printf("str");
- Ban(Player);
- }
- }
- }
- return ( true ) ;
- }
- CMD:giveallcash( playerid, params[ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- m_MoneyAll GivePlayerMoney
- #define \
- m_PlaySound PlayerPlaySound
- if( IsPlayerAdmin( playerid ) )
- {
- new
- Money ;
- foreach(Player, i )
- {
- if( sscanf( params," uu ",Money ) )
- {
- m_SendMessage(playerid,-1,""O"INFO: /giveallcash [Amount]");
- }
- m_PlaySound( i, 1057, 0.0, 0.0, 0.0 );
- m_MoneyAll( i, Money );
- }
- }
- return ( 1 ) ;
- }
- CMD:goto( playerid , params [ ] )
- {
- #pragma \
- tabsize 0
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- #define \
- No_Exist_ID INVALID_PLAYER_ID
- if( IsPlayerAdmin( playerid ))
- {
- new
- Player;
- if( sscanf( params," u " ,Player) )
- {
- m_SendMessage(playerid,-1,""O"INFO : /goto [PlayerName]");
- }
- else if(Player == No_Exist_ID)
- {
- m_SendMessage(playerid,-1,""O"ERROR: Acest player nu este conectat");
- }
- else
- {
- new
- Float: x ,
- Float: y ,
- Float: z ;
- GetPlayerPos(Player,x,y,z);
- if(!IsPlayerInAnyVehicle( playerid ))
- {
- SetPlayerPos(playerid, x+1 , y , z );
- }
- if(IsPlayerInAnyVehicle( playerid ))
- {
- SetVehiclePos( GetPlayerVehicleID( playerid ), x+1 , y+1 , z );
- }
- }
- }
- return ( true ) ;
- }
- CMD:gmx( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- if( IsPlayerAdmin ( playerid ) )
- {
- new
- str[600];
- foreach(Player, i )
- {
- SendRconCommand(" gmx ") ;
- format ( str , sizeof ( str ) , "%s Restarted server", GetName( playerid ) );
- m_SendMessage ( i , -1 , str ) ;
- printf("str") ;
- }
- }
- return ( true ) ;
- }
- CMD:essential( playerid , params [ ] )
- {
- #define \
- W "{FFFFFF}"
- #define \
- O "{FFAF00}"
- #define \
- m_SendMessage SendClientMessage
- m_SendMessage( playerid , -1 , " "W"Essential "O"v1.0 " ) ;
- m_SendMessage( playerid , -1 , " "O"/healall /armourall" ) ;
- m_SendMessage( playerid , -1 , " "W"/jetpack /kill" ) ;
- m_SendMessage( playerid , -1 , " "O"/giveallcash - RCON" ) ;
- m_SendMessage( playerid , -1 , " "W"/ban /kick - RCON" ) ;
- m_SendMessage( playerid , -1 , " "O"/ann /gmx - RCONl" ) ;
- return ( true ) ;
- }
Advertisement
Add Comment
Please, Sign In to add comment