/// <summary> /// Get an entity by name. /// </summary> /// <param name="name"> The name of the entity. </param> /// <returns> A reference to the entity. </returns> /// <remarks> /// If multiple entities have the same name, it will return the first found. Consider using /// IDs where necessary. /// </remarks> public static EntityBase Find(string name) { var id = EntityInterop.FindEntity(name); if (id == 0) { return(null); } return(Get(new EntityId(id))); }