Eluna implement changes from new_mthread to master ~ Does not add multithread support