查看: 631|回复: 0
收起左侧

[文字教程] 禁用在空中的车辆控制

[复制链接]
admin 发表于 2022-12-19 10:21:54 | 显示全部楼层 |阅读模式
使用方法:插入任何客户端脚本或者单独建立脚本!
-- CLIENT --
Citizen.CreateThread(function()
    while true do
        local idle = 1000
        local veh = GetVehiclePedIsIn(PlayerPedId(),false)
        if DoesEntityExist(veh) and not IsEntityDead(veh) then
            idle = 5
            local model = GetEntityModel(veh)
            if not IsThisModelABoat(model) and not IsThisModelAHeli(model) and not IsThisModelAPlane(model) and not IsThisModelABicycle(model) and not IsThisModelABike(model) and not IsThisModelAQuadbike(model) and IsEntityInAir(veh) then
                idle = 5
                DisableControlAction(0,59)
                DisableControlAction(0,60)
                --DisableControlAction(0,73)
            end
        end
    Citizen.Wait(idle)
    end
end)


楼主热帖
回复 论坛版权

使用道具 举报

文明发言,和谐互动
文明发言,和谐互动
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|首页 ( 冀ICP备2021005225号-1 ) |网站地图

GMT+8, 2025-2-9 01:06 , Processed in 0.070239 second(s), 13 queries , Gzip On, Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表