|
|
@ -3533,7 +3533,7 @@ function transponder_solo_message(info) |
|
|
|
counter = counter + 1 |
|
|
|
counter = counter + 1 |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
if counter == 4 and solo_data["time"] - solo_data_antiflood[sender][i]["time"] < 10 then |
|
|
|
if counter == 4 and os.time() - solo_data_antiflood[sender][i]["antiflood"] < 10 then |
|
|
|
result_find = true |
|
|
|
result_find = true |
|
|
|
break |
|
|
|
break |
|
|
|
end |
|
|
|
end |
|
|
@ -3545,6 +3545,7 @@ function transponder_solo_message(info) |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
solo_data_antiflood[sender][#solo_data_antiflood[sender]+1] = solo_data |
|
|
|
solo_data_antiflood[sender][#solo_data_antiflood[sender]+1] = solo_data |
|
|
|
|
|
|
|
solo_data_antiflood[sender][#solo_data_antiflood[sender]]["antiflood"] = os.time() |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
@ -4215,29 +4216,24 @@ function luChecker.checkerLoad(playerId, data, position) -- |
|
|
|
if luChecker.truckers[playerId]["trailerData"]["trailerId"] ~= data["trailerId"] then |
|
|
|
if luChecker.truckers[playerId]["trailerData"]["trailerId"] ~= data["trailerId"] then |
|
|
|
sampAddChatMessage(data["trailerId"],-1) |
|
|
|
sampAddChatMessage(data["trailerId"],-1) |
|
|
|
if getLocalPlayerId() ~= playerId then |
|
|
|
if getLocalPlayerId() ~= playerId then |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
local trucker_x, trucker_y, trucker_z = position.x, position.y, position.z |
|
|
|
local trucker_x, trucker_y, trucker_z = position.x, position.y, position.z |
|
|
|
local key, x, y, z = getKeysPoint(trucker_x, trucker_y, trucker_z) |
|
|
|
local key, x, y, z = getKeysPoint(trucker_x, trucker_y, trucker_z) |
|
|
|
|
|
|
|
local cargoNow = (key:find("n") and 1 or (key:find("y") and 2 or (key:find("l") and 3 or 0))) |
|
|
|
|
|
|
|
if cargoNow == inifiles.Settings.luCheckerCargo and inifiles.Settings.luCheckerCargo ~= 0 then |
|
|
|
|
|
|
|
local local_x, local_y, local_z = getCharCoordinates(PLAYER_PED) |
|
|
|
|
|
|
|
local dist_localPlayer_storage = getDistanceBetweenCoords3d(local_x, local_y, local_z, x, y, z) |
|
|
|
|
|
|
|
local dist_trucker_storage = getDistanceBetweenCoords3d(trucker_x, trucker_y, trucker_z, x, y, z) |
|
|
|
|
|
|
|
|
|
|
|
local local_x, local_y, local_z = getCharCoordinates(PLAYER_PED) |
|
|
|
if dist_localPlayer_storage <= 120.0 and dist_trucker_storage <= 50.0 then |
|
|
|
local dist_localPlayer_storage = getDistanceBetweenCoords3d(local_x, local_y, local_z, x, y, z) |
|
|
|
solo_message_send = { |
|
|
|
local dist_trucker_storage = getDistanceBetweenCoords3d(trucker_x, trucker_y, trucker_z, x, y, z) |
|
|
|
name = getNameById(playerId), |
|
|
|
|
|
|
|
id = playerId, |
|
|
|
if dist_localPlayer_storage <= 120.0 and dist_trucker_storage <= 50.0 then |
|
|
|
action = "load", |
|
|
|
if key == "ls" or key == "sf" then |
|
|
|
cargo = key, |
|
|
|
if inifiles.Settings.luCheckerCargo >= 1 and inifiles.Settings.luCheckerCargo <= 3 then |
|
|
|
time = os.time() |
|
|
|
key = key..cargo_replace[inifiles.Settings.luCheckerCargo] |
|
|
|
} |
|
|
|
end |
|
|
|
sampAddChatMessage("èãðîê ïîëó÷èë ãðóç "..playerId.." "..dist_localPlayer_storage.." "..dist_trucker_storage.." +++ "..luChecker.truckers[playerId]["trailerData"]["trailerId"].." ++++ "..data["trailerId"],-1) |
|
|
|
end |
|
|
|
end |
|
|
|
solo_message_send = { |
|
|
|
|
|
|
|
name = getNameById(playerId), |
|
|
|
|
|
|
|
id = playerId, |
|
|
|
|
|
|
|
action = "load", |
|
|
|
|
|
|
|
cargo = key, |
|
|
|
|
|
|
|
time = os.time() |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
sampAddChatMessage("èãðîê ïîëó÷èë ãðóç "..playerId.." "..dist_localPlayer_storage.." "..dist_trucker_storage.." +++ "..luChecker.truckers[playerId]["trailerData"]["trailerId"].." ++++ "..data["trailerId"],-1) |
|
|
|
|
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|
end |
|
|
|