Trying to solve crash in mob_thread_func

It was related to a null np➜env.

Should close #2 and #3