-
Quem está por aqui 0 membros estão online
- Nenhum usuário registrado visualizando esta página.
- 0
Nós fazemos uso de cookies no seu dispositivo para ajudar a tornar este site melhor. Você pode ajustar suas configurações de cookies , caso contrário, vamos supor que você está bem para continuar.
Pergunta
snow77 4
Quando uso os itens citados acima não acontece nada vou compartilhar o código da source. se alguem puder ajudar, tem alguns lugares que o código está comentado, não sei se é para tirar o comentário.
#pragma region Classe A
//if(Vol == 190){
if (item->sIndex == 4016)
{
STRUCT_ITEM *dest = GetItemPointer(&pMob[conn].MOB, pUser[conn].Cargo, m->DestType, m->DestPos);
if (dest == NULL)
{
sprintf(temp, "err,use item fail dest %d %d", m->DestType, m->DestPos);
ItemLog(temp, "-system", 0);
return;
}
if (m->DestType || m->DestPos >= 8 && m->DestPos < 18 || m->DestType == ITEM_PLACE_EQUIP && m->DestPos == 0 || m->DestType == ITEM_PLACE_EQUIP && m->DestPos == 1)
{
SendClientMessage(conn, "only possible with equipped weapons and armor");
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
int sanc = BASE_GetItemSanc(dest);
int ItemId = dest->sIndex;
// THIS FUCK SHIT NOT EFFECT haiss.
// BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 0 && zero. mean item dont have REFLEVEL WILL NOT EFFECT
//BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 1 && grade [A] replation in item List common file REFLEVEL,1
// BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 2 && grade replation in item List common file REFLEVEL,2
// BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 3 && grade [C] replation in item List common file REFLEVEL,3
// BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 4 && grade [D] replation in item List common file REFLEVEL,4
//BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 5 && grade [E] replation in item List common file REFLEVEL,5
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 6 grade [E] replation in item List common file REFLEVEL,6
if (sanc < 2 || BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 0 && BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 1 && BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 2
&& BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 3 && BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 4 && BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 5 && BASE_GetItemAbility(dest, EF_ITEMLEVEL) != 6)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
// the basic
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 0 &&
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 1 && god
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 2 && set E
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 3 && celes,unique
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 4
//the edit
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 10 && grade [A] replation in item List common file EF_MOBTYPE,10
// BASE_GetItemAbility(dest, EF_MOBTYPE) != 11 && grade replation in item List common file EF_MOBTYPE,11
// BASE_GetItemAbility(dest, EF_MOBTYPE) != 12 && grade [C] replation in item List common file EF_MOBTYPE,12
// BASE_GetItemAbility(dest, EF_MOBTYPE) != 13 && grade [D] replation in item List common file EF_MOBTYPE,13
//BASE_GetItemAbility(dest, EF_MOBTYPE) != 14 && grade [E] replation in item List common file EF_MOBTYPE,14
if (sanc < 2 || BASE_GetItemAbility(dest, EF_MOBTYPE) != 10 && BASE_GetItemAbility(dest, EF_MOBTYPE) != 2)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
//1103, Elmo_de_Couro(A), 1.0, 0.0.0.0.0, 1, 1650, 2, 0, 3, 0, 0, EF_CLASS, 1, EF_AC, 4, EF_SAVEMANA, 2, EF_MPADD, 4, EF_REFLEVEL, 1, EF_MOBTYPE, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
//1106, Elmo_de_Couro_Duro(A), 2.0, 0.0.0.0.0, 2, 9300, 2, 0, 3, 0, 0, EF_CLASS, 1, EF_AC, 11, EF_SAVEMANA, 3, EF_MPADD, 5, EF_REFLEVEL, 1, EF_MOBTYPE, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
//1109,Elmo_de_Couro_Batido(A),3.0,32.46.0.0.32,3,21000,2,0,3,0,0,EF_CLASS,1,EF_AC,22,EF_SAVEMANA,4,EF_MPADD,6,EF_REFLEVEL,2,EF_MOBTYPE,11,0,0,0,0,0,0,0,0,0,0,0,0
//1112,Elmo_de_Malha(A),4.0,32.46.0.0.32,4,98000,2,0,3,0,0,EF_CLASS,1,EF_AC,37,EF_SAVEMANA,5,EF_MPADD,7,EF_REFLEVEL,2,EF_MOBTYPE,11,0,0,0,0,0,0,0,0,0,0,0,0
//1163,Elmo_de_Aço(A),9.0,95.150.0.0.101,5,123000,2,2171,3,0,0,EF_CLASS,1,EF_AC,51,EF_SAVEMANA,6,EF_MPADD,8,EF_REFLEVEL,3,EF_MOBTYPE,12,0,0,0,0,0,0,0,0,0,0,0,0
//1178,Elmo_Dourado(A),10.0,95.150.0.0.101,6,125000,2,2176,3,0,0,EF_CLASS,1,EF_AC,65,EF_SAVEMANA,7,EF_MPADD,9,EF_REFLEVEL,3,EF_MOBTYPE,12,0,0,0,0,0,0,0,0,0,0,0,0
//1193,Elmo_Anão(A),11.0,135.210.0.0.141,7,135000,2,2181,3,0,0,EF_CLASS,1,EF_AC,79,EF_SAVEMANA,8,EF_MPADD,10,EF_REFLEVEL,4,EF_MOBTYPE,13,0,0,0,0,0,0,0,0,0,0,0,0
//1208,Elmo_Embutido(A),14.0,154.239.0.0.160,8,145000,2,2186,3,0,0,EF_CLASS,1,EF_AC,92,EF_SAVEMANA,9,EF_MPADD,10,EF_REFLEVEL,4,EF_MOBTYPE,13,0,0,0,0,0,0,0,0,0,0,0,0
//1225,Elmo_Mortal,19.0,285.0.0.0.0,10,160000,2,3801,1,0,0,EF_CLASS,1,EF_AC,108,EF_SAVEMANA,10,EF_MPADD,10,EF_REFLEVEL,5,EF_MOBTYPE,14,0,0,0,0,0,0,0,0,0,0,0,0
//1365,Tunica_Potâmides,45.0,227.0.0.0.0, 19,178000,4,2207,1,0,0,EF_CLASS,2,EF_AC,229,EF_CRITICAL,45,EF_HPADD,17,EF_REFLEVEL,5,EF_MOBTYPE,14,EF_LWORDGUILD,12,0,0,0,0,0,0,0,0,0,0
int replation = item->sIndex >= 4016 && item->sIndex <= 4020 ? item->sIndex - 4016 : item->sIndex - 4020;
if(BASE_GetItemAbility(dest, EF_ITEMLEVEL) != replation)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
SetItemBonus2(dest);
SendItem(conn, m->DestType, m->DestPos, dest);
SendEmotion(conn, 14, 3);
sprintf(temp, "useitem,reset effect %d+%d - (%d,%d,%d)", dest->sIndex, sanc, dest->stEffect[0].cEffect, dest->stEffect[1].cEffect, dest->stEffect[2].cEffect);
ItemLog(temp, pUser[conn].AccountName, pUser[conn].IP);
if (amount > 1)
BASE_SetItemAmount(item, amount - 1);
else
memset(item, 0, sizeof(STRUCT_ITEM));
return;
}
#pragma endregion
#pragma region Classe B
//if(Vol == 190) /// remark dulu.//
if (item->sIndex == 4017)
{
STRUCT_ITEM *dest = GetItemPointer(&pMob[conn].MOB, pUser[conn].Cargo, m->DestType, m->DestPos);
if (dest == NULL)
{
sprintf(temp, "err,use item fail dest %d %d", m->DestType, m->DestPos);
ItemLog(temp, "-system", 0);
return;
}
int sanc = BASE_GetItemSanc(dest);
int ItemId = dest->sIndex;
if (sanc < 2 || BASE_GetItemAbility(dest, EF_MOBTYPE) != 11 && BASE_GetItemAbility(dest, EF_MOBTYPE) != 2)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
SetItemBonus2(dest);
SendItem(conn, m->DestType, m->DestPos, dest);
SendEmotion(conn, 14, 3);
sprintf(temp, "useitem,reset effect %d+%d - (%d,%d,%d)", dest->sIndex, sanc, dest->stEffect[0].cEffect, dest->stEffect[1].cEffect, dest->stEffect[2].cEffect);
ItemLog(temp, pUser[conn].AccountName, pUser[conn].IP);
if (amount > 1)
BASE_SetItemAmount(item, amount - 1);
else
memset(item, 0, sizeof(STRUCT_ITEM));
return;
}
#pragma endregion
#pragma region Classe C
//if(Vol == 190) /// remark dulu.//
if (item->sIndex == 4018)
{
STRUCT_ITEM *dest = GetItemPointer(&pMob[conn].MOB, pUser[conn].Cargo, m->DestType, m->DestPos);
if (dest == NULL)
{
sprintf(temp, "err,use item fail dest %d %d", m->DestType, m->DestPos);
ItemLog(temp, "-system", 0);
return;
}
int sanc = BASE_GetItemSanc(dest);
int ItemId = dest->sIndex;
if (sanc < 2 || BASE_GetItemAbility(dest, EF_MOBTYPE) != 12 && BASE_GetItemAbility(dest, EF_MOBTYPE) != 2)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
SetItemBonus2(dest);
SendItem(conn, m->DestType, m->DestPos, dest);
SendEmotion(conn, 14, 3);
sprintf(temp, "useitem,reset effect %d+%d - (%d,%d,%d)", dest->sIndex, sanc, dest->stEffect[0].cEffect, dest->stEffect[1].cEffect, dest->stEffect[2].cEffect);
ItemLog(temp, pUser[conn].AccountName, pUser[conn].IP);
if (amount > 1)
BASE_SetItemAmount(item, amount - 1);
else
memset(item, 0, sizeof(STRUCT_ITEM));
return;
}
#pragma endregion
#pragma region Classe D
//if(Vol == 190) /// remark dulu.//
if (item->sIndex == 4019)
{
STRUCT_ITEM *dest = GetItemPointer(&pMob[conn].MOB, pUser[conn].Cargo, m->DestType, m->DestPos);
if (dest == NULL)
{
sprintf(temp, "err,use item fail dest %d %d", m->DestType, m->DestPos);
ItemLog(temp, "-system", 0);
return;
}
int sanc = BASE_GetItemSanc(dest);
int ItemId = dest->sIndex;
if (sanc < 2 || BASE_GetItemAbility(dest, EF_MOBTYPE) != 13 && BASE_GetItemAbility(dest, EF_MOBTYPE) != 2)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
SetItemBonus2(dest);
SendItem(conn, m->DestType, m->DestPos, dest);
SendEmotion(conn, 14, 3);
sprintf(temp, "useitem,reset effect %d+%d - (%d,%d,%d)", dest->sIndex, sanc, dest->stEffect[0].cEffect, dest->stEffect[1].cEffect, dest->stEffect[2].cEffect);
ItemLog(temp, pUser[conn].AccountName, pUser[conn].IP);
if (amount > 1)
BASE_SetItemAmount(item, amount - 1);
else
memset(item, 0, sizeof(STRUCT_ITEM));
return;
}
#pragma endregion
#pragma region Classe E
//if(Vol == 190) /// remark dulu.//
if (item->sIndex == 4020)
{
STRUCT_ITEM *dest = GetItemPointer(&pMob[conn].MOB, pUser[conn].Cargo, m->DestType, m->DestPos);
if (dest == NULL)
{
sprintf(temp, "err,use item fail dest %d %d", m->DestType, m->DestPos);
ItemLog(temp, "-system", 0);
return;
}
int sanc = BASE_GetItemSanc(dest);
int ItemId = dest->sIndex;
if (sanc < 2 || BASE_GetItemAbility(dest, EF_MOBTYPE) != 14 && BASE_GetItemAbility(dest, EF_MOBTYPE) != 2)
{
SendItem(conn, m->SourType, m->SourPos, item);
return;
}
SetItemBonus2(dest);
SendItem(conn, m->DestType, m->DestPos, dest);
SendEmotion(conn, 14, 3);
sprintf(temp, "useitem,reset effect %d+%d - (%d,%d,%d)", dest->sIndex, sanc, dest->stEffect[0].cEffect, dest->stEffect[1].cEffect, dest->stEffect[2].cEffect);
ItemLog(temp, pUser[conn].AccountName, pUser[conn].IP);
if (amount > 1)
BASE_SetItemAmount(item, amount - 1);
else
memset(item, 0, sizeof(STRUCT_ITEM));
return;
}
#pragma endregion
Clique aqui e adquira suas medalhas
Link para o comentário
Compartilhar em outros sites
15 respostass a esta questão
Posts Recomendados