跳到正文

Fightzone

作者:Buckydev

A scriptable mod to control damage and death using a accessible scripting language. Using JEXL and fabric events to allow or deny damage on a scriptable basis.

收藏

截图

介绍

中文介绍正在准备中,下面暂时显示原文。

Fightzone

A JEXL scripting mod to determine how entities take damage. Using a script to match the condition and an action for how to apply.

Configuration

enabled: true # Controls if scripts are evaluated at all.
saveEnabled: false # Controls config file saving. Useful if you want to keep the config pretty
scripts: # A script has 3 parts
  - action: DENY # Must be any of `ALLOW`, `DENY`, `PASS`. Case-sensitive
    name: Player protection # A name to locate quickly
    # Every script element must start with a `!script`. This makes the element a jexl script
    # The YAML formatting style should not matter. Below is a literal block scalar, this is the easiest to use. 
    script: !script |
      target == 'minecraft:player'

  - action: DENY
    name: Wolf protection
    # If an attacker is a player and the target is a wolf, the damage is blocked
    script: !script |
      (attacker != null && attacker == 'minecraft:player' ) && target == 'minecraft:wolf'

Variable List

target

  • Type: string
  • Nullable: false
  • Examples
  • minecraft:player
  • minecraft:wolf
  • othermod:creature

The identifier for the entity taking damage.

amount

  • Type: float
  • Nullable: false
  • Examples:
  • 0.0
  • 1.0
  • 0.5

The amount of damage applying to the entity.

damage_source

  • Type: string
  • Nullable: true
  • Examples:
  • minecraft:arrow
  • minecraft:campfire
  • othermod:magic

The identifier for the damage type being applied.

attacker

  • Type: string
  • Nullable: true
  • Examples:
  • null
  • minecraft:player

The identifier for the attacking entity, is usually null when it’s environmental damage like fire.

event

  • Type: string
  • Nullable: false
  • Examples:
  • death
  • damage

A helper to differentiate between a death or damage event.

常见问题

Fightzone 支持哪些 Minecraft 版本?

Fightzone 支持 Minecraft Java 版 26.2,可用的加载器:Fabric。下载时注意选择和你游戏版本一致的文件。

Fightzone 怎么安装?

先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。运行环境:仅服务端。

评论

登录后评论和评分

Buckydev 的其他作品

查看全部 →