Rewrote most of create engine