viewing paste Unknown #7618 | C

Posted on the
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
static inline unsigned char clif_bl_type(struct block_list *bl) {
    switch (bl->type) {
        case BL_PC:    return (disguised(bl) && !pcdb_checkid(iStatus->get_viewdata(bl)->class_))? 0x1:0x0; //PC_TYPE
        case BL_ITEM:  return 0x2; //ITEM_TYPE
        case BL_SKILL: return 0x3; //SKILL_TYPE
        case BL_CHAT:  return 0x4; //UNKNOWN_TYPE
        case BL_MOB:   return pcdb_checkid(iStatus->get_viewdata(bl)->class_)?0x0:0x5; //NPC_MOB_TYPE
        case BL_NPC:   return 0x6; //NPC_EVT_TYPE
        case BL_PET:   return pcdb_checkid(iStatus->get_viewdata(bl)->class_)?0x0:0x7; //NPC_PET_TYPE
        case BL_HOM:   return 0x8; //NPC_HOM_TYPE
        case BL_MER:   return 0x9; //NPC_MERSOL_TYPE
        case BL_ELEM:  return 0xa; //NPC_ELEMENTAL_TYPE
        default:       return 0x1; //NPC_TYPE
    }
}
 
Viewed 759 times, submitted by Guest.