public Entity Crafty.e(String componentList)
public Entity Crafty.e(String component1[, .., String componentN])
Creates an entity. Any arguments will be applied in the same
way .addComponent()
is applied as a quick way to add components.
Any component added will augment the functionality of the created entity by assigning the properties and methods from the component to the entity.
var myEntity = Crafty.e("2D, DOM, Color");