Files
Elite-Gaming-FiveM-Old/resources/tiller/tiller.lua
T
2025-01-29 23:19:03 -08:00

324 lines
9.9 KiB
Lua

-- 1 = X
-- 2 = Y
-- 3 = Z
-- to define if prop rotates or moves, use:
-- if rotation, add:
tiller = {
model = `tillertrailer`,
name = "TILLER",
isTrailer = true,
controlToOperate = {73, "INPUT_VEH_DUCK"},
pedAttachment = {
id = "LadderSeat",
offSet = {-0.5, 0.5, 0.5},
rotation = {0.0, 0.0, 180.0},
},
-- Menu is not usable while driving and controlling
menu = {
enabled = true,
resourceName = "tiller",
menuControls = {
openAuto = true,
openMenuKey = 311,
-- Export to open menu should be named openMenu()
}
},
drawRotation = true,
animation = {
enabled = true,
idle = {
dict = "amb@world_human_stand_guard@male@base",
name = "base"
},
},
cage = {
enabled = false,
id = "Cage",
offSet = {0.0, 0.0, 0.0},
rotation = {0.0, 0.0, 0.0},
},
water = {
enabled = true,
control = {0, 101},
locations = {
["InnerLadder"] = {
{
scale = 1.0,
asset = "core",
name = "water_cannon_jet",
offSet = {0.09, -0.99, -0.25},
rotation = {-10.0, 0.0, 180.0},
},
},
}
},
data = {
{
id = "LadderSeat",
model = `tiller_seat`,
isLadder = false,
attachTo = "vehicle",
boneIndex = "", -- If attaching to vehicle
defaultOffSet = {0.02, 5.71, 1.5},
offSet = {0.02, 5.71, 1.5},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = false,
minimumOffSet = {0.0, 0.0, 0.0},
maxOffSet = false,
maximumOffSet = {0.0, 0.0, 0.0},
controls = {
[63] = {
movementType = "rotate",
axis = 3,
movementAmount = 0.1,
},
[64] = {
movementType = "rotate",
axis = 3,
movementAmount = -0.1,
},
}
},
{
id = "LadderBottom",
model = `tiller_base`,
isLadder = false,
attachTo = "LadderSeat",
defaultOffSet = {0.0, -0.25, 0.02},
offSet = {0.0, -0.25, 0.02},
rotation = {2.8, 0.0, 0.0},
minRotation = true,
minimumRotation = {-82.0, 0.0, 0.0},
maxRotation = true,
maximumRotation = {2.8, 0.0, 0.0},
minOffSet = false,
minimumOffSet = {0.0, 0.0, 0.0},
maxOffSet = false,
maximumOffSet = {0.0, 0.0, 0.0},
controls = {
[136] = {
movementType = "rotate",
axis = 1,
movementAmount = -0.1,
},
[130] = {
movementType = "rotate",
axis = 1,
movementAmount = 0.1,
},
}
},
{
id = "OuterLadder",
model = `tiller_outer`,
isLadder = true,
attachTo = "LadderBottom",
defaultOffSet = {-0.005, -4.0, 0.134},
offSet = {-0.005, -4.0, 0.134},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.0, -10.0, 0.0},
maxOffSet = true,
maximumOffSet = {-0.005, -4.0, -0.134},
controls = {
[131] = {
movementType = "move",
axis = 2,
movementAmount = -0.01,
},
[132] = {
movementType = "move",
axis = 2,
movementAmount = 0.01,
},
}
},
{
id = "MiddleLadder",
model = `tiller_middle`,
isLadder = true,
attachTo = "OuterLadder",
defaultOffSet = {0.0, -0.13, 0.158},
offSet = {0.0, -0.13, 0.158},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.0, -5.5, 0.0},
maxOffSet = true,
maximumOffSet = {0.0, -0.13, 0.0},
controls = {
[131] = {
movementType = "move",
axis = 2,
movementAmount = -0.01,
},
[132] = {
movementType = "move",
axis = 2,
movementAmount = 0.01,
},
}
},
{
id = "InnerLadder",
model = `tiller_inner`,
isLadder = true,
attachTo = "MiddleLadder",
defaultOffSet = {-0.088, -3.69, -0.067},
offSet = {-0.088, -3.69, -0.067},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.0, -9.59, 0.0},
maxOffSet = true,
maximumOffSet = {0.0, -3.69, 0.0},
controls = {
[131] = {
movementType = "move",
axis = 2,
movementAmount = -0.01,
},
[132] = {
movementType = "move",
axis = 2,
movementAmount = 0.01,
},
}
},
{
id = "OutRigger1",
model = `tiller_outrigger`,
isLadder = false,
attachTo = "vehicle",
defaultOffSet = {-1.0, 3.7, -0.36},
offSet = {-1.0, 3.7, -0.36},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, -0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {-1.8, 0.0, 0.0},
maxOffSet = true,
maximumOffSet = {-1.0, 0.0, 0.0},
controls = {
[208] = {
movementType = "move",
axis = 1,
movementAmount = -0.01,
},
[207] = {
movementType = "move",
axis = 1,
movementAmount = 0.01,
},
}
},
{
id = "Foot1",
model = `tiller_foot`,
isLadder = false,
attachTo = "OutRigger1",
defaultOffSet = {0.0, -0.01, 0.0},
offSet = {0.0, -0.01, 0.0},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.0, 0.0, -0.49},
maxOffSet = true,
maximumOffSet = {0.0, 0.0, 0.0},
controls = {
[121] = {
movementType = "move",
axis = 3,
movementAmount = -0.002,
},
[212] = {
movementType = "move",
axis = 3,
movementAmount = 0.002,
},
}
},
{
id = "OutRigger2",
model = `tiller_outrigger`,
isLadder = false,
attachTo = "vehicle",
defaultOffSet = {1.0, 3.87, -0.36},
offSet = {1.0, 3.87, -0.36},
rotation = {0.0, 0.0, 180.0},
minRotation = false,
minimumRotation = {0.0, -0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.98, 0.0, 0.0},
maxOffSet = true,
maximumOffSet = {1.8, 0.0, 0.0},
controls = {
[208] = {
movementType = "move",
axis = 1,
movementAmount = 0.01,
},
[207] = {
movementType = "move",
axis = 1,
movementAmount = -0.01,
},
}
},
{
id = "Foot2",
model = `tiller_foot`,
isLadder = false,
attachTo = "OutRigger2",
defaultOffSet = {0.0, -0.01, 0.0},
offSet = {0.0, -0.01, 0.0},
rotation = {0.0, 0.0, 0.0},
minRotation = false,
minimumRotation = {0.0, 0.0, 0.0},
maxRotation = false,
maximumRotation = {0.0, 0.0, 0.0},
minOffSet = true,
minimumOffSet = {0.0, 0.0, -0.49},
maxOffSet = true,
maximumOffSet = {0.0, 0.0, 0.0},
controls = {
[121] = {
movementType = "move",
axis = 3,
movementAmount = -0.002,
},
[212] = {
movementType = "move",
axis = 3,
movementAmount = 0.002,
},
}
},
}
}
addVehicle(tiller)