⚙️Private Garages Config
Explore the functionality of our Private Garages, offering shell based vehicle storage.
In-Depth Explanation
Config.BypassPrivateGarage = true
Config.BypassPrivateGarageJobs = {
[1] = "police1",
[2] = "police2",
}
This setting enables the option for specific jobs to conduct raids on private garages, with support for multiple jobs to participate in these raids.
polyzone = {coords=vector4(-353.65, 6263.19, 31.49, 135.0), p1=0.7, p2=0.6, p3 = 0.5, maxZ = 1.5, minZ = 1.5, distanceBelow = 20.0},
Coords (Vector4): Set the garage's starting position to ensure proper player heading upon exit.
Box Sphere Dimensions (p1, p2, p3): Define the dimensions of the box sphere within the polyzone.
Height Adjustments (maxZ, minZ): Customize the polyzone's height based on original coordinates with +/- 1.5 Z-axis adjustments.
Shell Depth (distanceBelow): Determine the depth at which the garage shell will be created, currently set to 20.0 units.
vehicleShellOffset = vector3(0.0, 0.0, 0.0),
onFootShellOffset = vector3(13.5, 1.64, 0.0),
This setting is used to establish precise positions for vehicle and on-foot entries, functioning as an offset.
For on-foot entries, 'onFootShellOffset' adjusts the x, y, and z axes by adding 13.5 units to the x value, 1.64 units to the y axis, and keeping the z axis at 0.0 units. To calculate offset values, subtract your desired coordinates from the vector4(polyzone) coordinates.
Keep in mind you can set the vector3 values on a negative axis.
For coding nerds like me here is the actual code responsible for this:
SetEntityCoords(globalPlayerPed, Config.PrivateGarages[localisedGarageID].polyzone.coords.x + Config.PrivateGarages[localisedGarageID].onFootShellOffset.x, Config.PrivateGarages[localisedGarageID].polyzone.coords.y + Config.PrivateGarages[localisedGarageID].onFootShellOffset.y, Config.PrivateGarages[localisedGarageID].polyzone.coords.z - Config.PrivateGarages[localisedGarageID].polyzone.distanceBelow + Config.PrivateGarages[localisedGarageID].onFootShellOffset.z, false, false, false, false)
Last updated
Was this helpful?