diff --git a/resources/[EGRP-CarPacks]/EGRP-Extras/data/speedc8bb/vehicles.meta b/resources/[EGRP-CarPacks]/EGRP-Extras/data/speedc8bb/vehicles.meta index 429c88bf6..ff8e8ae6c 100644 --- a/resources/[EGRP-CarPacks]/EGRP-Extras/data/speedc8bb/vehicles.meta +++ b/resources/[EGRP-CarPacks]/EGRP-Extras/data/speedc8bb/vehicles.meta @@ -15,7 +15,7 @@ null null - LYNX + c6v8sound LAYOUT_LOW SHERIFF_COVER_OFFSET_INFO EXPLOSION_INFO_DEFAULT diff --git a/resources/[EGRP-CarPacks]/EGRP-Extras/data/speeddemonrb/vehicles.meta b/resources/[EGRP-CarPacks]/EGRP-Extras/data/speeddemonrb/vehicles.meta index a3d62fcc4..02f091802 100644 --- a/resources/[EGRP-CarPacks]/EGRP-Extras/data/speeddemonrb/vehicles.meta +++ b/resources/[EGRP-CarPacks]/EGRP-Extras/data/speeddemonrb/vehicles.meta @@ -15,7 +15,7 @@ null null - DOMINATOR + str392m LAYOUT_LOW SHERIFF_COVER_OFFSET_INFO EXPLOSION_INFO_DEFAULT diff --git a/resources/opticomsystem/OpticomTrafficSystem.net.dll b/resources/opticomsystem/OpticomTrafficSystem.net.dll new file mode 100644 index 000000000..3de7e6999 Binary files /dev/null and b/resources/opticomsystem/OpticomTrafficSystem.net.dll differ diff --git a/resources/opticomsystem/fxmanifest.lua b/resources/opticomsystem/fxmanifest.lua new file mode 100644 index 000000000..65926e8b1 --- /dev/null +++ b/resources/opticomsystem/fxmanifest.lua @@ -0,0 +1,28 @@ +fx_version 'bodacious' +games {'gta5'} + +-- Resource stuff +name 'Opticom Traffic System' +description 'Opticom Traffic Lights Script By ToxicScripts' +version 'v1' +author 'Toxic Scripts' + +-- Adds additional logging, useful when debugging issues. +client_debug_mode 'false' +server_debug_mode 'false' + +-- Leave this set to '0' to prevent compatibility issues +-- and to keep the save files your users. +experimental_features_enabled '0' + +files { + 'settings.ini', +} + +client_scripts { + 'OpticomTrafficSystem.net.dll', +} + +server_scripts { + 'server/server.lua', +} \ No newline at end of file diff --git a/resources/opticomsystem/server/server.lua b/resources/opticomsystem/server/server.lua new file mode 100644 index 000000000..18cdfb463 --- /dev/null +++ b/resources/opticomsystem/server/server.lua @@ -0,0 +1,6 @@ +RegisterServerEvent("Opticom:TriggeredOnCoords") +AddEventHandler("Opticom:TriggeredOnCoords", function(id, coords) + TriggerClientEvent('Opticom:TriggeredOnCoords', -1, id, coords) +end) + +print("OPTICOMSYSTEM ^1Has Authenticated ^2Successfully! ^0By ^1ToxicScripts! ^7") \ No newline at end of file diff --git a/resources/opticomsystem/settings.ini b/resources/opticomsystem/settings.ini new file mode 100644 index 000000000..3082e1ce3 --- /dev/null +++ b/resources/opticomsystem/settings.ini @@ -0,0 +1,46 @@ +{[Info] +//Dont edit these if you dont know what you are doing +//This is the detection delay, meaning the opticom system will check for vehicles every 0.5 seconds +DetectionDelay 500 +//Detection distance from the vehicle +DetectionDistance 100 +//Detection range for the opticom +DetectionRange 60 +//Detection range for other nearby traffic lights +LightDetectionRange 60 +//Make vehicle whitelisted for opticom automatically if it is an emergency vehicle +UseEmergencyWhitelist true +//Reset traffic and traffic lights to their original state after 10 seconds +ResetTrafficAfter 10 +//Freezes the npc traffic when the opticom is triggered on a traffic light +StopTrafficEnabled true +//Detection method 1 is more accurate most of the cases, set this to true for the other method of detection +UseDetectionMethod2 true +} + +//Add custom traffic lights here to have the opticom system installed on them +{[TrafficLightModels] +prop_traffic_01a +prop_traffic_01b +prop_traffic_01d +prop_traffic_02a +prop_traffic_02b +prop_traffic_03a +prop_traffic_03b +} + +//Add vehicles to the opticom whitelist (Emergency Class Vehicles already included) +{[Vehicles] +blista + + + + + + +} + +//Add vehicles to the opticom blacklist (You Can blacklist an Emergency Class Vehicle) +{[BlacklistVehicles] +police2 +} \ No newline at end of file diff --git a/server.cfg b/server.cfg index aad2151a6..f8ab22196 100644 --- a/server.cfg +++ b/server.cfg @@ -216,7 +216,7 @@ ensure cd_doorlock ensure firehydrant ensure Halloween ensure scenes-main -ensure +ensure opticomsystem ensure ensure ensure