Contract Settings

The contract configuration file is divided into several sections, each containing a group of settings with common features.

Definition

This part of the config is primarily responsible for the visual representation of the contract.

Parameters:

  • Name - Display name. Can be displayed via a placeholder.
  • Description - Description. Can be displayed via a placeholder.
  • Icon - Icon.
  • Priority - Priority. Used for ordering contracts in the GUI.

See also our Text Formation Guide.

Definition:
  Name: <white><b>Basic</b></white>
  Description:
  - <gray>The most basic contract with no special privileges.</gray>
  - <gray>Available to everyone.</gray>
  - <gray></gray>
  - <gray><white><sprite:"items":"item/clock_12"></white> <yellow><b>Working Hours:</b></yellow></gray>
  - '<gray><dark_gray> » </dark_gray>Mon-Fri: <white>10 AM</white> - <white>10 PM</white></gray>'
  - '<gray><dark_gray> » </dark_gray>Sat-Sun: <white>12 PM</white> - <white>8 PM</white></gray>'
  - <gray></gray>
  - <gray>Work done outside of working hours <soft_red><b>IS NOT PAID</b></soft_red>!</gray>
  - <gray></gray>
  - <gray><white><sprite:"items":"item/arrow"></white> <green><b>Objective Bonuses:</b></green></gray>
  - '<gray><dark_gray> » </dark_gray>XP: <green>+1%</green> per job level</gray>'
  - '<gray><dark_gray> » </dark_gray>Earnings: <green>+1%</green> per job level</gray>'
  - <gray></gray>
  - <gray><white><sprite:"items":"item/experience_bottle"></white> <blue><b>Promotion:</b></blue></gray>
  - <gray>Earn <blue>2,500 Contract Points</blue></gray>
  - <gray>within <white>14 days</white> to receive a promotion</gray>
  - <gray>and additional rewards.</gray>
  - <gray></gray>
  - <gray>In case of failure, a promotion retry</gray>
  - <gray>will be available in no less than <soft_red>3 days</soft_red>.</gray>
  Icon:
    Material: minecraft:coal
    Lore: []
  Priority: 0

Unlocking

This part is responsible for "unlocking" and "activating" the contract.

Parameters:

  • Permission-Required - Whether a permission is required to activate the contract.
  • Cost - Contract activation cost.
  • Conditions - Conditions for contract activation.
Unlocking:
  Permission-Required: false
  Cost:
    Enabled: false
  Conditions:
    Enabled: false

Cost

Parameters:

  • Enabled - If enabled, checks and charges the cost from the player.
  • List - Activation cost in the format "currency" - "cost". List of available currencies.
Cost:
  Enabled: true
  List:
    vault: 5000.0
    coins: 50.0

Conditions

Parameters:

  • Enabled - If enabled, checks if the player meets the specified conditions.
  • List - List of conditions with individual parameters.
Conditions:
  Enabled: false
  List: {}

The following conditions are supported by default:

Active Contracts

The player must have no more/less than the specified active contracts (in any jobs).

Example

The player must have no more than 3 basic contracts and at least 1 advanced contract.

List:
  active_contracts:
    basic: 0-3
    advanced: 1

Job Level

The player's job level must be within the specified limits.

Example #1

Player's job level: up to 24 inclusive.

List:
  job_level: 0-24

Example #2

Player's job level: from 25 inclusive.

List:
  job_level: 25

Behavior

This part is responsible for the "behavior" of the contract.

Parameters:

  • Leave-Cooldown - Contract cancellation cooldown time. The player will not be able to cancel the contract or leave the job with it until this period expires. Format like 1w 2d 3h 4m 5s.
  • Timeframe - Working hours by days of the week in 24-hour format. Use the TimeframePenalty modifier (see below).
  • Objective-Property-Modifiers - Modifiers for objective properties.
Behavior:
  Leave-Cooldown: 3d
  Timeframe:
    Days:
      MONDAY: 10:00-22:00
      TUESDAY: 10:00-22:00
      WEDNESDAY: 10:00-22:00
      FRIDAY: 10:00-22:00
      SUNDAY: 12:00-20:00
      THURSDAY: 10:00-22:00
      SATURDAY: 12:00-20:00
  Objective-Property-Modifiers:
    INCOME:
      Base: 1.0
      JobLevelBonus: 0.01
      TimeframePenalty: 1.0
    CONTRACT_POINTS:
      Base: 1.0
      JobLevelBonus: 0.0
      TimeframePenalty: 1.0
    XP:
      Base: 1.0
      JobLevelBonus: 0.01
      TimeframePenalty: 1.0
    PROBABILITY:
      Base: 1.0
      JobLevelBonus: 0.0
      TimeframePenalty: 1.0

Objective Property Modifiers

Parameters:

  • Base - Base multiplier. 1.0 = 100% (no changes), 1.25 = +25%.
  • JobLevelBonus - Job level bonus. Use only the "bare" value, for example, 0.01 = +1% per level.
  • TimeframePenalty - Off-hours "penalty". 0.1 = -90%, 0.9 = -10%.

Promotion

This part is responsible for the "promotion" or "completion" of the contract.

Parameters:

  • Enabled - If enabled, the promotion option will be available to players.
  • Duration - Time limit. Time format like 1w 2d 3h 4m 5s.
  • Cooldown - Time until the next promotion retry if the promotion was cancelled for any reason. Time format like 1w 2d 3h 4m 5s.
  • Goal.Contract-Points - Contract points that must be earned to complete the promotion.
  • Reward-Commands - Commands to execute after successfully completing the promotion.
  • Reward-Messages - Messages to the player after successfully completing the promotion.
Promotion:
  Enabled: true
  Duration:
    Enabled: true
    Value: 2w
  Cooldown:
    Enabled: true
    Value: 3d
  Goal:
    Contract-Points: 2500
  Reward-Commands:
  - money give %player_name% 15000
  - lp user %player_name% permission set excellentjobs.contracts.contract.advanced.%job_id% true
  Reward-Messages:
  - <gray>You have unlocked <green>Advanced</green> contract for your <white>%job_name%</white> job!</gray>