08.11.2013, 23:23
(
Последний раз редактировалось JhnN; 09.11.2013 в 13:34.
)
Sistema de Brinquedos/Acessуrios v1.0
Descriзгo: Elaborei esse FS й bem simples, deve ter vбrios desses pela net, nгo importa, estou postando aqui no fуrum, й meu primeiro..
Ele tem 31 Brinquedos , Ъtilidades , acessуrios.. chame do que quiser.
Cade player pode usar no mбximo 2 brinquedos.
Comandos:
/brinquedos - Abre dialog com a lista de brinquedos / ъtilidades disponнvel.
/tirarbrinquedo - Como nome jб diz, remove um objeto do personagem.
IMAGENS: Click Aqui
FS:
pawn Код:
/*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
FS JL-Brinquedos/Utilidades v1.0
Crйditos:
JhnN - pelo FS
FiniSh1 - Por alguns SetPlayerAttachedObject
Agradecimentos: Wiki e Forum SA:MP, por tirar dъvidas e ajudar em uns cуdigos
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*/
#define FILTERSCRIPT
#include <a_samp>
#include <zcmd>
#if defined FILTERSCRIPT
#define Verde 0x80FF80AA
#define Rosa 0xFF00FFAA
#define Vermelho 0xFF0000AA
#define Azulclaro 0x0088FFFF
#define BrinquedosJhnN 50
new JL[4][160] =
{
"[ERRO]: Vocк precisa sair do veнculo!",
"[ERRO]: Vocк precisa Logar/Spawn!",
"[INFO]: Seu brinquedo foi removido com sucesso!",
"[INFO]: Para tirar um brinquedo {FF0000}/tirarbrinquedo"
};
public OnFilterScriptInit()
{
print("FS JL-Brinquedos por JhnN!");
return 1;
}
CMD:brinquedos(playerid, params[])
{
if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, JL[0]);
ShowBrinquedos(playerid);
return 1;
}
CMD:tirarbrinquedo(playerid, params[])
{
for(new i=0; i< MAX_PLAYER_ATTACHED_OBJECTS; i++)
{
if(IsPlayerAttachedObjectSlotUsed(playerid, i)) RemovePlayerAttachedObject(playerid, i);
}
SendClientMessage(playerid, Vermelho, JL[2]);
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid)
{
case BrinquedosJhnN:
{
if(response)
{
SendClientMessage(playerid, Azulclaro, JL[3]);
GameTextForPlayer(playerid,"~y~/tirarbrinquedo",4000,3);
switch(listitem)
{
case 0: SetPlayerAttachedObject(playerid, 0, 19330, 2, 0.166000, -0.038999, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000);
case 1: SetPlayerAttachedObject(playerid, 0, 19161, 2, 0.078999, 0.000000, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000);
case 2: SetPlayerAttachedObject(playerid, 0, 18639, 2, 0.131000, 0.019000, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000);
case 3: SetPlayerAttachedObject(playerid, 0, 18638, 2, 0.148999, 0.031000, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000);
case 4: SetPlayerAttachedObject(playerid, 0, 18939, 2, 0.164000, 0.001999, 0.000000, 0.000000, 0.000000, 0.000000, 1.000000, 1.000000, 1.000000);
case 5: SetPlayerAttachedObject(playerid, 0, 19488, 2, 0.121999, 0.000000, -0.005999, -83.199966, 98.200027, -2.500000, 1.000000, 1.000000, 1.000000);
case 6: SetPlayerAttachedObject(playerid, 0, 19352, 2, 0.106999, 0.016000, -0.010999, 4.500000, 82.099990, -3.100001, 1.000000, 1.000000, 1.000000);
case 7: SetPlayerAttachedObject(playerid, 0, 19090, 2, -0.315999, 0.019999, 0.030000, 0.000000, 0.000000, 0.000000, 1.455999, 0.526000, 0.541000);
case 8: SetPlayerAttachedObject(playerid, 0, 19424, 2, 0.070999, -0.026000, -0.002000, -85.299987, 1.600005, -99.500000, 0.944001, 0.915000, 0.809999);
case 9: SetPlayerAttachedObject(playerid, 0, 19078,1,-1.000000,-0.517000,0.000000,0.000000,0.299999,10.499994,8.673998,9.400999,7.410993);
case 10: SetPlayerAttachedObject(playerid,1, 19078,4,-0.067000,0.053999,0.018000,-168.400039,-169.800003,-2.800000,1.000000,1.000000,1.000000);
case 11: SetPlayerAttachedObject(playerid,0, 19085,2,0.090999,0.035000,-0.015000,106.599983,83.199996,0.800003,1.000000,1.000000,1.000000);
case 12: SetPlayerAttachedObject(playerid,1, 19086,15,0.051000,0.000000,-0.424999,0.000000,0.000000,-102.100006,1.000000,1.000000,1.000000);
case 13: SetPlayerAttachedObject(playerid,0, 19137,2,0.101000,0.000000,0.000000,0.000000,0.000000,0.000000,1.000000,1.000000,1.000000);
case 14: SetPlayerAttachedObject(playerid,0, 19137,15,0.040999,0.000000,-0.130000,-86.300003,106.100013,-96.100051,7.741999,4.874000,5.584998);
case 15: SetPlayerAttachedObject(playerid,0, 19315,1,-0.247999,0.509999,-0.015999,4.300004,86.900024,85.500015,3.010000,4.463000,3.824000);
case 16: SetPlayerAttachedObject(playerid,0, 19314,2,0.157000,0.000000,0.000000,-0.199999,-7.600006,-88.599998,1.000000,1.000000,1.000000);
case 17: SetPlayerAttachedObject(playerid,0, 19314,2,0.157000,0.000000,0.000000,1.400000,-7.600006,-28.599973,0.711000,0.919999,0.361999);
case 18: SetPlayerAttachedObject(playerid,0, 19320,2,0.000000,0.000000,0.000000,4.299999,72.999992,3.199999,3.594999,3.787999,4.951001);
case 19: SetPlayerAttachedObject(playerid,0, 18963,2,0.261000,0.084999,0.004999,4.999999,85.400039,84.699974,2.097000,2.627000,3.033999);
case 20: SetPlayerAttachedObject(playerid,0, 1607,2,0.267000,0.000000,0.000000,-0.199999,81.199996,-3.499999,1.135000,1.000000,1.126999);
case 21: SetPlayerAttachedObject(playerid,0, 1608,1,0.000000,0.000000,0.000000,0.499999,89.200042,0.199999,1.000000,1.000000,1.000000);
case 22: SetPlayerAttachedObject(playerid,0, 1609,1,-0.358000,0.000000,0.170000,0.000000,93.099998,0.000000,1.427000,1.509000,1.641000);
case 23: SetPlayerAttachedObject(playerid,0, 16442,15,0.000000,0.000000,0.259000,0.000000,0.000000,-104.400001,1.000000,1.000000,1.000000);
case 24: SetPlayerAttachedObject(playerid,1, 373 , 1, 0.33, -0.029, -0.15, 65, 25, 35);
case 25: SetPlayerAttachedObject(playerid,1, 1240, 1, 0.15, 0.17, 0.06, 0.0, 90.0, 0.0);
case 26: SetPlayerAttachedObject(playerid,1, 1252, 1, 0.1, -0.2, 0.0, 0.0, 90.0, 0.0);
case 27: SetPlayerAttachedObject(playerid,1, 356, 1, -0.2, -0.15, 0.0, 0.0, 24.0, 0.0);
case 28: SetPlayerAttachedObject(playerid,1 ,359 ,15 ,-0.02 ,0.08 ,-0.3 ,0 ,50 ,-10);
case 29: SetPlayerAttachedObject(playerid,0, 19065, 2, 0.120000, 0.040000, -0.003500, 0, 100, 100, 1.4, 1.4, 1.4);
case 30: SetPlayerAttachedObject(playerid,0 ,1852 ,2 ,0.1 ,0 ,-0.01 ,0 ,15 ,0);
case 31: SetPlayerAttachedObject(playerid,1, 1654, 1,0.1,0.20,0.0,180.0,100.0,0.0);
}
}
}
}
return 1;
}
stock ShowBrinquedos(playerid)
{
new string[1700];
strcat(string, "{FF0000}-{FFFFFF} Chapйu de Bombeiro {0088FF}Slot 1 \n"); // 0
strcat(string, "{FF0000}-{FFFFFF} Chapйu de Policial {0088FF}Slot 1 \n"); // 1
strcat(string, "{FF0000}-{FFFFFF} Chapйu Michael Jackson {0088FF}Slot 1 \n"); // 2
strcat(string, "{FF0000}-{FFFFFF} Chapйu Operбrio {0088FF}Slot 1 \n"); // 3
strcat(string, "{FF0000}-{FFFFFF} Chapйu de Funkeiro {0088FF}Slot 1 \n"); // 4
strcat(string, "{FF0000}-{FFFFFF} Chapйu de Veio {0088FF}Slot 1 \n"); // 5
strcat(string, "{FF0000}-{FFFFFF} Chapйu do Harry Potter {0088FF}Slot 1 \n"); // 6
strcat(string, "{FF0000}-{FFFFFF} Bolsa de sequestrador {0088FF}Slot 1 \n");// 7
strcat(string, "{FF0000}-{FFFFFF} Fones de ouvido {0088FF}Slot 1 \n");// 8
strcat(string, "{FF0000}-{FFFFFF} Loro Josй Gigante {0088FF}Slot 1 \n");// 9
strcat(string, "{FF0000}-{FFFFFF} Loro Josй menor (Ombro) {0088FF}Slot 2 \n");// 10
strcat(string, "{FF0000}-{FFFFFF} Tapa olho de pirata {0088FF}Slot 2 \n");// 11
strcat(string, "{FF0000}-{FFFFFF} Dildo {0088FF}Slot 2\n");// 12
strcat(string, "{FF0000}-{FFFFFF} Cabeзa de galo {0088FF}Slot 1 \n");// 13
strcat(string, "{FF0000}-{FFFFFF} Cabeзa de galo gigante Slot 1 \n");// 14
strcat(string, "{FF0000}-{FFFFFF} Cervo {0088FF}Slot 1 \n");// 15
strcat(string, "{FF0000}-{FFFFFF} Chifre de boy 1 {0088FF}Slot 1 \n");// 16
strcat(string, "{FF0000}-{FFFFFF} Chifre de boy 2 {0088FF}Slot 1 \n");// 17
strcat(string, "{FF0000}-{FFFFFF} Fanstasia de obуbora {0088FF}Slot 1 \n");// 18
strcat(string, "{FF0000}-{FFFFFF} Cabeзгo do CJ {0088FF}Slot 1 \n"); // 19
strcat(string, "{FF0000}-{FFFFFF} Golfinho {0088FF}Slot 1 \n"); // 20
strcat(string, "{FF0000}-{FFFFFF} Tubarгo {0088FF}Slot 1 \n"); // 21
strcat(string, "{FF0000}-{FFFFFF} Fantasia de tartaruga {0088FF}Slot 1 \n"); // 22
strcat(string, "{FF0000}-{FFFFFF} Vaca {0088FF}Slot 1 \n"); // 23
strcat(string, "{FF0000}-{FFFFFF} Colete no corpo {0088FF}Slot 2 \n");// 24
strcat(string, "{FF0000}-{FFFFFF} Coraзгo no peito {0088FF}Slot 2 \n");// 25
strcat(string, "{FF0000}-{FFFFFF} C4 nas costas {0088FF}Slot 2 \n");// 26
strcat(string, "{FF0000}-{FFFFFF} M4 nas costas {0088FF}Slot 2 \n");// 27
strcat(string, "{FF0000}-{FFFFFF} Bazzuka nas costas {0088FF}Slot 2 \n");// 28
strcat(string, "{FF0000}-{FFFFFF} Toca do Papai Noel {0088FF}Slot 1 \n");// 29
strcat(string, "{FF0000}-{FFFFFF} Dado na cabeзa {0088FF}Slot 1 \n");// 30
strcat(string, "{FF0000}-{FFFFFF} C4 no peito {0088FF}Slot 2 \n");// 31
//SendClientMessage(playerid, Azulclaro, JL[3]);
ShowPlayerDialog(playerid, BrinquedosJhnN, DIALOG_STYLE_LIST, "JL-Brinquedos, selecione um brinquedo para adcionar a seu skin:", string, "APLICAR", "SAIR");
return 1;
}
#endif
JhnN - FS em geral.
FiniSh1 - Por alguns SetPlayerAttachedObject
Agradecimentos: Forum sa-mp e wiki
Como todos viram, й bem simples.
Poste abaixo seu comentбrios. bj
Qualquer coisa to skype lб, sу adc: Jonathan.Lima50