Inactive [FUN/MECH] Block Crusher v1.5 - Piston Crush & Compress [1060]

Discussion in 'Inactive/Unsupported Plugins' started by Dingmatt, Jul 7, 2011.

  1. Offline


    Block Crusher - Piston Crush & Compress
    Version: v1.5
    Crushing - When extending pistons will crush blocks between themselves and a block of obsidian; if no obsidian's present then they will push blocks as normal.
    Compressing - Two pistons pushing blocks into the a space blocked by obsidian will cause the blocks to compress into a new block.
    Both Fully Configurable

    Config (open)

    ____- 1|4|1________________#Stone>Cobblestone
    ____- 2|3|1________________#Grass>Dirt
    ____- 3|3|1________________#Dirt>Dirt
    ____- 4|4|1________________#Coblestone>Cobblestone
    ____- 12|12|1______________#Sand>Sand
    ____- 13|13|1______________#Gravel>Gravel
    ____- 24|12|1______________#Sandstone>Sand
    ____- 73|331|4_____________#Redstone Ore>Redstone Dust
    ____- 4|4|4|1______________#Cobblestone+Cobblestone+Cobblestone=Stone
    ____- 12|12|12|24__________#Sand+Sand+Sand=Sandstone
    ____- 0|12|12|24___________#Air+Sand+Sand=Sandstone

    Crusher_Enabled: Enables the crush functionality
    Compressor_Enabled: Enables the compress functionality
    Crush_Blocks: List of crush-able blocks and the type/quantity spawned (Crush|Spawn|Quantity)
    Compress_Blocks: List of compress recipes and block spawned (Ingredient1|Ingredient2|Ingredient3|Spawned)

    The default config is very basic and meant only as a sample, use the each blocks data value (from the minecraft wiki) to customize to your servers needs.

    v1.5 -
    - Too strict redstone event filtering (thx @HotelErotica)
    - Further code optimization and reduced memory consumption
    v1.4 -
    - Incorrectly crushing nearby blocks (thx @lipe123)
    v1.3 -
    - Added a config reload command
    Older Changes (open)

    v1.2 -
    - Indirect power activation (thx @hvergi)
    - Internal timings (thx @HotelErotica)
    - Tweaked code to improve performance
    v1.1 -
    - Compress functionality
    - Crushed quantities
    - Piston 'facing down' (thx @NaturalCauses)
    - Incorrect redstone activation (thx @xenofixus)
    - Config file (older versions of the config won't work)
    v1 - Release
    v0.2 - (beta) Added config to allow custom list of crush-able blocks and which block they spawn
    v0.1 - (alpha) Initial Tests

    Pre v1.1 Upgrade Warning (open)

    The v1 config file won't work with v1.1+, delete it before upgrading else risk crashing your server

    /blockcrusher reload - Reloads the plugins config file
    Latest (v1.5) BlockCrusher.jar
    Old(v1.4) BlockCrusher.jar
    Latest (v1.5)
    If you release a modified version of this mod then please also release the source, credit would also be appreciated.
    @feildmaster for the block facing code
    @krinsdeath for the config file code
    @theguildur for the quantity idea
    and anyone who's helped by submitting bug reports.

    Suggestions and comments welcome. :)
    Enderman55 and someguy817 like this.
  2. You did it! Awesome, just fantastic! I'll be installing this post haste. Hello clay factory!
  3. Offline


    And your more then welcome to add my video on there if you like, I might make a new version tonight though i doubled production with tweaking my timing abit.
  4. Offline


    Cheers all
  5. Offline


  6. Offline


    I found one bug so far. If you have a piston facing down with an obsidian block below it, it will not 'crush' the block between them. All other directions work just fine.


    And now for my overly complicated cobblestone harvester :p

  7. Offline


  8. Offline


    ok then there is 2 that are like this but three in function
  9. Alright, next stage of creation:

    Suggestion 1:
    Allow a crushed item to produce multiples of another item. (configurable)
    IE ~
    Crush sandstone get 4 sand dust.
    Crush cobblestone get 2 gravel.

    Suggestion 2:

    Multi-block recipes for the crusher.

    From a top down perspective, it'd look like one of these configurations:

    Depending on the blocks placed in each of those positions, (The B's), it would create a new block. Under the Obsidian block you could have an 'activator block' that alters what is produced by the combined blocks.

    Possible recipes:
    With nothing:
    Put four sand blocks produces 2 sandstone.
    Put 2 coal ore, 2 wood blocks, get get 2 fire 'blocks'.
    Put 1 sand, 1 wood, 1 cobble, 1 pumpkin ~ Get 1 Lapis Block

    With Lava Under the Block:
    Put a wood block (not planks) in each of the B spots and the X, and it will produce a coal (ore) block.
    Put a coal (ore) in each of the B spots, and the X, and it would produce a diamond block.
    Put 2 cobblestone and 2 coal, get an Iron Ore Block
    Put 2 cobblestone and 2 iron ore, get a Gold Ore Block

    These are just some basic ideas off the top of my head.
  10. Offline


    Quick problem; I have my crusher laid out like this (using a detector)
    R=redstone, _ = empty space, T = repeater, P = piston, O = obsidian


    Even if there is no wiring the block still gets "crushed" even though no power is going to the piston and even though the piston doesn't actually 'fire'/move.

    ninjaedit: this is top down so this takes up 3x3x1
  11. Offline


    There i was hoping there were no bugs lol, I'll sort this tonight.

    I might try something like this tonight but it probably won't be as complicated, I'd like to keep things a simple as possible.

    From what I understand the pistons still being powered but notch must have coded it not to extend in this situation, I'll try to compensate for this tonight.

  12. I've always kind of felt KISS was a generally ridiculous rule when taken to extremes. :) But you're the coder.
  13. Offline


    Its more because I don't want the plugin to cause unexpected results in people piston setups, the idea is to only use setups which no one would normally use (i.e. why would some create a piston pushing against an obsidian block).

    What I'll probably add is a two block setup:
    __P_______P = Piston
    __B_______B = Block
    O B B P___O = Obsidian

    Where the block in bold/italic is compressed into a new type depending on the blocks underlined.
  14. "Its more because I don't want the plugin to cause unexpected results in people piston setups"
    *laughs* with increasing complexity it's unlikely that anyone would mistakenly use it anyway. But like I said, you're the coder. :) Glad you seem to like the ideas.
  15. Offline


    Just to give you all an update, I've fixed all the bug mentioned so far and i'm in the middle of adding the extra functionality.
    Going to have to complete it tomorrow though as i'm tired and need sleep.
  16. Offline


    latest 2 changelog entries need to be outside the spoiler
  17. Offline


    I the idea it was.
    Nice plugin thought
  18. Offline


    Last edited by a moderator: May 17, 2016
  19. Offline


    if you want to look ill give you the source
  20. Offline


    Sounds good, I don't mind trading... You never know what you'll find lol.
  21. Offline



    oh and off topic whats the texture pack you used in the video?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: May 17, 2016
  22. Offline


  23. No chance for Permissions I guess? :p

    btw, from log: [BlockCrusher version: 0.1] - Enabled


    Otherwise, really cool plugin, but as I don't play much myself, I am struggling to see the use, other than a cobble factory with lava+water I suppose?

    I mean, you dig up a stack of sand, then place sandblocks, to turn them back into single sand blocks? What am I missing :D
  24. The ability to personalize it. I'm certain you're able to determine what comes out of the compress.
    Iron Ore + Coal Ore = Red Stone Ore? For example. Or anything your little heart can imagine.

    Can you make the output variable?

    Crush One Smooth Stone:
    100% Chance of Cobblestone
    10% Chance of Redstone Dust
    5% Chance of Iron Ore
    1% Chance of Diamond

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: May 17, 2016
  25. Hah yea of course, but many plugins do that. Am really thinking of something unique with the specialness of pistons :p

    But can only come up with cobble factories really.
  26. There's an insane use for it if you're looking at production facilities.

    Lava dumps, water cools, cobble goes to crusher, becomes gravel, gravel gets pushed into a water stream (using claygen), becomes a clay block, and is pushed into another crusher, becoming clay dust, clay dust is processed into bricks.

    Now we just need one the guy who made the sticky pistons able to pull things in/out of chests make it able to do that with item entities, and we can add another step.

    Dust is pushed into a furnace, becomes bricks, which gets pulled out and stuffed in a chest.
  27. Offline


    Lol yeah, that's one of two bugs I've found since v1.1 (the others just a tweak in behavior).

    Does anyone have any more suggestions for this plugin? As I have an idea for a performance plugin which I'll shift my attention to.
  28. Thanks! I forgot claygen existed, I see it has a farming mode now, makes it a lot more interesting :eek:
  29. Suggestion:
    1. Place a chest on top of the obsidian, and one on top of the piston. It will pull items from the chest on top of the piston, crush it, and place it in the chest on top of the obsidian. (Or beside, or under, or whatever.) For the compressor you put one chest on each piston, and one under the center square (where compression happens). You a chest on one block of obsidian, it will place the results in that chest.
  30. Further Suggestion:
    1. Allow the rock compressor to spit out multiple (and possibly variable #'s of) blocks or item entities. I currently have a recipe for "Coal Ore + Glowstone + Redstone Ore" I'd like to have kick out 4-8 gunpowder, for instance.

Share This Page