OtherDrops

226k Downloads

loc-offset to effect replacementblock

Zarius opened this issue ยท 4 comments

commented

Posted on BukkitDev tickets by Tajin

I think it might be useful if the offset-settings would also have an effect on the coordinates where a block is beeing replaced via "replacementblock"

This would allow to change the surrounding blocks.

Here's a random example:

DIAMOND_BLOCK:
  - tool: AIR
    action: LEFT_CLICK
    dropgroup: cage
    drops:
      - loc-offset: 0/1/0
        replacementblock: IRON_FENCE
      - loc-offset: 0/0/1
        replacementblock: IRON_FENCE
      - loc-offset: -1/0/0
        replacementblock: IRON_FENCE
      - loc-offset: 0/0/-1
        replacementblock: IRON_FENCE
      - loc-offset: 1/0/0
        replacementblock: IRON_FENCE
      - loc-offset: 1/1/0
        replacementblock: IRON_FENCE  
      - loc-offset: -1/1/0
        replacementblock: IRON_FENCE
      - loc-offset: 0/1/-1
        replacementblock: IRON_FENCE
      - loc-offset: 0/1/1
        replacementblock: IRON_FENCE

Punching the diamond_block would spawn a cage around it.

commented

Revisiting this idea and thinking of a config:

  - location.offset: [FACE@DISTANCE: REPLACEMENT, ...]

# eg:
  - location.offset: [UP@1: ironfence, NORTH@1: ironfence, SOUTH@1: ironfence, etc...]
commented

Using '.' in a key name will confuse the Configuration class, since it uses '.' to separate nested key names.

commented

Depends on how you read it :) Might not be correct as such but I've been using msir.not, message.victim, potioneffect.drop, etc without a problem.

commented

Well, the Configuration class does provide a method to change the delimiter, so it's easy to work around at least.