1° - Sistema de maconha para ganhar colete que horrível se um pm invadir até você pegar colete já terminou. Sugestão: No equipar colocar 100 de colete e 100 de vida e criar uma regra para não equipar em batalha.
2° - Sistema de lazer bem simples vou colocar aqui embaixo:
3° - Sistema de arara a cada arara vendia ganha-se 10.000:
4° - Esse aqui vocês escolhem ele mostra pro player que entra o recorde de pessoas do server:
5° Também opcional mostra quantas pessoas passaram pelo server desde que ele foi ligado:
2° - Sistema de lazer bem simples vou colocar aqui embaixo:
- Spoiler:
- #include
//----------------------------------------------------------------------------//
public OnFilterScriptInit() {
print("\n-- Laser Pointer by Skiaffo --\n");
new p = GetMaxPlayers();
for (new i=0; i < p; i++) {
SetPVarInt(i, "laser", 0);
SetPVarInt(i, "color", 18643);
}
return 1;
}
public OnFilterScriptExit() {
new p = GetMaxPlayers();
for (new i=0; i < p; i++) {
SetPVarInt(i, "laser", 0);
RemovePlayerAttachedObject(i, 0);
}
return 1;
}
//----------------------------------------------------------------------------//
public OnPlayerSpawn(playerid) {
if (!GetPVarInt(playerid, "color")) SetPVarInt(playerid, "color", 18643);
}
public OnPlayerDisconnect(playerid) {
SetPVarInt(playerid, "laser", 0);
RemovePlayerAttachedObject(playerid, 0);
return 1;
}
//----------------------------------------------------------------------------//
public OnPlayerCommandText(playerid, cmdtext[]) {
new cmd[256];
new idx;
cmd = strtok(cmdtext, idx);
if (!strcmp("/laseron", cmdtext, true)) {
SetPVarInt(playerid, "laser", 1);
SetPVarInt(playerid, "color", GetPVarInt(playerid, "color"));
return 1;
}
if (!strcmp("/laseroff", cmdtext, true)) {
SetPVarInt(playerid, "laser", 0);
RemovePlayerAttachedObject(playerid, 0);
return 1;
}
if (!strcmp("/lasercol", cmd, true)) {
new tmp[256];
tmp = strtok(cmdtext, idx);
if (!strlen(tmp)) {
SendClientMessage(playerid, 0x00E800FF, "Usage: /lasercol [color]");
return 1;
}
if (!strcmp(tmp, "red", true)) SetPVarInt(playerid, "color", 18643);
else if (!strcmp(tmp, "blue", true)) SetPVarInt(playerid, "color", 19080);
else if (!strcmp(tmp, "pink", true)) SetPVarInt(playerid, "color", 19081);
else if (!strcmp(tmp, "orange", true)) SetPVarInt(playerid, "color", 19082);
else if (!strcmp(tmp, "green", true)) SetPVarInt(playerid, "color", 19083);
else if (!strcmp(tmp, "yellow", true)) SetPVarInt(playerid, "color", 19084);
else SendClientMessage(playerid, 0x00E800FF, "Colour not available!");
return 1;
}
return 0;
}
public OnPlayerUpdate(playerid) {
if (GetPVarInt(playerid, "laser")) {
RemovePlayerAttachedObject(playerid, 0);
if ((IsPlayerInAnyVehicle(playerid)) || (IsPlayerInWater(playerid))) return 1;
switch (GetPlayerWeapon(playerid)) {
case 23: {
if (IsPlayerAiming(playerid)) {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SP standing aiming
0.108249, 0.030232, 0.118051, 1.468254, 350.512573, 364.284240);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SP crouched aiming
0.108249, 0.030232, 0.118051, 1.468254, 349.862579, 364.784240);
}
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SP standing not aiming
0.078248, 0.027239, 0.113051, -11.131746, 350.602722, 362.384216);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SP crouched not aiming
0.078248, 0.027239, 0.113051, -11.131746, 350.602722, 362.384216);
} } }
case 27: {
if (IsPlayerAiming(playerid)) {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SPAS standing aiming
0.588246, -0.022766, 0.138052, -11.531745, 347.712585, 352.784271);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SPAS crouched aiming
0.588246, -0.022766, 0.138052, 1.468254, 350.712585, 352.784271);
}
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SPAS standing not aiming
0.563249, -0.01976, 0.134051, -11.131746, 351.602722, 351.384216);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // SPAS crouched not aiming
0.563249, -0.01976, 0.134051, -11.131746, 351.602722, 351.384216);
} } }
case 30: {
if (IsPlayerAiming(playerid)) {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // AK standing aiming
0.628249, -0.027766, 0.078052, -6.621746, 352.552642, 355.084289);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // AK crouched aiming
0.628249, -0.027766, 0.078052, -1.621746, 356.202667, 355.084289);
}
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // AK standing not aiming
0.663249, -0.02976, 0.080051, -11.131746, 358.302734, 353.384216);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // AK crouched not aiming
0.663249, -0.02976, 0.080051, -11.131746, 358.302734, 353.384216);
} } }
case 31: {
if (IsPlayerAiming(playerid)) {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // M4 standing aiming
0.528249, -0.020266, 0.068052, -6.621746, 352.552642, 355.084289);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // M4 crouched aiming
0.528249, -0.020266, 0.068052, -1.621746, 356.202667, 355.084289);
}
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // M4 standing not aiming
0.503249, -0.02376, 0.065051, -11.131746, 357.302734, 354.484222);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // M4 crouched not aiming
0.503249, -0.02376, 0.065051, -11.131746, 357.302734, 354.484222);
} } }
case 34: {
if (IsPlayerAiming(playerid)) {
/*if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // Sniper standing aiming
0.528249, -0.020266, 0.068052, -6.621746, 352.552642, 355.084289);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // Sniper crouched aiming
0.528249, -0.020266, 0.068052, -1.621746, 356.202667, 355.084289);
}*/
return 1;
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // Sniper standing not aiming
0.658248, -0.03276, 0.133051, -11.631746, 355.302673, 353.584259);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // Sniper crouched not aiming
0.658248, -0.03276, 0.133051, -11.631746, 355.302673, 353.584259);
} } }
case 29: {
if (IsPlayerAiming(playerid)) {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // MP5 standing aiming
0.298249, -0.02776, 0.158052, -11.631746, 359.302673, 357.584259);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // MP5 crouched aiming
0.298249, -0.02776, 0.158052, 8.368253, 358.302673, 352.584259);
}
} else {
if (GetPlayerSpecialAction(playerid) != SPECIAL_ACTION_DUCK) {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // MP5 standing not aiming
0.293249, -0.027759, 0.195051, -12.131746, 354.302734, 352.484222);
} else {
SetPlayerAttachedObject(playerid, 0, GetPVarInt(playerid, "color"), 6, // MP5 crouched not aiming
0.293249, -0.027759, 0.195051, -12.131746, 354.302734, 352.484222);
} } } } }
return 1;
}
stock IsPlayerInWater(playerid) {
new anim = GetPlayerAnimationIndex(playerid);
if (((anim >= 1538) && (anim <= 1542)) || (anim == 1544) || (anim == 1250) || (anim == 1062)) return 1;
return 0;
}
stock IsPlayerAiming(playerid) {
new anim = GetPlayerAnimationIndex(playerid);
if (((anim >= 1160) && (anim <= 1163)) || (anim == 1167) || (anim == 1365) ||
(anim == 1643) || (anim == 1453) || (anim == 220)) return 1;
return 0;
}
//----------------------------------------------------------------------------//
strtok(const string[], &index)
{
new length = strlen(string);
while ((index < length) && (string[index] <= ' '))
{
index++;
}
new offset = index;
new result[20];
while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
{
result[index - offset] = string[index];
index++;
}
result[index - offset] = EOS;
return result;
}
//----------------------------------------------------------------------------//
3° - Sistema de arara a cada arara vendia ganha-se 10.000:
- Spoiler:
- /////////////////////////////////////////////
// //
// Sistema de Arara by FreeGells! //
// //
// Ajuda de Shadoww5. //
// //
/////////////////////////////////////////////
#include
#include
#define BRANCO 0xFFFFFFFF
#define VERMELHO 0xFF0000FF
enum a
{
bool:Arara,
bool:Racao,
Grande,
Timer
}
new Info[MAX_PLAYERS][a];
public OnFilterScriptInit()
{
if(!fexist("Araras.txt")) { dini_Create("Araras.txt"); }
return 1;
}
public OnFilterScriptExit()
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(Info[i][Arara]) { RemovePlayerAttachedObject(i, 0); }
}
return 1;
}
forward Crescimento(playerid);
public OnPlayerConnect(playerid)
{
new nome[24], str[50];
GetPlayerName(playerid, nome, 24);
format(str, sizeof str, "%s - Arara", nome);
if(dini_Isset("Araras.txt", str))
{
Info[playerid][Arara] = bool:dini_Bool("Araras.txt", str);
format(str, sizeof str, "%s - Racao", nome);
Info[playerid][Racao] = bool:dini_Bool("Araras.txt", str);
format(str, sizeof str, "%s - Grande", nome);
Info[playerid][Grande] = dini_Int("Araras.txt", str);
if(Info[playerid][Arara])
{
Info[playerid][Timer] = SetTimerEx("Crescimento", 300000, true, "i", playerid);
SendClientMessage(playerid, 0xFFFF00FF, "Alimente sua arara ou ela morrerá.");
}
}
return 1;
}
public OnPlayerSpawn(playerid)
{
if(Info[playerid][Arara]) { SetPlayerAttachedObject(playerid,0, 19079, 1, 0.319503, -0.089340, -0.185576, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000 ); }
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
new nome[24], str[50];
GetPlayerName(playerid, nome, 24);
format(str, sizeof str, "%s - Arara", nome);
dini_BoolSet("Araras.txt", str, Info[playerid][Arara]);
format(str, sizeof str, "%s - Racao", nome);
dini_BoolSet("Araras.txt", str, Info[playerid][Racao]);
format(str, sizeof str, "%s - Grande", nome);
dini_IntSet("Araras.txt", str, Info[playerid][Grande]);
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmdtext, "/comprararara", true) == 0)
{
if(Info[playerid][Grande] >= 5) return SendClientMessage(playerid, VERMELHO, "Sua Arara Está Grande e Pronta para ser vendida, Para vender digite /VenderArara !");
if(GetPlayerMoney(playerid)<2000)return SendClientMessage(playerid, BRANCO,"Você não tem R$2000!");
if(Info[playerid][Arara]) return SendClientMessage(playerid, BRANCO, "Você já tem uma Arara!");
SendClientMessage(playerid, BRANCO, "Você Comprou uma Arara!");
SendClientMessage(playerid, BRANCO, "Ela irá crescer de Cinco a Cinco Minutos!");
SendClientMessage(playerid, BRANCO, "Não se esqueça de Alimenta-lá! /Racao!");
SendClientMessage(playerid, BRANCO, "Para saber se ela já foi alimentada use /alimentada");
SetPlayerAttachedObject(playerid,0, 19079, 1, 0.319503, -0.089340, -0.185576, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000 );
GivePlayerMoney(playerid, -2000);
Info[playerid][Arara] = true;
Info[playerid][Timer] = SetTimerEx("Crescimento", 300000, true, "i", playerid);
return 1;
}
if(strcmp(cmdtext, "/alimentada", true) == 0)
{
if(Info[playerid][Grande] >= 5) return SendClientMessage(playerid, VERMELHO, "Sua Arara Está Grande e Pronta para ser vendida, Para vender digite /VenderArara !");
if(!Info[playerid][Arara]) return SendClientMessage(playerid, VERMELHO, "Você não tem uma arara.");
if(Info[playerid][Racao]) { SendClientMessage(playerid, BRANCO, "Arara Alimentada: {008000}Sim"); }
else { SendClientMessage(playerid, BRANCO, "Arara Alimentada: {FF0000}Não"); }
return 1;
}
if(strcmp(cmdtext, "/racao", true) == 0)
{
if(Info[playerid][Grande] >= 5) return SendClientMessage(playerid, VERMELHO, "Sua Arara Está Grande e Pronta para ser vendida, Para vender digite /VenderArara !");
if(!Info[playerid][Arara]) return SendClientMessage(playerid, VERMELHO, "Você não tem uma arara.");
if(Info[playerid][Racao]) return SendClientMessage(playerid, BRANCO, "Você já Alimentou sua Arara!");
SendClientMessage(playerid, BRANCO, "Você Alimentou Sua Arara! Isso lhe custou R$200");
GivePlayerMoney(playerid, -200);
Info[playerid][Racao] = true;
return 1;
}
if(strcmp(cmdtext, "/venderarara", true) == 0)
{
if(!Info[playerid][Arara]) return SendClientMessage(playerid, BRANCO,"Você Não comprou nenhuma Arara!");
if(Info[playerid][Grande] < 5) return SendClientMessage(playerid, BRANCO,"Sua Arara ainda não está grande!");
Info[playerid][Grande] = 0;
Info[playerid][Arara] = false;
RemovePlayerAttachedObject(playerid, 0);
GivePlayerMoney(playerid, 10000);
SendClientMessage(playerid, BRANCO, "Você Vendeu Sua Arara e ganhou R$10000!");
return 1;
}
return 0;
}
public Crescimento(playerid)
{
if(!Info[playerid][Arara])
{
KillTimer(Info[playerid][Timer]);
return 0;
}
if(!Info[playerid][Racao] && Info[playerid][Grande] < 5)
{
SendClientMessage(playerid, BRANCO, "Você não alimentou sua Arara e Ela Morreu!");
RemovePlayerAttachedObject(playerid, 0);
Info[playerid][Arara] = false;
Info[playerid][Grande] = 0;
KillTimer(Info[playerid][Timer]);
return 1;
}
new str[30];
Info[playerid][Grande]++;
Info[playerid][Racao] = false;
format(str, sizeof str, "Sua Arara Cresceu! (%d/5)", Info[playerid][Grande]);
SendClientMessage(playerid, BRANCO, str);
if(Info[playerid][Grande] >= 5)
{
SendClientMessage(playerid, BRANCO, "Sua Arara Está Grande e Pronta para ser vendida, Para vender digite /VenderArara !");
KillTimer(Info[playerid][Timer]);
}
return 1;
}
4° - Esse aqui vocês escolhem ele mostra pro player que entra o recorde de pessoas do server:
- Spoiler:
- /*
Recorde de Players Online
*/
#include
new oplayers, Precord, Drecord, Mrecord, Yrecord, THrecord, TMrecord;
new mname[][] = {"Janeiro", "Fevereiro", "Marco", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"};
public OnFilterScriptInit()
{
LoadRecord();
oplayers=ConnectedPlayers();
print("\n--------------------------------------");
print("FS =Recorde de player Online, Carregado...");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
print("\n--------------------------------------");
print("FS =Recorde de player Online, Desativado...");
print("--------------------------------------\n");
return 1;
}
public OnPlayerConnect(playerid)
{
if(IsPlayerNPC(playerid)) { return 1; }
SetTimerEx("Record", 5000, false, "d", playerid);
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
oplayers--;
return 1;
}
///////////////////////////////////////////////////////////////////////////
forward LoadRecord();
public LoadRecord()
{
new strFromFile[24], arrCoords[6][5], File: file = fopen("porecords", io_read);
if (file)
{
fread(file, strFromFile);
split(strFromFile, arrCoords, ',');
Precord = strval(arrCoords[0]);
Drecord = strval(arrCoords[1]);
Mrecord = strval(arrCoords[2]);
Yrecord = strval(arrCoords[3]);
THrecord = strval(arrCoords[4]);
TMrecord = strval(arrCoords[5]);
fclose(file);
}
return 1;
}
forward SaveRecord();
public SaveRecord()
{
new coordsstring[24];
format(coordsstring, sizeof(coordsstring), "%d,%d,%d,%d,%d,%d", Precord, Drecord, Mrecord, Yrecord, THrecord, TMrecord);
new File: file = fopen("porecords", io_write);
fwrite(file, coordsstring);
fclose(file);
return 1;
}
forward Record(playerid);
public Record(playerid)
{
if(Precord)
{
new string[92];
format(string, sizeof(string), "**Recorde de Jogadores Online: %d, Batido Em: %d %s %d, at %d:%d", Precord, Drecord, mname[Mrecord-1], Yrecord, THrecord, TMrecord);
SendClientMessage(playerid, 0xA5D24DFF, string);
}
oplayers++;
if(Precord < oplayers)
{
Precord=oplayers;
gettime(THrecord, TMrecord); getdate(Yrecord, Mrecord, Drecord);
new string[92];
format(string, sizeof(string), "*Novo Recorde de players online: %d, Batido Em: %d %s %d, at %d:%d", Precord, Drecord, mname[Mrecord-1], Yrecord, THrecord, TMrecord);
SendClientMessageToAll(0xFCB833FF, string);
SaveRecord();
}
return 1;
}
stock split(const strsrc[], strdest[][], delimiter)
{
new i, li;
new aNum;
new len;
while(i <= strlen(strsrc))
{
if(strsrc[i] == delimiter || i == strlen(strsrc))
{
len = strmid(strdest[aNum], strsrc, li, i, 128);
strdest[aNum][len] = 0;
li = i+1;
aNum++;
}
i++;
}
return 1;
}
forward ConnectedPlayers();
public ConnectedPlayers()
{
new Connected;
for(new i = 0; i < MAX_PLAYERS; i++) if(IsPlayerConnected(i) && !IsPlayerNPC(i)) Connected++;
return Connected;
}
///////////////////////////////////////////////////////////////////////////
5° Também opcional mostra quantas pessoas passaram pelo server desde que ele foi ligado:
- Spoiler:
- contador++;
new contadorxd[128];
format(contadorxd, sizeof(contadorxd), "Você é o visitante número %d de hoje!",contador);
SendClientMessage(playerid,0xFFFF00AA, contadorxd);