up to date with functions and draw