Handling virtual environment