Premium .Avenue™ 776 Posted October 18, 2015 Premium Share Posted October 18, 2015 (edited) bool CHARACTER::EquipItem([...]) { [...] if (item->GetType() == ITEM_COSTUME && item->GetSubType() >= COSTUME_BELL) { if (!GetWear(WEAR_WEAPON)) { return false; } } } Doesn't work. function: disable equipping costume weapons, when weapons aren't worn. Edited October 18, 2015 by .Avenue™ Link to comment Share on other sites More sharing options...
Active Member Koray 1993 Posted October 18, 2015 Active Member Share Posted October 18, 2015 Do you want if weapon is not equipped block equip costume weapon, right? Link to comment Share on other sites More sharing options...
Premium .Avenue™ 776 Posted October 18, 2015 Author Premium Share Posted October 18, 2015 Do you want if weapon is not equipped block equip costume weapon, right? exactly this Link to comment Share on other sites More sharing options...
Active Member Koray 1993 Posted October 18, 2015 Active Member Share Posted October 18, 2015 Do you want if weapon is not equipped block equip costume weapon, right? exactly this send me your costume subtype enum Link to comment Share on other sites More sharing options...
Active Member Koray 1993 Posted October 19, 2015 Active Member Share Posted October 19, 2015 try this ... if (item->GetType() == ITEM_COSTUME && item->GetSubType() >= COSTUME_BELL && item->GetSubType() <= COSTUME_TWO_HANDED) { LPITEM lpWeapon = GetWear(WEAR_WEAPON); if (lpWeapon == NULL) return false; ... Link to comment Share on other sites More sharing options...
Premium .Avenue™ 776 Posted October 19, 2015 Author Premium Share Posted October 19, 2015 try this ... if (item->GetType() == ITEM_COSTUME && item->GetSubType() >= COSTUME_BELL && item->GetSubType() <= COSTUME_TWO_HANDED) { LPITEM lpWeapon = GetWear(WEAR_WEAPON); if (lpWeapon == NULL) return false; ... I've already fixed it. I pasted the code on wrong place. Can you add me please in Skype? (mravenue.epvp) I've got a question Link to comment Share on other sites More sharing options...
Rideas 167 Posted October 19, 2015 Share Posted October 19, 2015 try this ... if (item->GetType() == ITEM_COSTUME && item->GetSubType() >= COSTUME_BELL && item->GetSubType() <= COSTUME_TWO_HANDED) { LPITEM lpWeapon = GetWear(WEAR_WEAPON); if (lpWeapon == NULL) return false; ... I've already fixed it. I pasted the code on wrong place. Can you add me please in Skype? (mravenue.epvp) I've got a question Another problem fix bool CHARACTER::UnequipItem(LPITEM item) { [...] if (item->GetType() == ITEM_WEAPON) { if (GetWear(WEAR_COSTUME_WEAPON)) { ChatPacket(CHAT_TYPE_INFO, "Remove the first costume weapons"); return false; } } } 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now