NOVA-Team / NOVA-Monorepo

The core API of the NOVA voxel game modding system
https://nova-team.github.io
GNU Lesser General Public License v3.0
66 stars 23 forks source link

Add replace filter to Replaceable. #293

Closed ExE-Boss closed 6 years ago

ExE-Boss commented 7 years ago

This PR makes BlockProperty.Replaceable not a singleton and gives it a filter to only allow replacement with some block types.

codecov-io commented 7 years ago

Codecov Report

Merging #293 into master will increase coverage by 0.46%. The diff coverage is 28.88%.

@@             Coverage Diff              @@
##             master     #293      +/-   ##
============================================
+ Coverage     13.61%   14.07%   +0.46%     
- Complexity      705      710       +5     
============================================
  Files           405      405              
  Lines         12287    12302      +15     
  Branches       1313     1314       +1     
============================================
+ Hits           1673     1732      +59     
+ Misses        10497    10452      -45     
- Partials        117      118       +1
Impacted Files Coverage Δ Complexity Δ
...in/java/nova/core/component/ComponentProvider.java 64.28% <ø> (ø) 3 <0> (ø) :arrow_down:
...forge/v17/wrapper/block/forward/ProxyMaterial.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
...er/mc/forge/v17/wrapper/block/forward/FWBlock.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
src/main/java/nova/core/item/ItemBlock.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
...r/mc/forge/v17/wrapper/block/backward/BWBlock.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
...forge/v18/wrapper/block/forward/ProxyMaterial.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
...er/mc/forge/v18/wrapper/block/forward/FWBlock.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
...r/mc/forge/v18/wrapper/block/backward/BWBlock.java 0% <0%> (ø) 0 <0> (ø) :arrow_down:
.../java/nova/core/block/component/BlockProperty.java 100% <100%> (+100%) 0 <0> (ø) :arrow_down:
src/main/java/nova/core/util/Asset.java 33.33% <0%> (+33.33%) 3% <0%> (+3%) :arrow_up:
... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update ed4eabd...846215e. Read the comment docs.

ExE-Boss commented 6 years ago

Closed in favour of #310.