From 8e96543c582c2365dbf182597af2f3a038e89dc8 Mon Sep 17 00:00:00 2001 From: iseeyoucopy <2729972+iseeyoucopy@users.noreply.github.com> Date: Sun, 7 Jul 2024 10:05:18 +0100 Subject: [PATCH] Small update (#117) * small update added configurable option for max distance between horse and player, the horse will be sent automatically * Update fxmanifest.lua - version bump * Update package.json - version bump * Update version - version bump --------- Co-authored-by: Apollyon <37031311+JusCampin@users.noreply.github.com> --- client/main.lua | 3 +-- config/main.lua | 4 ++++ fxmanifest.lua | 2 +- ui/package.json | 2 +- version | 4 ++-- 5 files changed, 9 insertions(+), 6 deletions(-) diff --git a/client/main.lua b/client/main.lua index d22c861..f83c408 100644 --- a/client/main.lua +++ b/client/main.lua @@ -609,11 +609,10 @@ AddEventHandler('bcc-stables:HorsePrompts', function() while MyHorse do local playerPed = PlayerPedId() local sleep = 1000 - local maxDistance = 50.0 -- Set a maximum distance for the horse to be sent away local distance = #(GetEntityCoords(playerPed) - GetEntityCoords(MyHorse)) -- Check if the player is getting away from the horse - if distance > maxDistance then + if distance > Config.maxDistanceFlee then Wait(500) FleeHorse() Wait(500) diff --git a/config/main.lua b/config/main.lua index cc89dc4..2cc825c 100644 --- a/config/main.lua +++ b/config/main.lua @@ -59,6 +59,10 @@ Config.maxPlayerHorses = 5 -- Default: 5 Config.maxTrainerHorses = 10 -- Default: 10 ----------------------------------------------------- +--Max distance between player and horse, if he move away from horse, it will send automatically +Config.maxDistanceFlee = 150 +----------------------------------------------------- + -- Can Spawn Horse Anywhere with Whistle Config.whistleSpawn = true -- Default:true / Set to false to only Use 'Call Horse' Button at Stable to Spawn Horse ----------------------------------------------------- diff --git a/fxmanifest.lua b/fxmanifest.lua index 4818927..1d69e21 100644 --- a/fxmanifest.lua +++ b/fxmanifest.lua @@ -34,5 +34,5 @@ files { "ui/img/*.*" } -version '1.4.12' +version '1.4.13' diff --git a/ui/package.json b/ui/package.json index 58788a6..3855721 100644 --- a/ui/package.json +++ b/ui/package.json @@ -1,7 +1,7 @@ { "name": "bcc-stables", - "version": "1.4.12", + "version": "1.4.13", "private": true, "scripts": { diff --git a/version b/version index a508dde..d459689 100644 --- a/version +++ b/version @@ -1,2 +1,2 @@ -<1.4.12> -Update horse looting. +<1.4.13> +See GitHub for details!