got modify_copy working, still a bit hacky