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

Add HeightMap datastructure to avoid returning vectors #43

Merged
merged 6 commits into from
Jul 15, 2024

Conversation

rozukke
Copy link
Owner

@rozukke rozukke commented Jun 18, 2024

Equivalent of #31 for getHeights.

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Cpp-linter Review

Click here for the full clang-format patch
diff --git a/include/mcpp/util.h b/include/mcpp/util.h
index b2ee486..e4c9130 100644
--- a/include/mcpp/util.h
+++ b/include/mcpp/util.h
@@ -35 +35,2 @@ class Coordinate {
- * Represents a 2D area of the world with the y coordinates of the highest non-air blocks at each (x,z)
+ * Represents a 2D area of the world with the y coordinates of the highest
+ * non-air blocks at each (x,z)
@@ -38 +39,2 @@ struct HeightMap {
-    HeightMap(const Coordinate& loc1, const Coordinate& loc2, const std::vector<int>& heights);
+    HeightMap(const Coordinate& loc1, const Coordinate& loc2,
+              const std::vector<int>& heights);
@@ -41 +43,2 @@ struct HeightMap {
-     * Get the height using an offset from the origin/base point of the heights area
+     * Get the height using an offset from the origin/base point of the heights
+     * area
@@ -56 +59,2 @@ struct HeightMap {
-     * Fill a coordinate inplace with the highest y coordinate at the `loc`'s x and z components.
+     * Fill a coordinate inplace with the highest y coordinate at the `loc`'s x
+     * and z components.

Have any feedback or feature suggestions? Share it here.

include/mcpp/util.h Outdated Show resolved Hide resolved
include/mcpp/util.h Outdated Show resolved Hide resolved
include/mcpp/util.h Outdated Show resolved Hide resolved
include/mcpp/util.h Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@github-actions github-actions bot dismissed their stale review June 18, 2024 08:29

outdated suggestion

@rozukke rozukke added the enhancement New feature or request label Jun 20, 2024
@rozukke rozukke self-assigned this Jul 15, 2024
@rozukke rozukke merged commit 6ed3d39 into main Jul 15, 2024
2 checks passed
@rozukke rozukke deleted the feature/height-map branch August 29, 2024 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant