Code:
x = 0;
y += lineHeight;
items.forEach(function(item) {
this.drawItemName(item, x, y, width);
y += lineHeight;
}, this);As it is right now it just lists the items, and if there is more than one of an item it appears twice in the list.
what I would like is for it to say Item x 2 instead, and obviously only appearing once in the list.
I'm still learning javascript and dont know how to check through the list like that, I tried reading through yanflys victory aftermath plugin but couldn't understand what it was doing.
can anyone help?