[Release] Original Police K9 [Updated]

GREAT RELEASE! I love this script only 1 question, how do I change the notifications I only found them in 1 file changed them all but still it shows me the notifications in german?

Thanks in advance, kind regards.

Is good to have the GPS for k9? Show the label of items when the search player or vehicle.

I will add those to config

Iā€™ll add a config option to list the items. I have it so it doesnā€™t because dogs donā€™t know whatā€™s in the car. Also it gives the cops more rp so they have to search the vehicle.

1 Like

Thanks in advance, love the way this script work keep up the good work!

Tested this on my server, but the K9 wont spawn, when i just do /k9 spawn it tells me to try the one of the four diffrent breeds, but when i do nothing spawns, any idea why? the scipt seems like a great addon to the police job (SOLVED)

if anyone wants to add to esx_policejob menu

   if PlayerData.job.grade_name == 'k9' then
    table.insert(elements, {label = 'K9 Interaction', value = 'k9_interaction'})
  end


    if data.current.value == 'k9_interaction' then
      local elements = {
        {label = 'Spawn K9', value = 'k9spawn'},
        {label = 'K9 Follow', value = 'k9follow'},
        {label = 'K9 Stay', value = 'k9stay'},
        {label = 'K9 Search Vehicle', value = 'k9sehveh'},
        {label = 'K9 Search Citizen', value = 'k9sehcit'},
        {label = 'K9 Enter Vehicle', value = 'k9enterveh'},
        {label = 'K9 Exit Vehicle', value = 'k9exitveh'},
        {label = 'K9 Dismiss', value = 'k9delete'}
      }

      ESX.UI.Menu.Open('default', GetCurrentResourceName(), 'k9_interaction', {
        title    = 'K9 Actions',
        align    = 'bottom-right',
        elements = elements
      }, function(data99, menu99)
          local action = data99.current.value

          if action == 'k9spawn' then
              ExecuteCommand('k9 spawn husky')
          elseif action == 'k9follow' then
            ExecuteCommand('k9 follow')
          elseif action == 'k9stay' then
          ExecuteCommand('k9 stay')
        elseif action == 'k9sehveh' then
          ExecuteCommand('k9 search vehicle')
        elseif action == 'k9sehcit' then
            ExecuteCommand('k9 search player')
          elseif action == 'k9enterveh' then
            ExecuteCommand('k9 enter')
          elseif action == 'k9exitveh' then
            ExecuteCommand('k9 exit')
          elseif action == 'k9delete' then
            ExecuteCommand('k9 delete')
          end
      end, function(data99, menu99)
        menu99.close()
      end)
2 Likes

Might not have permission. Check the config for the correct grade_name

Thank you sir, I will link this in the post

Make sure you are adding a job_grades. Should work like this

job_name: "police"
grade: 99
name: "name this what the config states or change it"
label: "K9"
salary: 0 
skin_male: "{}" 
skin_female: "{}"
1 Like

Yeah that was the case, thanks for the help! Would there be any way of translating the script? I tried translating all of the ESX notifications in Canine.cs but it didnt work, iā€™m also not able to change the keybind for the attack action, any idea why?

Well itā€™s C# so it would need to be compiled again. But I will add those to the config shortly.

You can now change the keybinds and translate in version 1.2

Can be really great to get a trunk option for the K9 in police carā€¦ I use a Police Pickup and can be awesome to get the dog in trunk :slight_smile:

can you tell me where is the esx_policejob menu ?i cant find it ā€¦thank you

Im the owner of a decent FX server. Would really appreciate a FX version with Ace perms. K9 is a bid division in our community. TY

There is a standalone version read the latest update.

Itā€™s in the esx policejob, you gotta know how to script to put it in.

You might be able to do this nowā€¦ Although I have met tried. There is an option in the config that allows you to switch which bone of the car the dog is selected to. You would have to lookup gtav bone names but that should work. I am planning to make it easier soon.

ok thanks :slight_smile: i just dont use this script now is the reason :slight_smile: but for sure i try it right now and modify this .
thanks for this great work !