query(e, 'attribute')

View on GitHub

Syntax

query(entity, 'attribute')
query(entity, 'attribute', name)

returns the value of an attribute of the living entity. If the name is not provided, returns a map of all attributes and values of this entity. If an attribute doesn’t apply to the entity, or the entity is not a living entity, null is returned.