partially working code... im sleepy