making this a proper engine