8000 Allow to filter by original block in XML · Issue #567 · PGMDev/PGM · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Allow to filter by original block in XML #567

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
rockymine opened this issue Jul 15, 2020 · 2 comments
Closed

Allow to filter by original block in XML #567

rockymine opened this issue Jul 15, 2020 · 2 comments
Labels
feature New feature or request

Comments

@rockymine
Copy link

Allow to filter by original block in XML

With this issue I propose the addition a new filter that allows for a mapmaker to filter whether a block has been been part of the original map (i.e. was not placed during the match). The filter would allow players to break and place blocks in a region, just like the block filter does. What differentiates this new filter from <apply block="..." .../> is that, if the specified block is part of the original map, the filter would not allow them to be broken.

This would be helpful for woolrooms especially. There may be some other useful applications as well. But this one is the first that came to my mind.

  • Example: You define a filter that allows to break and place oak planks and apply it to the woolroom. If the woolroom is partially built out of oak planks, players will be able to destroy that part of the woolroom. As a mapmaker you usually don't want this to happen.

As consequence you often deny players from placing this block in the woolroom (and allow others instead) or don't allow any changes to the woolroom at all. In some situations this restricts the creative freedom of the mapmaker or messes with the hotbar (Hopefully this makes sense to you).

TL;DR. It would be nice to have a filter that allows players to place a block that is also part of a structure. You should only be allowed to break blocks that were placed by the player, not the originals placed by the mapmaker.

How it would look in XML

<!-- normal filter -->
<any id="edit-region>
    <material>wood:1</material>
    <material>sandstone</material>
</any>
<!-- new apply -->
<apply block-original="edit-region" region="woolrooms" message="You may not interact with the original blocks!"/>
@Pablete1234 Pablete1234 added the feature New feature or request label Jul 18, 2020
@Cazadorian
Copy link
Contributor

This issue was resolved by #1076 and can likely be closed now I think.

@Pablete1234
Copy link
Member

While #1076 is a slightly different implementation, it covers the intended use-case here, where you can define a blocks filter with the blocks you want to match, and later refer to them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Development

No branches or pull requests

3 participants
0