redid the structs, basic implementation for 3 of 4 functions, a few features are missing