second commit, implemented conceptually, wip , not really tested and probably crushing