working on some level flow code