sandstone-mc / sandstone

Sandstone | Next Generation Framework for Minecraft
https://sandstone.dev/
MIT License
172 stars 16 forks source link

Allow Resources & `/variables` utilities in every argument where it makes sense #172

Open GrantGryczan opened 2 years ago

GrantGryczan commented 2 years ago

Like how execute.run accepts the parameters of MCFunction. It would make checks with predicates that are only ever used once much less verbose.

I am iffy on this suggestion though, because there are a lot of commands that could receive the same treatment but don't (for example, the item command could allow the creation of ItemModifiers via its parameters too), and I'm not confident this is a good design pattern for anything beyond functions. More opinions (or deeper consideration) would be needed.

MulverineX commented 1 year ago

All places where a Resource or /variables utility can be turned into a simple value it should be supported, because Sandstone is supposed to be a rolling abstraction precompiler where you can choose the amount of features you want to use. This will be done alongside other missing support in a future release.