Core-Services
DiscordShop
  • 🏠HOME
  • ⚙️SCRIPTS
    • CS_MENU_DEFAULT
    • CS_VISA
    • CS_SHOPS
    • CS_GARAGE
    • CS_REVIVESTATION
    • CS_PANICBUTTON V2
    • CS_DEATHTIMEOUT V2
    • CS_VEHICLERENTAL
      • Installation
      • Configuration
        • config.lua
        • devConfig.lua
        • framework.lua
        • webhook.lua
      • Exports
Powered by GitBook
On this page
  • Installation
  • Configuration
  • Config.lua
  • Functions
  • Webhook.lua
  • Example Usage
  • Support

Was this helpful?

  1. SCRIPTS

CS_DEATHTIMEOUT V2

A deathtimeout script making users unable to harm other players.

PreviousCS_PANICBUTTON V2NextCS_VEHICLERENTAL

Last updated 14 days ago

Was this helpful?


Installation


Configuration

Config.lua

1. General Settings

  • Locale: Sets the language for the messages. Options are:

    • "EN" for English

    • "DE" for German

2. Commands

Each command defines a specific functionality. Two commands are predefined:

dtstart

  • Starts a deathtimeout for a specified player.


Functions

  • cs_deathtimeout.canStartDeathtimeout(): Set conditions to prevent the deathtimeout from appearing.

  • cs_deathtimeout.BlockedActions(playerid, playerpedid): Edit blocked actions during the deathtimeout

  • NotificationFunction(title, msg, type): The notification function used.

Make sure to change the Notification function to your notify trigger!

Or else the script will not work properly.

Notification Types

Different types of notifications available:

  • NotifyTypes: Defines types like info, error, success, warning.

Locales

Translations for different languages:

  • LocalesDeathtimeout: Contains translations for English (EN) and German (DE).

ESX Version Handling

Determines whether an old or new version of ESX is being used and initializes the shared object accordingly. If you want to, you can of course change the shared object to fit your needs.

Webhook.lua

  • The script offers 3 webhooks.

    • dtstart

    • dtclear

    • dtclearradius

If you do not want a webhook to be sent, just leave the string empty. Like this:

WebhookDt = {

    Colors = {
        ["dtstart"] = 43775,
        ["dtclear"] = 43775,
        ["dtclearradius"] = 43775,
    },

    dtstart = "",

    dtclear = "https://discord.com/api/webhooks/1333765633136918548/8sigg4zjPatDnfT8vKLCyF9fbBzr3VDCJAAdcif69pI3LJprxmDGQXQP14ckv9mjybq6",

    dtclearradius = "https://discord.com/api/webhooks/1333765633136918548/8sigg4zjPatDnfT8vKLCyF9fbBzr3VDCJAAdcif69pI3LJprxmDGQXQP14ckv9mjybq6",
}

In this example, you would not be notified when a player starts a local deathtimeout.


Example Usage


If you have any further questions, open a ticket on our discord server: discord.gg/core-services

⚙️
Get the script
Support