Giter VIP home page Giter VIP logo

discord-integration's Introduction

Two hard problems

Hi there! 👋 I'm a high school student in Kraków, Poland. I spend my free time making things. The things include mostly programming projects, but I'm also interested in electronics and 3d printing. Check out a list of some of the things that I made or contributed to:

Timetable logo

This is a school timetable app - it can load and parse VULCAN Optivum timetables (using another project of mine) or load data from an API for V High School in Kraków timetable.

Technologies and features:

  • Fully responsive and mobile first - works great on mobile and on desktop
  • Very customizable - users can select their groups, hide lessons they don't attend, choose favourite classes change the color scheme and more
  • Has a built-in classroom map for the V High School.
  • Has a combined view, where a user can see the timetables of all the classes at once
  • Build using Vue 3 and Quasar
  • Progressive Web App (PWA)
  • Caching - timetable data is stored locally so the app works even when offline and loads almost instantly

📱 Wulkanowy - [Source]

Wulkanowy logo

A mobile app, with over 1 million downloads on Google Play for accessing VULCAN Uonet+ school registers. This is quite a big project with over 20 contributors.

I've also worked on related projects, like the timetable parser mentioned before, a Discord bot for the Wulkanowy community and the project's website.

Discord Integration logo

A plugin for Spigot servers that allows to sync messages in a Discord server and Minecraft chat.

Very customizable, has almost 3000 downloads. Check the listing on Spigot Hub for a list of features.

Written in Kotlin, uses Discord4j, makes use of Kotlin coroutines.

💻 Face Shield - [Source]

Face Shield logo

Desktop app that detects when you touch your face, using a webcam or a Xbox Kinect. When you do that, it plays a sound and shows an alert on the screen.

Used technologies: Electron, Vue.js, Vuetify, TensorFlow.js.

This app was made as a submission for the Hack Heroes programming contest, where it won 🥇 first place.

🌐 Boardflow - [Source]

Boardflow logo

A collaborative web app, where students can add upcoming lessons, homework, tests and quizzes to a shared calendar. Created due to the ineffectiveness of school organization during the lockdowns caused by COVID-19.

Technologies and features:

  • Made in Vue.js and Vuetify
  • Uses Firebase Firestore as a real-time database
  • Uses Firebase Auth for signing in with Google or Facebook accounts
  • Has 🇵🇱 Polish and 🇬🇧 English translations

No Liblink logo

A browser extension which automatically replaces annoying liblink.pl links with the URL they are redirecting to in the Librus Synergia school register.

Published in Chrome Web Store

A web app for creating resources to teach programming. Teachers can create materials and exercises, written in markdown. Students can send back their solutions to the exercises, which are then graded by a teacher.

Technologies and features:

  • Made in Vue.js and Vuetify
  • Uses Firebase Firestore as a real-time database
  • Uses Firebase Auth for signing in with Google or Facebook accounts
  • Uses Firebase Cloud Messaging for push notifications

An app for realtime bidding, useful for tabletop games like Monopoly. Supports three types of auctions:

  • English - classic auction type. Players place their bids and see the bids of others in real time
  • Dutch - the price gets lower as time passes, until someone accepts the current price.
  • Sealed-bid - players bid once, without seeing the offers of other bidders. The player who bids the highest price wins.

Uses Vue.js, Vuetify and a custom Socket.IO backend.

A web app that counts down to midnight, January 1st. That's it!

discord-integration's People

Contributors

dominik-korsa avatar xrebellion avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

discord-integration's Issues

Add server console sync

Specify a text channel to display server logs and to execute server commands

The plugin could verify that the @everyone role doesn't have message sending access

Webhooks able to mention @everyone or @here.

Even with every permission for roles and channels not allowing mentions, the MC to Discord chat (which uses webhooks) is able to mention @everyone or @here. And since server owners can't disable mentions in webhooks, there'll have to be some function to remove mentions from messages when they're sent to Discord.

Plugin API

Create an API for the plugin. It should allow other plugins to send chat messages to Discord, intended for use with custom chat plugins

Lack of all functionality.

After installing the plugin, I encountered a connection error, I set everything up correctly. I'll provide a screenshot below.
And also, the main theme of this request is that if I enter messages in a ds chat, then it is not displayed on the server.

https://prnt.sc/Lhx_CF_M8pBK

NullPointerException when requesting UUID fails (cracked player)

Hello, there seems to be an issue with the UUID handling for cracked players for getting player heads.
It seems like now when the requested nickname is not found, the mojang auth server returns basically nothing, but it is not handled within the plugin. The error appears everytime a cracked player sends a chat.
The error says like so:

[20:01:39 WARN]: java.lang.NullPointerException: Cannot invoke "com.dominikkorsa.discordintegration.response.NameToUUIDResponse.getId()" because "responseData" is null
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.AvatarService.updateNicknameUUID(AvatarService.kt:23)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.AvatarService.access$updateNicknameUUID(AvatarService.kt:12)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.AvatarService$updateNicknameUUID$1.invokeSuspend(AvatarService.kt)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:191)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:147)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:93)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:191)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:147)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:93)
[20:01:39 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:191)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:147)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:93)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.resumeRootWith(SuspendFunctionGun.kt:191)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.loop(SuspendFunctionGun.kt:147)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun.access$loop(SuspendFunctionGun.kt:15)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//io.ktor.util.pipeline.SuspendFunctionGun$continuation$1.resumeWith(SuspendFunctionGun.kt:93)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTaskKt.resume(DispatchedTask.kt:235)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTaskKt.resumeUnconfined(DispatchedTask.kt:191)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTaskKt.dispatch(DispatchedTask.kt:162)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.dispatchResume(CancellableContinuationImpl.kt:406)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.resumeImpl(CancellableContinuationImpl.kt:440)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.resumeImpl$default(CancellableContinuationImpl.kt:429)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.resumeWith(CancellableContinuationImpl.kt:337)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.ResumeAwaitOnCompletion.invoke(JobSupport.kt:1439)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.notifyCompletion(JobSupport.kt:1544)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.completeStateFinalization(JobSupport.kt:326)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.finalizeFinishingState(JobSupport.kt:241)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.tryMakeCompletingSlowPath(JobSupport.kt:925)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.tryMakeCompleting(JobSupport.kt:878)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.JobSupport.makeCompletingOnce$kotlinx_coroutines_core(JobSupport.kt:843)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.AbstractCoroutine.resumeWith(AbstractCoroutine.kt:104)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:46)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
[20:01:40 WARN]:        at discord-integration-2.4.0.jar//kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

Handle channels and webhooks set by users as strings instead of string lists and the null default value

While the config.yml in resources.yml looks like this:

chat:
  channels:
  # - 0123456789
  # - 01248163264128256
  webhooks:
  # - https://discord.com/api/webhooks/...

The one generated by Boosted YAML is actually (notice the null):

chat:
 channels: null
 # - 0123456789
 # - 01248163264128256
 webhooks: null
 # - https://discord.com/api/webhooks/...

Users often incorrectly place the string values in place of null, like this:

chat:
  channels: 43219876

  webhooks: discord.com/api/webhooks/...

[Bug] Status Showing as Idle

Sometimes the status of my bot, using this plugin, shows as Idle. It didn't used to do this in the previous version. This a minor bug but nonetheless I wanted to bring it to your attention.

[Future Request] Account Mapping

Issue

Running the command, /di claim, in Minecraft would generate a code, in Minecraft, which could be used in discord for a brief period, linking a Minecraft account to a Discord account.

This link could be optionally required <- needs more thought.

Use Cases

  • A look-up table for potential future features.
    • You could expose the lookup as an end point for other developers to add onto this plugin with modularity. You would not have to support all the features in one repo. Each future being its own plugin. Meaning new features are less likely to break existing features.
  • #9

Prefixes error

image
some of groups have a prefix, the messages delivery to the Discord it's really not readable, any solutions?

Server stuck when stoping server sometimes

When I stoping server, it stuck my server sometimes.
Windows 10 home 64x
PaperMC-1.17.1-279
JDK-16.0.2.7-hotspot

server log just stuck at:
[06:59:41] [Server thread/INFO]: [DiscordIntegration] Disabling DiscordIntegration v2.1.0
(No more log after it and no error log before it.)

[Minor Bug] Multiple Emojis with the Same Name Causes Error

This is a minor bug so I could completely understand if you do not plan on fixing this. However, I did want to bring it to your attention. (I promise it is not an intended feature this time lol)

On Discord it is possible to have multiple emojis with the same name on your server. When using this bot on a server that has multiple emojis with the same name, the bot does not function. Furthermore it is not apparently obvious why it doesn't work which may lead to someone thinking the plugin just doesn't work at all.

[01:03:50 WARN]: java.lang.IllegalArgumentException: Multiple entries with same key: true=<:true:904892144023613480> and true=<:true:906345919666094140> [01:03:50 WARN]: at com.google.common.collect.ImmutableMap.conflictException(ImmutableMap.java:376) [01:03:50 WARN]: at com.google.common.collect.ImmutableMap.checkNoConflict(ImmutableMap.java:370) [01:03:50 WARN]: at com.google.common.collect.RegularImmutableMap.checkNoConflictInKeyBucket(RegularImmutableMap.java:153) [01:03:50 WARN]: at com.google.common.collect.RegularImmutableMap.fromEntryArray(RegularImmutableMap.java:115) [01:03:50 WARN]: at com.google.common.collect.ImmutableMap$Builder.buildOrThrow(ImmutableMap.java:574) [01:03:50 WARN]: at com.google.common.collect.ImmutableMap$Builder.build(ImmutableMap.java:538) [01:03:50 WARN]: at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.Client.mapEmojis(Client.kt:65) [01:03:50 WARN]: at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.Client.initEmojis(Client.kt:57) [01:03:50 WARN]: at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.Client.access$initEmojis(Client.kt:31) [01:03:50 WARN]: at discord-integration-2.4.0.jar//com.dominikkorsa.discordintegration.Client$initEmojis$1.invokeSuspend(Client.kt) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106) [01:03:50 WARN]: at discord-integration-2.4.0.jar//com.github.shynixn.mccoroutine.dispatcher.AsyncCoroutineDispatcher.dispatch(AsyncCoroutineDispatcher.kt:28) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.DispatchedTaskKt.dispatch(DispatchedTask.kt:160) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.dispatchResume(CancellableContinuationImpl.kt:406) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.CancellableContinuationImpl.completeResume(CancellableContinuationImpl.kt:522) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.channels.AbstractChannel$ReceiveHasNext.completeResumeReceive(AbstractChannel.kt:977) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.channels.AbstractSendChannel.offerInternal(AbstractChannel.kt:56) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.channels.LinkedListChannel.offerInternal(LinkedListChannel.kt:29) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.channels.AbstractSendChannel.trySend-JP2dKIU(AbstractChannel.kt:155) [01:03:50 WARN]: at discord-integration-2.4.0.jar//kotlinx.coroutines.reactive.SubscriptionChannel.onNext(Channel.kt:114) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.StrictSubscriber.onNext(StrictSubscriber.java:89) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.FluxSwitchIfEmpty$SwitchIfEmptySubscriber.onNext(FluxSwitchIfEmpty.java:74) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.FluxMap$MapSubscriber.onNext(FluxMap.java:120) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.FluxMap$MapSubscriber.onNext(FluxMap.java:120) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.FluxFlatMap$FlatMapMain.tryEmit(FluxFlatMap.java:543) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.FluxFlatMap$FlatMapInner.onNext(FluxFlatMap.java:984) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.publisher.MonoPublishOn$PublishOnSubscriber.run(MonoPublishOn.java:181) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:68) [01:03:50 WARN]: at discord-integration-2.4.0.jar//reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:28) [01:03:50 WARN]: at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) [01:03:50 WARN]: at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [01:03:50 WARN]: at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [01:03:50 WARN]: at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [01:03:50 WARN]: at java.base/java.lang.Thread.run(Thread.java:833)

[Bug] Erroneous Color Code Symbol

When a message is sent to Discord it will show the color code used by my chat manager. Perhaps you could exclude "§" and the proceeding character from showing?
image

[Suggestion] Block Users and/or Disable Discord Chat

I have encountered a situation where a user was seeing messages from someone they didn't want to see through this integration. A useful safety feature would be allowing a user to disable their view of the Discord messages and/or block certain Discord users from being shown to them.

[Suggestion] Ping Users from In-game by Clicking on a Recent Message

I noticed that you can hover over someone's Discord message in game to see some additional details. However it would be useful if you could take this one step further and click on the person's name and have their id pasted into the chat so you could mention them. Example: Clicking on someone's Discord message in game puts <@!121448959272157184> in the chat.

Fix incompatibility with custom chat plugins

Plugins that cancel the AsyncPlayerChatEvent cause the plugin to not send messages to Discord. There are a few things that could be added to resolve this issue:

  • Create a wiki article explaining this issue
  • Implement #47
  • Implement handlers for custom events of other plugins
  • (added in ec5a739) Add config to log cancelled chat events, for example using a debug.log-cancelled-chat-events field with options:
    • disable - Don't log cancelled events
    • auto - Log cancelled events until there is an event that is not cancelled or supported chat plugin is detected
    • all - Log all cancelled events
      The warnings should point to the new wiki article
  • Add config to increase priority of chat event handler
  • (added in ec5a739) Add config to handle cancelled chat events
  • Add chat plugin chart in bStats

Related: #46

If you are creating a custom chat plugin please reach out to me on the plugin's Discord server

Cannot change nickname of user

I get the following error even though I have the Bot's role on top and it has permissions for everything.

15.08 16:06:41 [Server] Server thread/WARN [Discord Integration 3.3.0] Cannot change nickname of user @Xxxxxx#1234 to XXXXXXX, reason:
15.08 16:06:41 [Server] INFO PATCH /guilds/1007767736711135242/members/258325304110612480 returned 403 Forbidden with response {code=50013, message=Missing Permissions}
15.08 16:06:41 [Server] Server thread/WARN [Discord Integration 3.3.0] Make sure to put the bot's role on the top of the role list

Expand the guide more

I followed the guide and I can get Minecraft messages in discord but discord messages don't go in mc chat and death messages dont go into discord chat. Join messages also don't appear. I cant figure what I need to change from the default config to get it to work

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.