National Points Shop [18xx]

  • HyperFilter | DoS Protection | DDoS Protection | DoS Mitigation | DDoS Mitigation | AntiDoS | AntiDDoS | Proxy Shielding

jarmen

Hızlı Cüce
Kayıtlı Üye
Joined
Sep 2, 2012
Messages
609
Reaction score
3
Points
18
Age
35
  1. uint32 m_iNPBuyPrice;void CUser::ItemTrade(Packet & pkt)







    You must reply in the thread to view hidden text.
    Code:
    else if (type == 1 && pNpc->m_iSellingGroup == 249000)
    
    { 
    
    if (m_sItemArray[SLOT_MAX+pos].nNum != 0)
    
    {
    
    if (m_sItemArray[SLOT_MAX+pos].nNum != itemid)
    
    {
    
    errorCode = 2;
    
    goto fail_return;
    
    }
    
    
    
    
    
    if (!pTable->m_bCountable || count <= 0)
    
    {
    
    errorCode = 2;
    
    goto fail_return;
    
    }
    
    
    
    
    
    if (pTable->m_bCountable 
    
    && (count + m_sItemArray[SLOT_MAX+pos].sCount) > MAX_ITEM_COUNT)
    
    {
    
    errorCode = 4;
    
    goto fail_return; 
    
    }
    
    }
    
    transactionPrice = ((uint32)pTable->m_iNPBuyPrice * count);
    
    
    
    
    
    if(pTable->m_bSellingGroup == 0)
    
    {
    
    errorCode = 3;
    
    goto fail_return;
    
    }
    
    
    
    
    
    if (!hasLoyalty(transactionPrice))
    
    {
    
    errorCode = 3;
    
    goto fail_return;
    
    }
    
    
    
    
    
    if (((pTable->m_sWeight * count) + m_sItemWeight) > m_sMaxWeight)
    
    {
    
    errorCode = 4;
    
    goto fail_return;
    
    }
    
    
    
    
    
    m_sItemArray[SLOT_MAX+pos].nNum = itemid;
    
    m_sItemArray[SLOT_MAX+pos].sDuration = pTable->m_sDuration;
    
    m_sItemArray[SLOT_MAX+pos].sCount += count;
    
    
    
    
    
    m_iLoyalty -= transactionPrice;
    
    
    
    
    
    if (!pTable->m_bCountable)
    
    m_sItemArray[SLOT_MAX+pos].nSerialNum = g_pMain->GenerateItemSerial();
    
    
    
    
    
    SetUserAbility(false);
    
    SendItemWeight();
    
    }
    
    else if (type == 2 && pNpc->m_iSellingGroup == 249000)
    
    goto fail_return;
    
    .
    
    .
    
    .
    
    fail_return: 
    
    result << bSuccess;
    
    if (!bSuccess)
    
    result << errorCode;
    
    else if (pNpc->m_iSellingGroup == 249000 && bSuccess)
    
    result << pTable->m_bSellingGroup << m_iLoyalty << transactionPrice;
    
    else if (pNpc->m_iSellingGroup != 249000 && bSuccess)
    
    result << pTable->m_bSellingGroup << m_iGold << transactionPrice; // price bought or sold for





    ALINTIDIR



    Credits by Christian!
 
Cevap: National Points Shop [18xx]



Credits by Christian!
 
Cevap: National Points Shop [18xx]



sagollll!!!
 
Cevap: National Points Shop [18xx]



Teşekkür ederim..
 
Cevap: National Points Shop [18xx]



teşekkürler
 
Cevap: National Points Shop [18xx]



teşekkürler
 
Cevap: National Points Shop [18xx]



thanks
 
Cevap: National Points Shop [18xx]



tyyyyyyyyyyy
 
Cevap: National Points Shop [18xx]



teşekkürler hocam ..
 
Cevap: National Points Shop [18xx]



AAAAAAAAAAAAAAAAAAAAA
 
Cevap: National Points Shop [18xx]



bakalım....
 
Cevap: National Points Shop [18xx]



teşekürler
 
Cevap: National Points Shop [18xx]



teşekkürler











 
Cevap: National Points Shop [18xx]



thanks
 
Cevap: National Points Shop [18xx]



teşekkürler
 
Back
Top Bottom
Reklam
Reklam