Made some functions and stuff