-
-
Notifications
You must be signed in to change notification settings - Fork 299
Nopo I Neeeed Thissss (Vanquisher Waypoint Share Feature and Config file) #5197
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
base: beta
Are you sure you want to change the base?
Conversation
|
I have detected some issues with your pull request: Body issues: Please fix these issues. For the correct format, refer to the pull request template. |
NopoTheGamer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the whole file needs to be formatted (do ctrl alt l in intellij)
| //Share vanquisher spawns | ||
| @Expose | ||
| @ConfigOption(name = "Enabled", desc = "Share your Vanquisher spawns and receive other Vanquisher spawns via Party Chat") | ||
| @ConfigEditorBoolean | ||
| @FeatureToggle | ||
| var enabled: Boolean = true | ||
|
|
||
| //Instant share w/o keybind | ||
| @Expose | ||
| @ConfigOption(name = "Instant Share", desc = "Instantly share your Vanquisher spawns via Party Chat") | ||
| @ConfigEditorBoolean | ||
| var instantShare: Boolean = true | ||
|
|
||
| //Manually share with keybind | ||
| @Expose | ||
| @ConfigOption(name = "Keybind Share", desc = "Manually share your Vanquisher spawns with a keybind") | ||
| @ConfigEditorKeybind(defaultKey = GLFW.GLFW_KEY_Y) | ||
| var keybindSharing: Int = GLFW.GLFW_KEY_Y | ||
|
|
||
| //Read global chat to recognize non-party members' Vanquisher spawns |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove the chat gpt comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thos are my comments ;[
| @Suppress("MaxLineLength") | ||
| private val vanquisherSharedPattern by patternGroup.list( | ||
| "coords", | ||
| "(?<party>§9Party §8> )?(?<playerName>.+)§f: (?<x>[^ ]+): (?<y>[^ ]+): (?<z>[^ ]+): | Vanquisher" | ||
| ) | ||
|
|
||
| private val vanquisherDiedPattern by patternGroup.pattern( | ||
| "died", | ||
| "(?<party>§9Party §8> )?(?<playerName>.*)§f: §rVanquisher dead!", | ||
| ) | ||
| private val vanquisherSpawnedPattern by patternGroup.pattern( | ||
| "spawned", | ||
| ".*§aA §r§cVanquisher §r§ais spawning nearby!" | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove colour codes
| } | ||
|
|
||
| @HandleEvent | ||
| fun onRawEntityJoin(event: EntityEnterWorldEvent<Entity>) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can change Entity to the one you need (armour stand im guessing?)
| if (entity !is LivingEntity) return | ||
| if (entity is RemotePlayer) return |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and then you can remove this
| @HandleEvent(onlyOnIsland = IslandType.CRIMSON_ISLE, receiveCancelled = true) | ||
| fun readChat(event: SkyHanniChatEvent.Allow) { | ||
| if(!isEnabled()) return | ||
| val message = event.message |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use cleanMessage instead
53 Detekt FailuresRules flagged (7): Rule violations
|
57 Detekt FailuresRules flagged (7): Rule violations
|
58 Detekt FailuresRules flagged (7): Rule violations
|
58 Detekt FailuresRules flagged (7): Rule violations
|
31 Detekt FailuresRules flagged (8): Rule violations
|
12 Detekt FailuresRules flagged (3): Rule violations
|
|
|
||
| class VanquisherWaypointShareConfig { | ||
| @Expose | ||
| @ConfigOption(name = "Enabled", desc = "Share your Vanquisher spawns and receive other Vanquisher spawns via Party Chat") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| @ConfigOption(name = "Enabled", desc = "Share your Vanquisher spawns and receive other Vanquisher spawns via Party Chat") | |
| @ConfigOption(name = "Enabled", desc = "Share your Vanquisher spawns and receive other Vanquisher spawns via Party Chat.") |
| var enabled: Boolean = true | ||
|
|
||
| @Expose | ||
| @ConfigOption(name = "Instant Share", desc = "Instantly share your Vanquisher spawns via Party Chat") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| @ConfigOption(name = "Instant Share", desc = "Instantly share your Vanquisher spawns via Party Chat") | |
| @ConfigOption(name = "Instant Share", desc = "Instantly share your Vanquisher spawns via Party Chat.") |
| var instantShare: Boolean = true | ||
|
|
||
| @Expose | ||
| @ConfigOption(name = "Keybind Share", desc = "Manually share your Vanquisher spawns with a keybind") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| @ConfigOption(name = "Keybind Share", desc = "Manually share your Vanquisher spawns with a keybind") | |
| @ConfigOption(name = "Keybind Share", desc = "Manually share your Vanquisher spawns with a keybind.") |
| var keybindSharing: Int = GLFW.GLFW_KEY_Y | ||
|
|
||
| @Expose | ||
| @ConfigOption(name = "Read Global Chat", desc = "Register Vanquisher spawns from All Chat and Party Chat") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| @ConfigOption(name = "Read Global Chat", desc = "Register Vanquisher spawns from All Chat and Party Chat") | |
| @ConfigOption(name = "Read Global Chat", desc = "Register Vanquisher spawns from All Chat and Party Chat.") |
| ) | ||
|
|
||
| /** | ||
| * REGEX-TEST: .*A Vanquisher is spawning nearby! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont think the message on hypixel has a .* infront
|
|
||
|
|
||
| /** | ||
| * REGEX-TEST: §9Party §8> User Name§f: x: 2.3, y: 4.5, z: -6.7 | Vanquisher |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
regex tests are meant to test real messages, not messages made to fit the regex
|
|
||
| TitleManager.sendTitle( | ||
| "§5§lVanquisher Spawned!", | ||
| "§r§7You found one nearby!", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the reset does nothing
| for (waypoint in waypoints.values) { | ||
| if (waypoint.spawnTime.passedSince() > 30.seconds) continue | ||
|
|
||
| val beaconColor = java.awt.Color(160, 37, 191) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should just be Color(..)
| val y = location.y.toInt() | ||
| val z = location.z.toInt() | ||
|
|
||
| HypixelCommands.partyChat("x: $x, y: $y, z: $z | Vanquisher") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this check if you are a party
@NopoTheGamer pls help