Hey habe ein Problem beim Godmother Script und zwar wenn ich LVPD bin kann ich in Reporter Fahrzeuge rein also bei jeder Fraktion
Es kommen auch keine Errors oder Warnings das war seit dem ich das mit dem Carrank habe von ertlflorian1:
Lua
function checkFacCar ( thePlayer, seat )
local carfac = tonumber (getElementData ( source, "faccarid" ))
local carrank = tonumber (getElementData (source, "Rank"))
local playerrank = tonumber (getElementData (thePlayer, "Rank"))
local isPlayerFaction = isFaction (thePlayer, carfac)
if carfac ~= nil then
isPlayerFaction = isFaction (thePlayer, carfac)
else
isPlayerFaction = true
end
if ( carfac ~= false ) and (carrank == nil) then
if ( seat == 0 ) then
if ( isPlayerFaction == false ) then
removePedFromVehicle ( thePlayer )
outputChatBox ( "Dieses Fahrzeug gehört einer anderen Fraktion!", thePlayer, 255, 0, 0 )
end
end
elseif ( carfac ~= false ) and (carrank ~= nil) then
if (playerrank < carrank) and (seat == 0) and ( isPlayerFaction == true ) then
removePedFromVehicle ( thePlayer )
outputChatBox ( "Du bist nicht Rank "..carrank.."!", thePlayer, 255, 0, 0 )
end
end
end
addEventHandler ( "onVehicleEnter", getRootElement(), checkFacCar )
Alles anzeigen
Das ist beim faccarcheck drin
Lua
aVan1 = createVehicle ( 582, 736, -1332.6999511719, 13.699999809265, 0, 0, 270, "Reporter" )
setVehicleColor ( aVan1, 6, 6, 6, 6 )
setVehiclePaintjob ( aVan1, 3 )
toggleVehicleRespawn ( aVan1, true )
setVehicleRespawnDelay ( aVan1, 3000)
setVehicleIdleRespawnDelay ( aVan1, 6000)
setElementData(aVan1,"faccarid", 3)
setElementData(aVan1,"Rank", 2)
So habe ich es bei den Fahrzeugen
Brauche dringend hilfe