Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extremely controversial: Block -> BlockType; Item -> ItemType; ItemStack -> Item #342

Closed
Prospector opened this issue Dec 19, 2018 · 15 comments

Comments

@Prospector
Copy link
Contributor

Is this an insane idea? Probably. But it would be consistent with BlockEntityType, ParticleType, EntityType, etc.

you should probably 馃憥 right now

@LemmaEOF
Copy link

The main thing is that there's already a BlockEntity class that necessitates BlockEntityType being called as such. There isn't a necessity for blocks or items.

@Prospector
Copy link
Contributor Author

ItemStack tho

@LemmaEOF
Copy link

LemmaEOF commented Dec 19, 2018

Then that would require Item -> ItemStackType and that would just be hell. Plus, there's already official Mojang established names for Block and Item, but not BlockEntity and the like.

@2xsaiko
Copy link
Contributor

2xsaiko commented Dec 19, 2018

I was going to suggest this at some point, actually. Exactly the same renames. So I'm all for it :D

@Daomephsta
Copy link

I'm all for this. The new name better communicates that the classes are flyweights, which is a common pitfall for new modders.

@3TUSK
Copy link
Contributor

3TUSK commented Dec 19, 2018

For reference, Sponge API uses BlockType1 and ItemType2 for the same concept.

@liach
Copy link
Contributor

liach commented Dec 19, 2018

sponge api does have many nice names, e.g. text instead of component

@falkreon
Copy link

Not completely opposed.

"Type" is a loaded word, and that flyweight sense that we're trying to communicate might not come across. What about BlockKind/ItemKind?

I think we should keep ItemStack though.

@liach
Copy link
Contributor

liach commented Dec 19, 2018

Or Block/ItemRegistryEntry

@2xsaiko
Copy link
Contributor

2xsaiko commented Dec 19, 2018

Nah, it's main job isn't to be a registry entry.

@NikkyAI
Copy link
Contributor

NikkyAI commented Dec 19, 2018

i think type might not be the best choice but kind works well enough

@Ansraer
Copy link
Contributor

Ansraer commented Dec 19, 2018

tbh I am not a huge fan. I can understand where you are coming from, but we always had Block and all modders are used to them. Plus Block type would kind of imply that there is an actual Block too.
I am completely against changing ItemStack btw. That name perfectly describes what an ItemStack is.

@2xsaiko
Copy link
Contributor

2xsaiko commented Dec 19, 2018

"all modders are used to them" is not a good reason. There's a lot of names that were changed from the well known ones despite that in Yarn mappings, eg. BlockEntity

@Prospector
Copy link
Contributor Author

I think it's a thoroughly shit idea but "modders are used to them" is the worst argument you could've pulled out because that does not matter

@Prospector
Copy link
Contributor Author

With a vote ratio of 3:1 I will close this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants