You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/client/ClientOnLinux.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@
5
5
6
6
7
7
To get the client to run you need to download the launcher, and [omp-client.dll](https://assets.open.mp/omp-client.dll). \
8
-
Then you need to put omp-client.dll in the AppData\Local\com.open.mp\omp\ folder of your prefix.\
8
+
Then you need to put omp-client.dll in the AppData\Local\mp.open.launcher\omp\ folder of your prefix.\
9
9
After that, you can execute the open mp launcher through the cli, or make a batch file like the one below, so that you can add it to your launcher of choice.
// Mark that the player should be placed in their vehicle once it is fully loaded.
40
+
// This avoids issues where the vehicle might not yet be loaded on the client's side.
41
+
SetPVarInt(playerid, "PutPlayerInVehicle", 1);
42
+
29
43
return 1;
30
44
}
45
+
46
+
public OnVehicleStreamIn(vehicleid, forplayerid)
47
+
{
48
+
// This callback is triggered when a vehicle streams in for the player (i.e. when it is loaded into memory).
49
+
// Check if the streamed-in vehicle is the player's and if they need to be placed in it.
50
+
if (vehicleid == s_PlayerVehicle[forplayerid] && GetPVarInt(forplayerid, "PutPlayerInVehicle"))
51
+
{
52
+
// Put the player into the vehicle.
53
+
PutPlayerInVehicle(forplayerid, vehicleid, 0);
54
+
55
+
// Clear the marker to prevent repeatedly putting the player into the vehicle
56
+
// (e.g., if the player leaves the vehicle and it streams in again later).
57
+
DeletePVar(forplayerid, "PutPlayerInVehicle");
58
+
}
59
+
60
+
return 1;
61
+
}
62
+
31
63
```
32
64
33
65
| ID | Seat |
@@ -48,7 +80,9 @@ You can use [GetPlayerVehicleSeat](GetPlayerVehicleSeat) in a loop to check if a
48
80
49
81
:::warning
50
82
51
-
If the seat is invalid or is taken, will cause a crash when they EXIT the vehicle.
83
+
* If the seat is invalid or already taken, the client will crash when they EXIT the vehicle.
84
+
* Putting a player into a vehicle that is not streamed in can be unreliable. This is due to a potential client-side issue where the vehicle may not have fully loaded into memory yet.
85
+
* This also applies when attempting to put a player into a vehicle that was just created.
0 commit comments