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

A prototype that makes Nature's Compass worse :D #63

Open
wants to merge 6 commits into
base: forge-1.12.2
Choose a base branch
from

Conversation

variousauthors
Copy link

Hey hey, I modded your mod for a private modpack and I thought you might appreciate it. If you like this idea, then consider this a prototype and I will make it into a config option for you. If you do not like it, then close this PR and think of it as a friendly joke ;)

Motivation:

My buddy spent like 6 hours searching for a Mystic Grove. This made me feel a mix of emotions:

  • I wanted him to find the grove, so I felt sad that he couldn't
  • From a game design perspective, wandering for 6 hours with no way to know if you are "getting closer" is terrible
  • I hate the idea of making rare biomes less rare, in some sense the definition of rare is that not everyone who sets out to find the biome will find it
  • I use Nature's Compass during development of the modpack to test things in creative mode, but I don't want to give players a tool that just lets them trivially find rare biomes

All of this combined into my brain to form: Nature's Scanner

Nature's Scanner is modelled after Scanning in Eve Online. You hold the scanner in your hand and choose a biome to search for as normal. Then you dial in a radius to search in, and scan. In short order the scanner tells you whether your desired biome exists in the radius... and that's all. No direction, no distance, no coords.

A casual scanner, like my friend, can then use it to at least validate their search. He can search for Mystic Grove at the max radius (2^13) and at least know that it's out there. He can periodically get a sense of whether he's going in the right direction by scanning again.

For the professional scanner, this device lets you zero in on the biome but requires that you move, and take additional measurements. The journey to find a rare biome will still be long and arduous... but it will terminate in a finite number of steps.

Thanks everyone! Let me know what you think ;)

Comment on lines -47 to -51
RenderUtils.drawConfiguredStringOnHUD(I18n.format("string.naturescompass.coordinates"), 5, 5, 0xFFFFFF, 6);
RenderUtils.drawConfiguredStringOnHUD(compass.getFoundBiomeX(stack) + ", " + compass.getFoundBiomeZ(stack), 5, 5, 0xAAAAAA, 7);

RenderUtils.drawConfiguredStringOnHUD(I18n.format("string.naturescompass.distance"), 5, 5, 0xFFFFFF, 9);
RenderUtils.drawConfiguredStringOnHUD(String.valueOf(BiomeUtils.getDistanceToBiome(player, compass.getFoundBiomeX(stack), compass.getFoundBiomeZ(stack))), 5, 5, 0xAAAAAA, 10);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No no no, too helpful!

Comment on lines 97 to 102
sortingCategory = sortingCategory.next();
sortByButton.displayString = I18n.format("string.naturescompass.sortBy") + ": " + sortingCategory.getLocalizedName();
selectionList.refreshList();
} else if (button == searchRadiusButton) {
searchRadius = searchRadius.next();
searchRadiusButton.displayString = I18n.format("string.naturescompass.searchRadius") + ": " + searchRadius.getLocalizedName();
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I loved this next interface. Much nicer than inline maths.

Comment on lines 107 to 110
((ItemNaturesCompass) stack.getItem()).setFound(stack, x, z, samples, player);
((ItemNaturesCompass) stack.getItem()).setFound(stack, x, z, samples, maxDistance, player);
} else {
NaturesCompass.logger.info("Search failed: " + getRadius() + " radius, " + samples + " samples");
((ItemNaturesCompass) stack.getItem()).setNotFound(stack, player, getRadius(), samples);
((ItemNaturesCompass) stack.getItem()).setNotFound(stack, player, maxDistance, samples);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than reporting the actual distance searched (since you could use that to triangulate) we just parrot back the requested radius.

@@ -0,0 +1,26 @@
package com.chaosthedude.naturescompass.util;

public class SearchRadius {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought it would be cute to use powers of 2

If the radius of the search is really big, it is not fun to have to
guess which direction to go. So the Compass will tell you a cardinal
direction and give you a milestone about half-way.

Other changes to language are included
@Macleykun
Copy link
Contributor

@MattCzyr do you plan to merge this at some point? Or is this more like a troll pull?

@variousauthors
Copy link
Author

Go ahead and close it. It's not a troll, we use this on our server instead of the vanilla nature's compass, but if there's no interest in it then it's just clutter. Thanks!

@variousauthors
Copy link
Author

Oh yeah I added the hint thing. It's cool, when the biome you seek is really far out the compass says "the biome you seek is to the north, past the mountains" or something like that. It samples the biome half way and adds that as a clue.

@variousauthors
Copy link
Author

Oh and I changed the compass to point north all the time :D it's been a while since I touched this.

@Macleykun
Copy link
Contributor

Sounds interesting, but wouldn't it be wiser to have this optional perhaps?
I don't want to speak on behalf of @MattCzyr . But i assume some people would love this, and some would prefer the old style :P.

Knowing more what this does, i think it's a good PR and should be considered to be merged!

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

Successfully merging this pull request may close these issues.

2 participants