More fixes to env, still problemes with neg index