Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- IRCCMD:eject(botid, channel[], user[], host[], params[])
- {
- new giveid,lolz1[256],lolz2[256],msg[256],pon[100];
- new Lname[MAX_PLAYER_NAME];
- GetPlayerName(giveid, Lname, sizeof(Lname));
- if (IRC_IsHalfop(gBotID[0], channel, user))
- if(sscanf(params,"sz",pon,msg)) return IRC_Say(gBotID[0],channel,"3Usage:1 !eject <PartOfName/PlayerID> <Reason [Optional]>");
- if(!IsPlayerConnected(giveid))return IRC_Say(gBotID[0],channel,"4*** Error: Invalid player ID.");
- if(!IsPlayerInAnyVehicle(giveid)) return IRC_Say(gBotID[0],channel,"4*** Error: The selected id is not in a vehicle.");
- format(lolz1,256,"4*** Admin %s (IRC) have ejected %s(ID:%d) from the vehicle. [Reason: %s.]",user,Lname,giveid, msg[0] ? msg: "No Reason");
- format(lolz2,256,"*** Admin %s (IRC) have ejected %s (ID:%d) from the vehicle. [Reason: %s.]",user,Lname,giveid, msg[0] ? msg: "No Reason");
- IRC_Say(gBotID[0],channel,lolz1);
- SendClientMessageToAll(red,lolz2);
- RemovePlayerFromVehicle(giveid);
- #pragma unused botid
- return true;
- }
- ----------------------------------------------------------------------------------------------------------------------
- IRCCMD:akill(botid, channel[], user[], host[], params[])
- {
- new giveid,msg[255],lolz1[255],lolz2[256],pon[100];
- new Lname[MAX_PLAYER_NAME];
- GetPlayerName(giveid, Lname, sizeof(Lname));
- if (IRC_IsOp(gBotID[0], channel, user))
- if(sscanf(params,"sz",pon,msg)) return IRC_Say(gBotID[0],channel,"3Usage:1 !akill <PartOfName/PlayerID> <Reason>");
- if(!IsPlayerConnected(giveid)) return IRC_Say(gBotID[0],channel,"4*** Error: Invalid Player ID");
- SetPlayerHealth(giveid,0);
- SetPlayerArmour(giveid,0);
- format(lolz1,sizeof(lolz1),"*** Admin %s (IRC) killed %s (ID:%d) [Reason: %s]",user,Lname,giveid,msg[0] ? msg: "No Reason");
- format(lolz2,sizeof(lolz2),"4*** Admin %s (IRC) killed %s (ID:%d) [Reason: %s]",user,Lname,giveid,msg[0] ? msg: "No Reason");
- SendClientMessageToAll(red,lolz1);
- IRC_Say(gBotID[0],channel,lolz2);
- #pragma unused botid
- return true;
- }
- --------------------------------------------------------------------------------------------------------------------------
- IRCCMD:spawn(botid, channel[], user[], host[], params[])
- {
- new msg[128];
- new endid, idx;
- new tmp[256];
- tmp = strtok(params, idx);
- new Lname[MAX_PLAYER_NAME];
- GetPlayerName(endid, Lname, sizeof(Lname));
- if (IRC_IsHalfop(gBotID[0], channel, user))
- if(isnull(params)) return IRC_GroupSay(gGroupID, channel, "USAGE: !spawn [ID]");
- endid = strval(tmp);
- format(msg,256,"6%s, You have successfully spawned %s (ID:%d)",user,Lname, endid);
- IRC_Say(gBotID[0],channel,msg);
- format(msg,256,"You have been spawned by Administrator %s.",user);
- SendClientMessage(endid,red,msg);
- RemovePlayerFromVehicle(endid);
- SpawnPlayer(endid);
- #pragma unused botid,user
- return true;
- }
- ---------------------------------------------------------------------------------------------------------------------------
- IRCCMD:setscore(botid, channel[], user[], host[], params[])
- {
- new id, score, pname[MAX_PLAYER_NAME], str[128];
- if(!IRC_IsAdmin(botid, channel, user)) return IRC_Say(gBotID[0], channel, "Invalid Level");
- {
- if (sscanf(params, "ui", id, score))
- {
- IRC_Say(gBotID[0], channel, "Usage: !setscore [ID] [score]");
- }
- if(!IsPlayerConnected(id)) return IRC_Say(gBotID[0], channel, "Invalid Player ID.");
- {
- SetPlayerScore(id, score);
- GetPlayerName(id, pname, sizeof(pname));
- format(str, sizeof(str), "57SCORE::1 %s Score Has Been Set To %d By IRC Administrator %s", pname, score, user);
- IRC_Say(gBotID[0], channel, str);
- format(str, sizeof(str), "%s's score has been set to %d by IRC Administrator %s", pname, score, user);
- SendClientMessageToAll(red, str);
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement