Jump to content

auto kit command

Closed 1.0.28

LizardMods
  • in Kits
LizardMods

Posted (edited)

I am trying to setup 3 autokits that will run commands.

I tested the command with TimedPermissions and GUIShop as a proof of concept.
 

this is the GUIShop example

    "chad": {
      "DisplayName": "chad",
      "CraftAsDisplayName": false,
      "Shortname": "pack 12", // not inportent
      "MakeBlueprint": false,
      "AllowSellOfUsedItems": false,
      "Condition": 0.0,
      "EnableBuy": true,
      "EnableSell": false,
      "Image": "https://i.imgur.com/QlUrCgl.png",
      "SellPrice": 1.0,
      "BuyPrice": 1.0,
      "BuyCooldown": 0,
      "SellCooldown": 0,
      "BuyQuantity": [
	  "1"
	  ],
      "SellQuantity": [],
      "BuyLimit": 0,
      "BuyLimitResetCoolDown": 0,
      "SellLimit": 0,
      "SellLimitResetCoolDown": 0,
      "KitName": "",
      "Command": [
        "addgroup $player.id chad 30d"  // the goods 
      ],
      "RunCommandAndCustomShopItem": false,
      "GeneTypes": [],
      "SkinId": 0
    },

this is what I have set for Kits

{
  "Kits": [
    {
      "Name": "autokit",
      "Display Name": "AutoKit",
      "Color": "#A0A935",
      "Permission": "Kits.default",
      "Description": null,
      "Image": null,
      "Hide": true,
      "Amount": 0,
      "Cooldown": 1.0,
      "Wipe Block": 0.0,
      "Building": null,
      "Enable sale": false,
      "Selling price": 0,
      "Items": [
        {
          "Type": "Item",
          "Command": "",
          "ShortName": "jumpsuit.suit.blue",
          "Amount": 1,
          "Blueprint": 0,
          "SkinID": 2691839789,
          "Container": "wear",
          "Condition": 100.0,
          "Chance": 100,
          "Position": 6,
          "Image": null,
          "Weapon": null,
          "Content": null
        },
        {
          "Type": "Command",
          "Command": "addgroup $player.id chad 30d",
          "ShortName": "chad",
          "Amount": 1,
          "Blueprint": 0,
          "SkinID": 0,
          "Container": "null",
          "Condition": 0.0,
          "Chance": 100,
          "Position": 0,
          "Image": null,
          "Weapon": null,
          "Content": null
        }
      ]
    }
  ]
}

I am assuming that this only works with custom items?
anyways the reason I am trying to do this is so a player will be put in a group when they get an auto kit.

by doing so better chat will give them a tag. the idea would be the first auto kit "44min" would put them into group chad, auto kit 2 "22min" would put them into group Failed, and the 3 auto kit would put them into group NOOB lol.

it is the only reason I bought this plugin because I thought this could bridge the gap.

any help would be appreciated.

Edited by LizardMods
LizardMods

Posted

Realizing that can give command does not equal can run command. Ugggg

Ok can we please make this a thing? it will open up so many possibilities.

Mevent

Posted

On 1/31/2022 at 7:17 AM, LizardMods said:

I am trying to setup 3 autokits that will run commands.

I tested the command with TimedPermissions and GUIShop as a proof of concept.
 

this is the GUIShop example

    "chad": {
      "DisplayName": "chad",
      "CraftAsDisplayName": false,
      "Shortname": "pack 12", // not inportent
      "MakeBlueprint": false,
      "AllowSellOfUsedItems": false,
      "Condition": 0.0,
      "EnableBuy": true,
      "EnableSell": false,
      "Image": "https://i.imgur.com/QlUrCgl.png",
      "SellPrice": 1.0,
      "BuyPrice": 1.0,
      "BuyCooldown": 0,
      "SellCooldown": 0,
      "BuyQuantity": [
	  "1"
	  ],
      "SellQuantity": [],
      "BuyLimit": 0,
      "BuyLimitResetCoolDown": 0,
      "SellLimit": 0,
      "SellLimitResetCoolDown": 0,
      "KitName": "",
      "Command": [
        "addgroup $player.id chad 30d"  // the goods 
      ],
      "RunCommandAndCustomShopItem": false,
      "GeneTypes": [],
      "SkinId": 0
    },

this is what I have set for Kits

{
  "Kits": [
    {
      "Name": "autokit",
      "Display Name": "AutoKit",
      "Color": "#A0A935",
      "Permission": "Kits.default",
      "Description": null,
      "Image": null,
      "Hide": true,
      "Amount": 0,
      "Cooldown": 1.0,
      "Wipe Block": 0.0,
      "Building": null,
      "Enable sale": false,
      "Selling price": 0,
      "Items": [
        {
          "Type": "Item",
          "Command": "",
          "ShortName": "jumpsuit.suit.blue",
          "Amount": 1,
          "Blueprint": 0,
          "SkinID": 2691839789,
          "Container": "wear",
          "Condition": 100.0,
          "Chance": 100,
          "Position": 6,
          "Image": null,
          "Weapon": null,
          "Content": null
        },
        {
          "Type": "Command",
          "Command": "addgroup $player.id chad 30d",
          "ShortName": "chad",
          "Amount": 1,
          "Blueprint": 0,
          "SkinID": 0,
          "Container": "null",
          "Condition": 0.0,
          "Chance": 100,
          "Position": 0,
          "Image": null,
          "Weapon": null,
          "Content": null
        }
      ]
    }
  ]
}

I am assuming that this only works with custom items?
anyways the reason I am trying to do this is so a player will be put in a group when they get an auto kit.

by doing so better chat will give them a tag. the idea would be the first auto kit "44min" would put them into group chad, auto kit 2 "22min" would put them into group Failed, and the 3 auto kit would put them into group NOOB lol.

it is the only reason I bought this plugin because I thought this could bridge the gap.

any help would be appreciated.

 

You need to use %steamid% to specify the player

"Command": "addgroup %steamid% vip 7d",

 

Mevent

Posted

Changed Status from Pending to Closed

LizardMods

Posted

I will try to de-escalate the dispute on PayPal.  Otherwise, I'll resend the payment.

1.4m

Downloads

Total number of downloads.

6.9k

Customers

Total customers served.

103.4k

Files Sold

Total number of files sold.

2.1m

Payments Processed

Total payments processed.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.