Add ItemPile.fromArray([item, count, tags])

Just calls the constructor with those arguments, but takes an array.
Useful to avoid difficulties in calling constructors with apply(), see
http://stackoverflow.com/questions/1959247/javascript-apply-on-constructor-throwing-malformed-formal-parameter
Add fromArrayIfArray, passes to fromArray if array, otherwise returns as-is