Toggle Night Vision

Power Type

Defines a Night Vision (Power Type) which can be toggled on and off with the specified Key.

Type ID: origins:toggle_night_vision

Fields

Field Type Default Description
active_by_default Boolean true Whether this power starts in the on or off state.
strength Float 1.0 How strong the night vision effect is. Range: 0.0 - 1.0.
key Key optional Which active key this power should respond to. If none is specified, this power will use the primary active power key (by default G).

Examples

{
    "type": "origins:toggle_night_vision",
    "strength": 0.5,
    "condition": {
        "type": "origins:submerged_in",
        "fluid": "minecraft:water"
    }
}

This example will give the player night vision while underwater, improving their vision by quite a bit that can be turned on and off by pressing the Primary ability key.