Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void NPCI(int clientid, int npcid)
- {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int vela = GetFirstSlotSADD(clientid, 4038, 64);
- if(vela == -1) {
- SendSay(npcid, "Não acha que está faltando algo?");
- return;
- }
- int _rand = rand() % 100;
- if(_rand <= 25) {
- memset(&player->Inventory[vela], 0, 8);
- player->Inventory[vela].Index = 3447;
- player->Inventory[vela].EF1 = 61;
- player->Inventory[vela].EFV1 = 5;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Oriharucon x5]");
- } else if(_rand <= 50) {
- memset(&player->Inventory[vela], 0, 8);
- player->Inventory[vela].Index = 3448;
- player->Inventory[vela].EF1 = 61;
- player->Inventory[vela].EFV1 = 2;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Lactolerium x2]");
- } else if(_rand <= 75) {
- memset(&player->Inventory[vela], 0, 8);
- player->Inventory[vela].Index = 4026;
- SendClientMsg(clientid, "!Chegou um item: [Moeda de Prata (1mi)]");
- } else {
- memset(&player->Inventory[vela], 0, 8);
- player->Inventory[vela].Index = 4104;
- SendClientMsg(clientid, "!Chegou um item: [Bolsa da Sorte]");
- }
- SendSay(npcid, "NPC I");
- SendSlot(clientid, vela);
- }
- void NPCII(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int bau = GetFirstSlotSADD(clientid, 4198, 64);
- if(bau == -1) {
- SendSay(npcid, "Esqueceu de me trazer o Baú do Tesouro!");
- return;
- }
- int _rand = rand() % 100;
- if(_rand <= 25) {
- memset(&player->Inventory[bau], 0, 8);
- player->Inventory[bau].Index = 3447;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 10;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Oriharucon x10]");
- } else if(_rand <= 50) {
- memset(&player->Inventory[bau], 0, 8);
- player->Inventory[bau].Index = 3448;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Lactolerium x5]");
- } else if(_rand <= 75) {
- memset(&player->Inventory[bau], 0, 8);
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- if(rand() % 100 <= 50) {
- player->Inventory[bau].Index = 2396;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Cavalo s/ Sela N x5]");
- } else {
- player->Inventory[bau].Index = 2401;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Cavalo s/ Sela B x5]");
- }
- } else {
- memset(&player->Inventory[bau], 0, 8);
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- if(rand() % 100 <= 50) {
- player->Inventory[bau].Index = 2397;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Cavalo Fantasma N x5]");
- } else {
- player->Inventory[bau].Index = 2402;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Cavalo Fanntasma B x5]");
- }
- }
- SendSlot(clientid, bau);
- SendSay(npcid, "NPC II");
- return;
- }
- void NPCIII(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int slot = -1;
- for(int i=0;i<64;i++) {
- if(player->Inventory[i].Index == 3447) {
- if(player->Inventory[i].EF1 == 61)
- if(player->Inventory[i].EFV1 == 5) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF2 == 61)
- if(player->Inventory[i].EFV2 == 5) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF3 == 61)
- if(player->Inventory[i].EFV3 == 5) {
- slot = i;
- break;
- }
- }
- }
- if(slot == -1) {
- SendSay(npcid, "Esqueceu do Pacote de Oriharucon x5?");
- return;
- }
- int null = GetFirstSlotSADD(clientid, 0, 64);
- if(null == -1) {
- SendSay(npcid, "Precisa de um slot vazio!");
- return;
- }
- int _rand = rand() % 100;
- if(_rand <= 20) {
- memset(&player->Inventory[slot], 0, 8);
- player->Inventory[slot].Index = 4140;
- SendClientMsg(clientid, "!Chegou um item: [Baú de Experiência]");
- } else if(_rand <= 40) {
- memset(&player->Inventory[slot], 0, 8);
- player->Inventory[slot].Index = 3336;
- SendClientMsg(clientid, "!Chegou um item: [Retorno de Habilidade]");
- } else if(_rand <=60) {
- memset(&player->Inventory[slot], 0, 8);
- player->Inventory[slot].Index = 4027;
- SendClientMsg(clientid, "!Chegou um item: [Moeda de Prata (5m)]");
- } else if(_rand <= 80) {
- _rand = rand() % 100;
- memset(&player->Inventory[slot], 0, 8);
- if(_rand <= 25)
- player->Inventory[slot].Index = 2441, player->Inventory[null].Index = 2441, SendClientMsg(clientid, "!Chegou um item: [Diamante]");
- else if(_rand <= 50)
- player->Inventory[slot].Index = 2442, player->Inventory[null].Index = 2442, SendClientMsg(clientid, "!Chegou um item: [Esmeralda]");
- else if(_rand <= 75)
- player->Inventory[slot].Index = 2443, player->Inventory[null].Index = 2443, SendClientMsg(clientid, "!Chegou um item: [Coral]");
- else
- player->Inventory[slot].Index = 2444, player->Inventory[null].Index = 2444, SendClientMsg(clientid, "!Chegou um item: [Garnet]");
- } else {
- memset(&player->Inventory[slot], 0, 8);
- player->Inventory[slot].Index = 3448;
- player->Inventory[slot].EF1 = 61;
- player->Inventory[slot].EFV1 = 10;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Lactolerium x10]");
- }
- SendSlot(clientid, slot);
- SendSlot(clientid, null);
- SendSay(npcid, "NPC III");
- }
- void NPCIV(int clientid, int npcid) {
- st_Mob *player= (st_Mob*)GetMobFromIndex(clientid);
- int bau = GetFirstSlotSADD(clientid, 4198, 64);
- int retorno = GetAmountItem(clientid, 3336);
- if(bau == -1) {
- SendSay(npcid, "Esqueceu do Baú do Tesouro!");
- return;
- }
- if(retorno < 2) {
- SendSay(npcid, "Traga-me 2 Retorno de Habilidades!");
- return;
- }
- int _rand = rand () %100;
- for(int i=0;i<2;i++) {
- int slot = GetFirstSlotSADD(clientid, 3336, 64);
- if(slot == -1) {
- SendClientMsg(clientid, "Algum erro aconteceu!");
- return;
- }
- memset(&player->Inventory[slot], 0, 8);
- SendSlot(clientid, slot);
- }
- memset(&player->Inventory[bau], 0, 8);
- if(_rand <= 20) {
- player->Inventory[bau].Index = 1740;
- SendClientMsg(clientid, "!Chegou um item: [Alma do Unicórnio]");
- } else if(_rand <= 40) {
- player->Inventory[bau].Index = 1741;
- SendClientMsg(clientid, "!Chegou um item: [Alma do Fênix]");
- } else if(_rand <= 60) {
- player->Inventory[bau].Index = 4028;
- SendClientMsg(clientid, "!Chegou um item: [Barra de Prata (10m)]");
- } else if(_rand <= 80) {
- player->Inventory[bau].Index = 2411;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Unicórnio]");
- } else {
- int slot = GetFirstSlotSADD(clientid, 0, 64);
- player->Inventory[bau].Index = 3448;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 10;
- player->Inventory[slot].Index = 3448;
- player->Inventory[slot].EF1 = 61;
- player->Inventory[slot].EFV1 = 10;
- SendClientMsg(clientid, "!Chegou um item: [Pacote de Lactolerium x10]");
- SendSlot(clientid, slot);
- }
- SendSlot(clientid, bau);
- SendSay(npcid, "NPC IV");
- }
- void NPCV(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int imo = GetFirstSlotSADD(clientid, 1742, 64);
- if(imo == -1) {
- SendSay(npcid, "Traga-me a Pedra da Imortalidade");
- return;
- }
- int bolsa = GetAmountItem(clientid, 4104);
- if(bolsa < 2) {
- SendSay(npcid, "Preciso de 2 Bolsas da Sorte para realizar a troca!");
- return;
- }
- memset(&player->Inventory[imo], 0, 8);
- for(int i=0;i<2;i++) {
- int slot = GetFirstSlotSADD(clientid, 4104, 64);
- memset(&player->Inventory[slot], 0, 8);
- SendSlot(clientid, slot);
- }
- int _rand = rand() % 100;
- if(_rand <= 20) {
- player->Inventory[imo].Index = 3026;
- if(rand() % 100 <= 50)
- player->Inventory[imo].EF1 = 60, player->Inventory[imo].EFV1 = 28, SendClientMsg(clientid, "!Chegou um item: [Extração Arma 28bs]");
- else
- player->Inventory[imo].EF1 = 2, player->Inventory[imo].EFV1 = 63, SendClientMsg(clientid, "!Chegou um item: [Extração Arma 63bs]");
- } else if(_rand <= 40) {
- player->Inventory[imo].Index = 4141;
- SendClientMsg(clientid, "!Chegou um item: [Lactolerium 100]");
- } else if(_rand <= 60) {
- player->Inventory[imo].Index = 769;
- SendClientMsg(clientid, "!Chegou um item: [Nyerds]");
- } else if(_rand <= 80) {
- player->Inventory[imo].EF1 = 61;
- player->Inventory[imo].EFV1 = 3;
- if(rand() % 100 <= 50)
- player->Inventory[imo].Index = 2400, SendClientMsg(clientid, "!Chegou um item: [Âmago de Andaluz N x3]");
- else
- player->Inventory[imo].Index = 2405, SendClientMsg(clientid, "!Chegou um item: [Âmago de Andaluz B x3]");
- } else {
- player->Inventory[imo].Index = 3338;
- player->Inventory[imo].EF1 = 43;
- player->Inventory[imo].EFV1 = 1;
- SendClientMsg(clientid, "!Chegou um item: [Refinação Abençoada +1]");
- }
- SendSlot(clientid, imo);
- SendSay(npcid, "NPC V");
- }
- void NPCVI (int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int bau = GetFirstSlotSADD(clientid, 4198, 64);
- if(bau == -1) {
- SendSay(npcid, "Traga-me o Baú de Tesouro!");
- return;
- }
- int ny = GetFirstSlotSADD(clientid, 769, 64);
- if(ny == -1) {
- SendSay(npcid, "Traga-me a Nyerds para realizar a troca!");
- return;
- }
- int _rand = rand() % 100;
- memset(&player->Inventory[bau], 0, 8);
- memset(&player->Inventory[ny], 0, 8);
- if(_rand <= 20) {
- player->Inventory[bau].Index = 2411;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 2;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Unicórnio]");
- } else if(_rand <= 40) {
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- player->Inventory[bau].Index = 2406;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Fenrir]");
- } else if(_rand <= 60) {
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- player->Inventory[bau].Index = 3182;
- SendClientMsg(clientid, "!Chegou um item: [Pergaminho da Água (A)]");
- } else if(_rand <= 80) {
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 2;
- player->Inventory[bau].Index = 3326;
- SendClientMsg(clientid, "!Chegou um item: [Pesadelo (A/G)]");
- } else {
- player->Inventory[bau].Index = 5338;
- SendClientMsg(clientid, "!Chegou um item: [Pedra Ideal]");
- }
- SendSlot(clientid, bau); SendSlot(clientid, ny);
- SendSay(npcid, "NPC VI");
- }
- void NPCVII(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- int bau = GetFirstSlotSADD(clientid, 4198, 64);
- if(bau == -1) {
- SendSay(npcid, "Traga-me o Baú de Tesouro!");
- return;
- }
- int slot = -1;
- for(int i=0;i<64;i++) {
- if(player->Inventory[i].Index == 3182) {
- if(player->Inventory[i].EF1 == 61)
- if(player->Inventory[i].EFV1 == 2) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF2 == 61)
- if(player->Inventory[i].EFV2 == 2) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF3 == 61)
- if(player->Inventory[i].EFV3 == 2) {
- slot = i;
- break;
- }
- }
- }
- if(slot == -1) {
- SendSay(npcid, "Traga-me 2 Pergaminhos da Água (A)");
- return;
- }
- if(player->Gold < 10000000) {
- SendSay(npcid, "Preciso de 10.000.000 de gold para a troca!");
- return;
- }
- int _rand = rand() % 100;
- memset(&player->Inventory[bau],0, 8);
- memset(&player->Inventory[slot], 0, 8);
- player->Gold -= 10000000;
- if(_rand <= 20) {
- player->Inventory[bau].Index = 3326;
- player->Inventory[slot].Index = 3182;
- SendClientMsg(clientid, "!Chegou um item: [Pesadelo (M/G) + Perg. Água (A)]");
- } else if(_rand <= 40) {
- player->Inventory[bau].Index = 2411;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 5;
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Unicórnio]");
- } else if(_rand <= 60) {
- player->Inventory[bau].Index = 3182;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 3;
- SendClientMsg(clientid, "!Chegou um item: [Pergaminho da Água (A) x3]");
- } else if(_rand <= 80) {
- player->Inventory[bau].Index = 3326;
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 2;
- SendClientMsg(clientid, "!Chegou um item: [Pesadelo (A/G) x2]");
- } else {
- player->Inventory[bau].Index = 5338;
- SendClientMsg(clientid, "!Chegou um item: [Pedra Ideal]");
- }
- SendSlot(clientid, slot);
- SendSlot(clientid, bau);
- SendScore(clientid); SendStats(clientid);
- SendSay(npcid, "NPC VII");
- }
- void NPCVIII(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- if(player->Gold < 10000000) {
- SendSay(npcid, "Preciso de 10 milhões de gold para concluir a troca!");
- return;
- }
- int bau = GetFirstSlotSADD(clientid, 4198, 64);
- if(bau == -1) {
- SendSay(npcid, "Traga-me o Baú do Tesouro");
- return;
- }
- int slot = -1;
- for(int i=0;i<64;i++) {
- if(player->Inventory[i].Index == 3326) {
- if(player->Inventory[i].EF1 == 61)
- if(player->Inventory[i].EFV1 == 2) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF2 == 61)
- if(player->Inventory[i].EFV2 == 2) {
- slot = i;
- break;
- }
- else if(player->Inventory[i].EF3 == 61)
- if(player->Inventory[i].EFV3 == 2) {
- slot = i;
- break;
- }
- }
- }
- if(slot == -1) {
- SendSay(npcid, "Traga-me 2 Pesadelos (A/G)");
- return;
- }
- memset(&player->Inventory[bau], 0, 8);
- memset(&player->Inventory[slot], 0, 8);
- player->Gold -= 10000000;
- int _rand = rand() % 100;
- if(_rand <= 25) {
- int other = rand() % 100;
- if(other <= 25)
- player->Inventory[bau].Index = 1760, SendClientMsg(clientid, "!Chegou um item: [Sephirot (TransKnight)]");
- else if(other <= 50)
- player->Inventory[bau].Index = 1761, SendClientMsg(clientid, "!Chegou um item: [Sephirot (Foema)]");
- else if(other <= 75)
- player->Inventory[bau].Index = 1762, SendClientMsg(clientid, "!Chegou um item: [Sephirot (BeanstMaster)]");
- else
- player->Inventory[bau].Index = 1763, SendClientMsg(clientid, "!Chegou um item: [Sephirot (Huntress)]");
- } else if(_rand <= 50) {
- player->Inventory[bau].EF1 = 61;
- player->Inventory[bau].EFV1 = 10;
- int other = rand() % 100;
- if(other <= 25)
- player->Inventory[bau].Index = 2400, SendClientMsg(clientid, "!Chegou um item: [Âmago de Andaluz N x10]");
- else if(other <= 50)
- player->Inventory[bau].Index = 2405, SendClientMsg(clientid, "!Chegou um item: [Âmago de Andaluz B x10]");
- } else if(_rand <= 75) {
- player->Inventory[bau].Index = 4029;
- SendClientMsg(clientid, "!Chegou um item: [Barra de Prata (50mi)]");
- } else {
- player->Inventory[bau].Index = 3336;
- SendClientMsg(clientid, "!Chegou um item: [Retorno da Habilidade]");
- }
- SendScore(clientid);
- SendSlot(clientid, bau);
- SendSlot(clientid, slot);
- SendSay(npcid, "NPC VIII");
- }
- void NPCIX(int clientid, int npcid) {
- st_Mob *player = (st_Mob*)GetMobFromIndex(clientid);
- if(GetAmountItem(clientid, 4104) < 5) {
- SendSay(npcid, "Preciso que me traga 5 Bolsas da sorte!");
- return;
- }
- if(GetAmountItem(clientid, 4198) < 2) {
- SendSay(npcid, "Preciso que me traga 2 Baús do Tesouro!");
- return;
- }
- for(int i=0;i<5;i++) {
- int Slot = GetFirstSlotSADD(clientid, 4104, 64);
- if(Slot != -1)
- memset(&player->Inventory[Slot], 0, 8), SendSlot(clientid, Slot);
- }
- for(int i=0;i<2;i++) {
- int Slot = GetFirstSlotSADD(clientid, 4198, 64);
- if(Slot != -1)
- memset(&player->Inventory[Slot], 0, 8), SendSlot(clientid, Slot);
- }
- int _rand = rand() % 100;
- if(_rand <= 40) {
- int slot = GetFirstSlotSADD(clientid,0, 64);
- player->Inventory[slot].Index = 2406;
- player->Inventory[slot].EF1 = 61;
- player->Inventory[slot].EFV1 = 5;
- SendSlot(clientid, slot);
- SendClientMsg(clientid, "!Chegou um item: [Âmago de Fenrir x5]");
- } else if(_rand <= 55) {
- int slot = GetFirstSlotSADD(clientid,0, 64);
- player->Inventory[slot].Index = 2310;
- SendSlot(clientid, slot);
- SendClientMsg(clientid, "!Chegou um item: [Ovo de Andaluz N]");
- } else if(_rand <= 70) {
- int slot = GetFirstSlotSADD(clientid,0, 64);
- player->Inventory[slot].Index = 2315;
- SendSlot(clientid, slot);
- SendClientMsg(clientid, "!Chegou um item: [Ovo de Andaluz B]");
- } else if(_rand <= 85) {
- int slot = GetFirstSlotSADD(clientid,0, 64);
- player->Inventory[slot].Index = 2316;
- SendSlot(clientid, slot);
- SendClientMsg(clientid, "!Chegou um item: [Ovo de Fenrir]");
- } else {
- int slot = GetFirstSlotSADD(clientid,0, 64);
- player->Inventory[slot].Index = 2321;
- SendSlot(clientid, slot);
- SendClientMsg(clientid, "!Chegou um item: [Ovo de Unicórnio]");
- }
- SendSay(npcid, "NPC IX");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement