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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

is it possible to use an ID for the portal instead of having the frame block be the id? #65

Open
andrewzah opened this issue Nov 14, 2022 · 1 comment

Comments

@andrewzah
Copy link

it would be nice to have multiple portals with the same frame type.

@kyrptonaught
Copy link
Owner

This is technically possible but I chose not to do so, mostly for performance.

When a portal is attempted to be lit, we just grab the block that is making up the new "frame" and check it against a hashmap. This allows the lookup to be fast. This quickness also allows us to avoid using a BE for the portal itself. We can quckly get our "portal link" and determine what color we are supposed to be based on this hashmap lookup. So tinting the block itself, tinting the loading screen, tinting particles, etc. This is also important since we can be checking for a potential portal every time a block is updated, or we interact with a block though right click, place a block, etc.

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

2 participants