---
title: "SetVehicleVirtualWorld | open.mp"
description: "Sets the 'virtual world' of a vehicle."
canonical: https://omp.itsneufox.com/uk/docs/scripting/functions/SetVehicleVirtualWorld
language: uk
---

# SetVehicleVirtualWorld

## Description

Sets the 'virtual world' of a vehicle. Players will only be able to see vehicles in their own virtual world.

| Name | Description |
| --- | --- |
| vehicleid | The ID of vehicle to set the virtual world of. |
| virtualWorld | The ID of the virtual world to put the vehicle in. |

## Returns

This function does not return any specific values.

## Examples

```c
SetVehicleVirtualWorld(GetPlayerVehicleID(playerid), 10);
SetPlayerVirtualWorld(playerid, 10);
```

## Related Functions

-   [GetVehicleVirtualWorld](https://omp.itsneufox.com/uk/docs/scripting/functions/GetVehicleVirtualWorld): Check what virtual world a vehicle is in.
-   [SetPlayerVirtualWorld](https://omp.itsneufox.com/uk/docs/scripting/functions/SetPlayerVirtualWorld): Set the virtual world of a player.
