# qbx\_medical

## in qbx\_medical/client/death.lua CTRL + F and look for:

```lua
AddEventHandler('gameEventTriggered', function(event, data)
```

* at the beginning of the event add following:
* ```lua
  if LocalPlayer.state.inDeathmatch == true then return end
  ```
* your event should look like this:

<figure><img src="https://2644204359-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fso4Bz1A5MlataovyRdlF%2Fuploads%2FtbjBoPLbg46SzJwmj2ub%2FScreenshot_1.png?alt=media&#x26;token=13a66cdc-688d-4259-a8c1-7e4eca5a5663" alt=""><figcaption></figcaption></figure>

## in qbx\_medical/client/wounding.lua CTRL + F and look for:

```lua
local level = getWorstInjury()
```

* replace whole thread this:

```lua
local wait = 1000
CreateThread(function()
    while true do
        if not LocalPlayer.state.inDeathmatch then
            if NumInjuries > 0 then
                local level = getWorstInjury()
                SetPedMoveRateOverride(cache.ped, sharedConfig.woundLevels[level].movementRate)
                wait = 5
            else
                wait = 1000
            end
        end

        Wait(wait)
    end
end)
```

## in qbx\_medical/client/wounding.lua CTRL + F and look for:

*line somewhere around 157*

```lua
if enableBleeding then
```

* replace whole thread with this

```lua
CreateThread(function()
    Wait(2500)
    while true do
        Wait(1000)
        if not LocalPlayer.state.inDeathmatch then
            if enableBleeding then
                checkBleeding()
            end
        end
    end
end)
```

## in qbx\_medical/client/damage.lua CTRL + F and look for:

*line somewhere around 223*

```lua
if damageEffectsEnabled then
```

* replace whole thread with this

```lua
CreateThread(function()
    while true do
        if not LocalPlayer.state.inDeathmatch then
            checkForDamage()
            if damageEffectsEnabled then
                ApplyDamageEffects()
            end
        end
        Wait(100)
    end
end)
```
