Anubis 0 Posted December 13, 2020 Good day! everyone can i request how to change it color of using @whosell command something like this! if(s_type & 4 && ((item_data->type != IT_ARMOR && item_data->type != IT_WEAPON) || pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine != refine)) continue; if(item_data->type == IT_ARMOR) snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d] | Price %d | Amount %d | %s (%d,%d) | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine ,item_data->jname ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0] ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x,pl_sd->bl.y ,pl_sd->status.name); else if(item_data->type == IT_WEAPON) snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d,%d,%d,%d] | Price %d | Amount %d | %s (%d,%d) | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine ,item_data->jname ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[1] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[2] ,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[3] ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x,pl_sd->bl.y ,pl_sd->status.name); else snprintf(atcmd_output, CHAT_SIZE_MAX, "%s | Price %d | Amount %d | %s (%d,%d) | %s",item_data->jname ,pl_sd->vending[j].value ,pl_sd->vending[j].amount ,mapindex_id2name(pl_sd->mapindex) ,pl_sd->bl.x, pl_sd->bl.y ,pl_sd->status.name); if(pl_sd->vending[j].value < MinPrice) MinPrice = pl_sd->vending[j].value; if(pl_sd->vending[j].value > MaxPrice) MaxPrice = pl_sd->vending[j].value; clif_displaymessage(fd, atcmd_output); count++; flag = 1; } if (flag && pl_sd->mapindex == sd->mapindex) { clif_viewpoint(sd, 1, 1, pl_sd->bl.x, pl_sd->bl.y, ++sat_num, 0xFFFFFF); flag = 0; } } } mapit_free(iter); if(count > 0) { snprintf(atcmd_output, CHAT_SIZE_MAX, " Found %d ea. Prices from %dz to %dz.", count, MinPrice, MaxPrice); Quote Share this post Link to post Share on other sites
0 4144 364 Posted December 13, 2020 at first you using wrong code. must be not clif_displaymessage but clif->message For text with color try use clif->messagecolor_self or clif->messagecolor. also clif_viewpoint wrong too. must be used clif->viewpoint Quote Share this post Link to post Share on other sites
0 cookie-rae 6 Posted December 13, 2020 Hi sir 4144 he is using a rA mod. so that's why the variables are shown as like that. Quote Share this post Link to post Share on other sites
0 4144 364 Posted December 13, 2020 hm, then probably need write it topic what this is not hercules but rathena Quote Share this post Link to post Share on other sites
0 Anubis 0 Posted December 14, 2020 Hi try to use clif->messagecolor_self but not working can u make for me how to work messagecolor thank you Quote Share this post Link to post Share on other sites
0 Anubis 0 Posted December 14, 2020 anyone how to make color message in @whosell thanks. Quote Share this post Link to post Share on other sites
Good day! everyone can i request how to change it color of using @whosell command something like this!
if(s_type & 4 && ((item_data->type != IT_ARMOR && item_data->type != IT_WEAPON) || pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine != refine))
continue;
if(item_data->type == IT_ARMOR)
snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d] | Price %d | Amount %d | %s (%d,%d) | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine
,item_data->jname
,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0]
,pl_sd->vending[j].value
,pl_sd->vending[j].amount
,mapindex_id2name(pl_sd->mapindex)
,pl_sd->bl.x,pl_sd->bl.y
,pl_sd->status.name);
else if(item_data->type == IT_WEAPON)
snprintf(atcmd_output, CHAT_SIZE_MAX, "+%d %s[%d,%d,%d,%d] | Price %d | Amount %d | %s (%d,%d) | %s",pl_sd->cart.u.items_cart[pl_sd->vending[j].index].refine
,item_data->jname
,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[0]
,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[1]
,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[2]
,pl_sd->cart.u.items_cart[pl_sd->vending[j].index].card[3]
,pl_sd->vending[j].value
,pl_sd->vending[j].amount
,mapindex_id2name(pl_sd->mapindex)
,pl_sd->bl.x,pl_sd->bl.y
,pl_sd->status.name);
else
snprintf(atcmd_output, CHAT_SIZE_MAX, "%s | Price %d | Amount %d | %s (%d,%d) | %s",item_data->jname
,pl_sd->vending[j].value
,pl_sd->vending[j].amount
,mapindex_id2name(pl_sd->mapindex)
,pl_sd->bl.x, pl_sd->bl.y
,pl_sd->status.name);
if(pl_sd->vending[j].value < MinPrice) MinPrice = pl_sd->vending[j].value;
if(pl_sd->vending[j].value > MaxPrice) MaxPrice = pl_sd->vending[j].value;
clif_displaymessage(fd, atcmd_output);
count++;
flag = 1;
}
if (flag && pl_sd->mapindex == sd->mapindex) {
clif_viewpoint(sd, 1, 1, pl_sd->bl.x, pl_sd->bl.y, ++sat_num, 0xFFFFFF);
flag = 0;
}
}
}
mapit_free(iter);
if(count > 0) {
snprintf(atcmd_output, CHAT_SIZE_MAX, " Found %d ea. Prices from %dz to %dz.", count, MinPrice, MaxPrice);
Share this post
Link to post
Share on other sites