Added levels, fixed a few bugs

This commit is contained in:
Savvy 2017-08-11 03:00:11 -04:00
parent f718d28239
commit 1df2460bfa
14 changed files with 438 additions and 216 deletions

View File

@ -2,8 +2,8 @@
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="d884bc5a-63a1-4e03-b68b-617ebe9b8e2a" name="Default" comment=""> <list default="true" id="d884bc5a-63a1-4e03-b68b-617ebe9b8e2a" name="Default" comment="">
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" afterPath="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" /> <change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" afterPath="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" />
</list> </list>
<ignored path="Rixa.iws" /> <ignored path="Rixa.iws" />
<ignored path=".idea/workspace.xml" /> <ignored path=".idea/workspace.xml" />
@ -40,12 +40,22 @@
<favorites_list name="Rixa" /> <favorites_list name="Rixa" />
</component> </component>
<component name="FileEditorManager"> <component name="FileEditorManager">
<leaf> <leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="MusicCommand.java" pinned="false" current-in-tab="true"> <file leaf-file-name="MessageEvent.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/MusicCommand.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MessageEvent.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="518"> <state relative-caret-position="224">
<caret line="206" column="130" lean-forward="false" selection-start-line="206" selection-start-column="130" selection-end-line="206" selection-end-column="130" /> <caret line="60" column="33" lean-forward="true" selection-start-line="60" selection-start-column="33" selection-end-line="60" selection-end-column="33" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="CommandHandler.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandHandler.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="289">
<caret line="28" column="32" lean-forward="false" selection-start-line="28" selection-start-column="32" selection-end-line="28" selection-end-column="32" />
<folding /> <folding />
</state> </state>
</provider> </provider>
@ -75,13 +85,21 @@
<find>The configuration</find> <find>The configuration</find>
<find>getMessage(</find> <find>getMessage(</find>
<find>Adding to queue</find> <find>Adding to queue</find>
<find>leave</find>
<find>log_channel</find> <find>log_channel</find>
<find>testin</find> <find>testin</find>
<find>testing</find> <find>testing</find>
<find>RixaManager</find> <find>RixaManager</find>
<find>addPerm</find> <find>addPerm</find>
<find>list</find> <find>list</find>
<find>setString</find>
<find>openConn</find>
<find>join</find>
<find>&quot;play&quot;</find>
<find>&quot;join&quot;</find>
<find>leave</find>
<find>disable</find>
<find>enable</find>
<find>setEna</find>
</findStrings> </findStrings>
<replaceStrings> <replaceStrings>
<replace>setTitle(String.format(&quot;Help: %s&quot;, title))</replace> <replace>setTitle(String.format(&quot;Help: %s&quot;, title))</replace>
@ -519,7 +537,6 @@
<component name="IdeDocumentHistory"> <component name="IdeDocumentHistory">
<option name="CHANGED_PATHS"> <option name="CHANGED_PATHS">
<list> <list>
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/music/youtube/YoutubeSearch.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/Data.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/Data.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/Command.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/Command.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/music/TrackScheduler.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/music/TrackScheduler.java" />
@ -540,10 +557,8 @@
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaManager.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaManager.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/VoiceChannel.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/VoiceChannel.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/BatchMoveCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/BatchMoveCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/ConfigCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/ServerInfoCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/ServerInfoCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/mod/DeleteMessagesCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/mod/DeleteMessagesCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandHandler.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/HelpReaction.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/HelpReaction.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/ConfigReaction.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/ConfigReaction.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MemberEvent.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MemberEvent.java" />
@ -559,17 +574,20 @@
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/TwitterCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/TwitterCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/twitter/TwitterModule.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaGuild.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaGuild.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/levels/LevelsModule.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/LevelsCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/user/UserData.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/user/UserData.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/extras/polls/Poll.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/extras/polls/Poll.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/Rixa.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/Rixa.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/utils/MessageBuilder.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/utils/MessageBuilder.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/PingCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/PingCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/mysql/mysql/MySQL.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/DatabaseManager.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/DatabaseManager.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MessageEvent.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/mysql/mysql/MySQL.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/MusicCommand.java" /> <option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/MusicCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/LevelsManagementCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/LevelsCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MessageEvent.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/levels/LevelsModule.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/ConfigCommand.java" />
<option value="$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandHandler.java" />
</list> </list>
</option> </option>
</component> </component>
@ -583,10 +601,10 @@
<treeState /> <treeState />
</component> </component>
<component name="ProjectFrameBounds" extendedState="6"> <component name="ProjectFrameBounds" extendedState="6">
<option name="x" value="953" /> <option name="x" value="-8" />
<option name="y" value="26" /> <option name="y" value="-8" />
<option name="width" value="964" /> <option name="width" value="1256" />
<option name="height" value="1022" /> <option name="height" value="1047" />
</component> </component>
<component name="ProjectLevelVcsManager"> <component name="ProjectLevelVcsManager">
<ConfirmationsSetting value="1" id="Add" /> <ConfirmationsSetting value="1" id="Add" />
@ -606,7 +624,8 @@
<foldersAlwaysOnTop value="true" /> <foldersAlwaysOnTop value="true" />
</navigator> </navigator>
<panes> <panes>
<pane id="Scope" /> <pane id="Scratches" />
<pane id="PackagesPane" />
<pane id="ProjectPane"> <pane id="ProjectPane">
<subPane> <subPane>
<expand> <expand>
@ -649,6 +668,16 @@
<item name="rixa" type="462c0819:PsiDirectoryNode" /> <item name="rixa" type="462c0819:PsiDirectoryNode" />
<item name="commands" type="462c0819:PsiDirectoryNode" /> <item name="commands" type="462c0819:PsiDirectoryNode" />
</path> </path>
<path>
<item name="Rixa" type="b2602c69:ProjectViewProjectNode" />
<item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="main" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="java" type="462c0819:PsiDirectoryNode" />
<item name="rixa" type="462c0819:PsiDirectoryNode" />
<item name="commands" type="462c0819:PsiDirectoryNode" />
<item name="admin" type="462c0819:PsiDirectoryNode" />
</path>
<path> <path>
<item name="Rixa" type="b2602c69:ProjectViewProjectNode" /> <item name="Rixa" type="b2602c69:ProjectViewProjectNode" />
<item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" /> <item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
@ -659,12 +688,38 @@
<item name="commands" type="462c0819:PsiDirectoryNode" /> <item name="commands" type="462c0819:PsiDirectoryNode" />
<item name="general" type="462c0819:PsiDirectoryNode" /> <item name="general" type="462c0819:PsiDirectoryNode" />
</path> </path>
<path>
<item name="Rixa" type="b2602c69:ProjectViewProjectNode" />
<item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="main" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="java" type="462c0819:PsiDirectoryNode" />
<item name="rixa" type="462c0819:PsiDirectoryNode" />
<item name="events" type="462c0819:PsiDirectoryNode" />
</path>
<path>
<item name="Rixa" type="b2602c69:ProjectViewProjectNode" />
<item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="main" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="java" type="462c0819:PsiDirectoryNode" />
<item name="rixa" type="462c0819:PsiDirectoryNode" />
<item name="guild" type="462c0819:PsiDirectoryNode" />
</path>
<path>
<item name="Rixa" type="b2602c69:ProjectViewProjectNode" />
<item name="Rixa" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="main" type="8a07ba80:GradleTreeStructureProvider$GradleModuleDirectoryNode" />
<item name="java" type="462c0819:PsiDirectoryNode" />
<item name="rixa" type="462c0819:PsiDirectoryNode" />
<item name="modules" type="462c0819:PsiDirectoryNode" />
</path>
</expand> </expand>
<select /> <select />
</subPane> </subPane>
</pane> </pane>
<pane id="PackagesPane" /> <pane id="Scope" />
<pane id="Scratches" />
</panes> </panes>
</component> </component>
<component name="PropertiesComponent"> <component name="PropertiesComponent">
@ -848,6 +903,18 @@
<envs /> <envs />
<patterns /> <patterns />
</configuration> </configuration>
<configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<option name="MAIN_CLASS_NAME" />
<option name="VM_PARAMETERS" />
<option name="PROGRAM_PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PASS_PARENT_ENVS" value="true" />
<module name="Rixa" />
<envs />
</configuration>
<configuration default="true" type="#org.jetbrains.idea.devkit.run.PluginConfigurationType" factoryName="Plugin"> <configuration default="true" type="#org.jetbrains.idea.devkit.run.PluginConfigurationType" factoryName="Plugin">
<module name="" /> <module name="" />
<option name="VM_PARAMETERS" value="-Xmx512m -Xms256m -XX:MaxPermSize=250m -ea" /> <option name="VM_PARAMETERS" value="-Xmx512m -Xms256m -XX:MaxPermSize=250m -ea" />
@ -934,19 +1001,6 @@
<envs /> <envs />
<method /> <method />
</configuration> </configuration>
<configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<option name="MAIN_CLASS_NAME" />
<option name="VM_PARAMETERS" />
<option name="PROGRAM_PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PASS_PARENT_ENVS" value="true" />
<module name="Rixa" />
<envs />
<method />
</configuration>
<configuration default="true" type="KotlinStandaloneScriptRunConfigurationType" factoryName="Kotlin script"> <configuration default="true" type="KotlinStandaloneScriptRunConfigurationType" factoryName="Kotlin script">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" /> <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<option name="filePath" /> <option name="filePath" />
@ -1033,69 +1087,36 @@
<layout> <layout>
<window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" /> <window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32932165" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32932165" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Palette&#9;" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="Palette&#9;" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33403805" sideWeight="0.51875" order="7" side_tool="true" content_ui="tabs" /> <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33403805" sideWeight="0.51875" order="7" side_tool="true" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32941177" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> <window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32941177" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="11" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.63424945" sideWeight="0.49573562" order="2" side_tool="false" content_ui="tabs" /> <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.63424945" sideWeight="0.49573562" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" /> <window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.33297986" sideWeight="0.48125" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.33297986" sideWeight="0.48125" order="9" side_tool="false" content_ui="tabs" /> <window_info id="Designer" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Designer" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.24270834" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.118229166" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" /> <window_info id="Gradle" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Gradle" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="true" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Nl-Palette" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Properties" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32769555" sideWeight="0.4978678" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Image Layers" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Floobits" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32980973" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Theme Preview" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
</layout>
<layout-to-restore>
<window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Nl-Palette" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33403805" sideWeight="0.51875" order="7" side_tool="true" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32941177" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Properties" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Designer" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="true" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" /> <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32932165" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Nl-Palette" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
<window_info id="Properties" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32769555" sideWeight="0.4978678" order="9" side_tool="false" content_ui="tabs" /> <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32769555" sideWeight="0.4978678" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Palette&#9;" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Image Layers" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" /> <window_info id="Image Layers" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" /> <window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" /> <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.63424945" sideWeight="0.49573562" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="11" side_tool="false" content_ui="tabs" />
<window_info id="Floobits" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" /> <window_info id="Floobits" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.33403805" sideWeight="0.48125" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.23958333" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32980973" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" /> <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32980973" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Gradle" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="true" content_ui="tabs" />
<window_info id="Theme Preview" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" /> <window_info id="Theme Preview" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
</layout-to-restore> </layout>
</component> </component>
<component name="Vcs.Log.UiProperties"> <component name="Vcs.Log.UiProperties">
<option name="RECENTLY_FILTERED_USER_GROUPS"> <option name="RECENTLY_FILTERED_USER_GROUPS">
@ -1119,55 +1140,6 @@
<option name="FILTER_TARGETS" value="false" /> <option name="FILTER_TARGETS" value="false" />
</component> </component>
<component name="editorHistoryManager"> <component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/ServerInfoCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="203">
<caret line="23" column="39" lean-forward="false" selection-start-line="23" selection-start-column="39" selection-end-line="23" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandHandler.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="646">
<caret line="40" column="67" lean-forward="false" selection-start-line="40" selection-start-column="67" selection-end-line="40" selection-end-column="67" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/HelpReaction.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="60" column="48" lean-forward="false" selection-start-line="60" selection-start-column="48" selection-end-line="60" selection-end-column="48" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/reactions/react/ConfigReaction.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="408">
<caret line="37" column="39" lean-forward="false" selection-start-line="37" selection-start-column="39" selection-end-line="37" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/BotEvent.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="408">
<caret line="32" column="39" lean-forward="false" selection-start-line="32" selection-start-column="39" selection-end-line="32" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/mod/PurgeMessagesCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-159">
<caret line="34" column="39" lean-forward="false" selection-start-line="34" selection-start-column="39" selection-end-line="34" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandRegistrar.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119">
<caret line="9" column="13" lean-forward="false" selection-start-line="9" selection-start-column="13" selection-end-line="9" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/mod/DeleteMessagesCommand.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/mod/DeleteMessagesCommand.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="272"> <state relative-caret-position="272">
@ -1232,20 +1204,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/BatchMoveCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="220">
<caret line="29" column="7" lean-forward="false" selection-start-line="29" selection-start-column="7" selection-end-line="29" selection-end-column="181" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/RemoveRoleCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="306">
<caret line="39" column="17" lean-forward="true" selection-start-line="39" selection-start-column="17" selection-end-line="39" selection-end-column="17" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/locale/Language.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/locale/Language.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="204"> <state relative-caret-position="204">
@ -1260,13 +1218,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/AddRoleCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119">
<caret line="22" column="13" lean-forward="false" selection-start-line="22" selection-start-column="13" selection-end-line="22" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/InviteCommand.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/InviteCommand.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119"> <state relative-caret-position="119">
@ -1344,13 +1295,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/ConfigCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-340">
<caret line="59" column="31" lean-forward="false" selection-start-line="59" selection-start-column="31" selection-end-line="59" selection-end-column="31" />
</state>
</provider>
</entry>
<entry file="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.dv8tion/JDA/3.1.1_215/71bc8974bda66301a498c14b5693b007a60bc0c4/JDA-3.1.1_215-sources.jar!/net/dv8tion/jda/core/entities/User.java"> <entry file="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.dv8tion/JDA/3.1.1_215/71bc8974bda66301a498c14b5693b007a60bc0c4/JDA-3.1.1_215-sources.jar!/net/dv8tion/jda/core/entities/User.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="252"> <state relative-caret-position="252">
@ -1358,27 +1302,6 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/LevelsCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="409">
<caret line="38" column="82" lean-forward="false" selection-start-line="38" selection-start-column="82" selection-end-line="38" selection-end-column="82" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaGuild.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="255">
<caret line="36" column="41" lean-forward="false" selection-start-line="36" selection-start-column="41" selection-end-line="36" selection-end-column="41" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/levels/LevelsModule.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="375">
<caret line="34" column="35" lean-forward="false" selection-start-line="34" selection-start-column="35" selection-end-line="34" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/extras/polls/Poll.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/extras/polls/Poll.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="102"> <state relative-caret-position="102">
@ -1435,38 +1358,208 @@
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/mysql/mysql/MySQL.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/mysql/Database.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="782"> <state relative-caret-position="255">
<caret line="77" column="41" lean-forward="false" selection-start-line="77" selection-start-column="41" selection-end-line="77" selection-end-column="41" /> <caret line="39" column="18" lean-forward="false" selection-start-line="38" selection-start-column="17" selection-end-line="39" selection-end-column="18" />
<folding>
<element signature="method#checkConnection#0;class#Database#0" expanded="false" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/DatabaseManager.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/DatabaseManager.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="17"> <state relative-caret-position="303">
<caret line="54" column="31" lean-forward="true" selection-start-line="54" selection-start-column="31" selection-end-line="54" selection-end-column="31" /> <caret line="114" column="27" lean-forward="true" selection-start-line="114" selection-start-column="27" selection-end-line="114" selection-end-column="27" />
<folding>
<element signature="method#createTable#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#checkConnection#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#executeUpdate#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#getObject#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#getObject#1;class#DatabaseManager#0" expanded="true" />
<element signature="method#executeQuery#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#getCount#0;class#DatabaseManager#0" expanded="true" />
<element signature="method#insert#0;class#DatabaseManager#0" expanded="true" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/user/UserData.java"> <entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/sql/DriverManager.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119"> <state relative-caret-position="-504">
<caret line="18" column="13" lean-forward="false" selection-start-line="18" selection-start-column="13" selection-end-line="18" selection-end-column="13" /> <caret line="632" column="84" lean-forward="true" selection-start-line="632" selection-start-column="84" selection-end-line="632" selection-end-column="84" />
<folding>
<element signature="method#getConnection#1;class#DriverManager#0" expanded="false" />
<element signature="method#getConnection#3;class#DriverManager#0" expanded="false" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MessageEvent.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/data/database/sql/mysql/mysql/MySQL.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0"> <state relative-caret-position="292">
<caret line="29" column="3" lean-forward="true" selection-start-line="29" selection-start-column="3" selection-end-line="29" selection-end-column="3" /> <caret line="51" column="7" lean-forward="true" selection-start-line="51" selection-start-column="7" selection-end-line="51" selection-end-column="7" />
<folding>
<element signature="method#MySQL#0;class#MySQL#0" expanded="false" />
<element signature="method#MySQL#1;class#MySQL#0" expanded="false" />
<element signature="method#openConnection#0;class#MySQL#0" expanded="false" />
</folding>
</state> </state>
</provider> </provider>
</entry> </entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/MusicCommand.java"> <entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/MusicCommand.java">
<provider selected="true" editor-type-id="text-editor"> <provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="518"> <state relative-caret-position="592">
<caret line="206" column="130" lean-forward="false" selection-start-line="206" selection-start-column="130" selection-end-line="206" selection-end-column="130" /> <caret line="121" column="68" lean-forward="false" selection-start-line="121" selection-start-column="68" selection-end-line="121" selection-end-column="68" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/LevelsManagementCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119">
<caret line="7" column="9" lean-forward="false" selection-start-line="7" selection-start-column="9" selection-end-line="7" selection-end-column="9" />
<folding />
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/util/Collections.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="193">
<caret line="173" column="27" lean-forward="false" selection-start-line="173" selection-start-column="27" selection-end-line="173" selection-end-column="27" />
<folding>
<element signature="e#7284#7285#0" expanded="false" />
<element signature="e#7312#7313#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/util/Comparator.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="170">
<caret line="149" column="8" lean-forward="false" selection-start-line="149" selection-start-column="8" selection-end-line="149" selection-end-column="8" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/general/LevelsCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-235">
<caret line="34" column="38" lean-forward="true" selection-start-line="34" selection-start-column="38" selection-end-line="34" selection-end-column="38" />
<folding>
<element signature="e#581#590#0" expanded="true" />
<element signature="e#1160#1218#0" expanded="true" />
<element signature="method#sortHashMapByValues#0;class#LevelsCommand#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/user/UserData.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="918">
<caret line="111" column="4" lean-forward="false" selection-start-line="111" selection-start-column="4" selection-end-line="115" selection-end-column="5" />
<folding>
<element signature="method#load#0;class#UserData#0" expanded="true" />
<element signature="method#checkExists#0;class#UserData#0" expanded="true" />
<element signature="method#insert#0;class#UserData#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/guild/RixaGuild.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="462">
<caret line="164" column="1" lean-forward="true" selection-start-line="164" selection-start-column="1" selection-end-line="164" selection-end-column="1" />
<folding>
<element signature="method#RixaGuild#0;class#RixaGuild#0" expanded="true" />
<element signature="method#load#0;class#RixaGuild#0" expanded="true" />
<element signature="method#getGuildSettings#0;class#RixaGuild#0" expanded="true" />
<element signature="method#checkExists#0;class#RixaGuild#0" expanded="true" />
<element signature="method#hasPermission#0;class#RixaGuild#0" expanded="true" />
<element signature="method#hasPermission#1;class#RixaGuild#0" expanded="true" />
<element signature="method#permissionExists#0;class#RixaGuild#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/levels/LevelsModule.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="501">
<caret line="99" column="5" lean-forward="true" selection-start-line="99" selection-start-column="5" selection-end-line="99" selection-end-column="5" />
<folding>
<element signature="method#LevelsModule#0;class#LevelsModule#0" expanded="true" />
<element signature="method#registerUser#0;class#LevelsModule#0" expanded="true" />
<element signature="method#getUserData#0;class#LevelsModule#0" expanded="true" />
<element signature="method#checkUser#0;class#LevelsModule#0" expanded="true" />
<element signature="method#load#0;class#LevelsModule#0" expanded="true" />
<element signature="method#checkExists#0;class#LevelsModule#0" expanded="true" />
<element signature="method#insert#0;class#LevelsModule#0" expanded="true" />
<element signature="method#setEnabled#0;class#LevelsModule#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/modules/music/MusicModule.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-8">
<caret line="18" column="11" lean-forward="false" selection-start-line="18" selection-start-column="5" selection-end-line="18" selection-end-column="11" />
<folding>
<element signature="method#setEnabled#0;class#MusicModule#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/ConfigCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="145">
<caret line="190" column="75" lean-forward="false" selection-start-line="190" selection-start-column="75" selection-end-line="190" selection-end-column="75" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/BatchMoveCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="170">
<caret line="29" column="7" lean-forward="false" selection-start-line="29" selection-start-column="7" selection-end-line="29" selection-end-column="181" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/RemoveRoleCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="68">
<caret line="21" column="4" lean-forward="true" selection-start-line="21" selection-start-column="4" selection-end-line="21" selection-end-column="4" />
<folding>
<element signature="e#726#964#0" expanded="false" />
<element signature="method#execute#0;class#RemoveRoleCommand#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/admin/AddRoleCommand.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="51">
<caret line="29" column="57" lean-forward="true" selection-start-line="29" selection-start-column="57" selection-end-line="29" selection-end-column="57" />
<folding>
<element signature="e#886#1120#0" expanded="false" />
<element signature="method#execute#0;class#AddRoleCommand#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/events/MessageEvent.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="60" column="33" lean-forward="true" selection-start-line="60" selection-start-column="33" selection-end-line="60" selection-end-column="33" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/main/java/me/savvy/rixa/commands/handlers/CommandHandler.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="289">
<caret line="28" column="32" lean-forward="false" selection-start-line="28" selection-start-column="32" selection-end-line="28" selection-end-column="32" />
<folding /> <folding />
</state> </state>
</provider> </provider>

View File

@ -12,6 +12,7 @@ import net.dv8tion.jda.core.entities.Member;
import net.dv8tion.jda.core.entities.Role; import net.dv8tion.jda.core.entities.Role;
import net.dv8tion.jda.core.entities.TextChannel; import net.dv8tion.jda.core.entities.TextChannel;
import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent; import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent;
import net.dv8tion.jda.core.managers.GuildManager;
import org.apache.commons.lang3.EnumUtils; import org.apache.commons.lang3.EnumUtils;
import java.util.Arrays; import java.util.Arrays;
@ -174,10 +175,10 @@ public class ConfigCommand implements CommandExec {
if (messages[2].equalsIgnoreCase("music")) { if (messages[2].equalsIgnoreCase("music")) {
RixaGuild.getGuild(event.getGuild()).getMusicModule().setEnabled(true); RixaGuild.getGuild(event.getGuild()).getMusicModule().setEnabled(true);
new MessageBuilder("Successfully enabled the music module!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("Successfully enabled the music module!").setColor(event.getMember().getColor()).queue(event.getChannel());
} /*else if (messages[2].equalsIgnoreCase("levels")) { } else if (messages[2].equalsIgnoreCase("levels")) {
GuildManager.getGuild(event.getGuild().getId()).getLevels().setEnabled(true); RixaGuild.getGuild(event.getGuild()).getLevelsModule().setEnabled(true);
event.getChannel().sendMessage("Successfully enabled the `Levels` module").queue(); event.getChannel().sendMessage("Successfully enabled the levels module").queue();
}*/ else if (messages[2].equalsIgnoreCase("joinverification")) { } else if (messages[2].equalsIgnoreCase("joinverification")) {
RixaGuild.getGuild(event.getGuild()).getGuildSettings().setJoinVerification(true); RixaGuild.getGuild(event.getGuild()).getGuildSettings().setJoinVerification(true);
new MessageBuilder("Successfully enabled Join Verification!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("Successfully enabled Join Verification!").setColor(event.getMember().getColor()).queue(event.getChannel());
} }
@ -185,10 +186,10 @@ public class ConfigCommand implements CommandExec {
if (messages[2].equalsIgnoreCase("music")) { if (messages[2].equalsIgnoreCase("music")) {
RixaGuild.getGuild(event.getGuild()).getMusicModule().setEnabled(false); RixaGuild.getGuild(event.getGuild()).getMusicModule().setEnabled(false);
new MessageBuilder("Successfully disabled the music module!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("Successfully disabled the music module!").setColor(event.getMember().getColor()).queue(event.getChannel());
}/* else if (messages[2].equalsIgnoreCase("levels")) { } else if (messages[2].equalsIgnoreCase("levels")) {
GuildManager.getGuild(event.getGuild().getId()).getLevels().setEnabled(false); RixaGuild.getGuild(event.getGuild()).getLevelsModule().setEnabled(false);
event.getChannel().sendMessage("Successfully disabled the `Levels` module").queue(); event.getChannel().sendMessage("Successfully disabled the levels module").queue();
}*/ else if (messages[2].equalsIgnoreCase("joinverification")) { } else if (messages[2].equalsIgnoreCase("joinverification")) {
RixaGuild.getGuild(event.getGuild()).getGuildSettings().setJoinVerification(false); RixaGuild.getGuild(event.getGuild()).getGuildSettings().setJoinVerification(false);
new MessageBuilder("Successfully disabled Join Verification!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("Successfully disabled Join Verification!").setColor(event.getMember().getColor()).queue(event.getChannel());
} }

View File

@ -0,0 +1,9 @@
package me.savvy.rixa.commands.admin;
public class LevelsManagementCommand {
// xp give/add <user> <amount>
// xp take/remove <user> <amount>
// xp set <user> <amount>
// xp convert <type> <user/all>
}

View File

@ -10,6 +10,7 @@ import net.dv8tion.jda.core.entities.ChannelType;
import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent; import net.dv8tion.jda.core.events.message.guild.GuildMessageReceivedEvent;
import java.io.IOException; import java.io.IOException;
import java.util.*;
/** /**
* Created by savit on 7/11/2017. * Created by savit on 7/11/2017.
@ -27,6 +28,11 @@ public class LevelsCommand implements CommandExec {
return; return;
} }
UserData data = rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId()); UserData data = rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId());
// Map<UserData, Integer> newMap = new HashMap<>();
// rixaGuild.getLevelsModule().getUserData().forEach((s, userData) -> {
// newMap.put(userData, userData.getExperience());
// });
// sortHashMapByValues(newMap);
new MessageBuilder() new MessageBuilder()
.setAuthor(event.getAuthor().getName(), event.getAuthor().getEffectiveAvatarUrl(), event.getAuthor().getEffectiveAvatarUrl()) .setAuthor(event.getAuthor().getName(), event.getAuthor().getEffectiveAvatarUrl(), event.getAuthor().getEffectiveAvatarUrl())
.setTitle(event.getAuthor().getName() + "'s level") .setTitle(event.getAuthor().getName() + "'s level")
@ -39,4 +45,32 @@ public class LevelsCommand implements CommandExec {
.addField("Total Exp", String.valueOf(data.getExperience()), false) .addField("Total Exp", String.valueOf(data.getExperience()), false)
.queue(event.getChannel()); .queue(event.getChannel());
} }
public LinkedHashMap<UserData, Integer> sortHashMapByValues(
Map<UserData, Integer> passedMap) {
List<UserData> mapKeys = new ArrayList<>(passedMap.keySet());
List<Integer> mapValues = new ArrayList<>(passedMap.values());
Collections.sort(mapValues);
//Collections.sort(mapKeys);
LinkedHashMap<UserData, Integer> sortedMap =
new LinkedHashMap<>();
for (Integer val : mapValues) {
Iterator<UserData> keyIt = mapKeys.iterator();
while (keyIt.hasNext()) {
UserData key = keyIt.next();
Integer comp1 = passedMap.get(key);
if (comp1.equals(val)) {
keyIt.remove();
sortedMap.put(key, val);
break;
}
}
}
return sortedMap;
}
} }

View File

@ -92,7 +92,7 @@ public class MusicCommand implements CommandExec {
if(message.length == 1) { if(message.length == 1) {
sendHelp(); sendHelp();
} else if (message.length == 2) { } else if (message.length == 2) {
if(message[1].equalsIgnoreCase("join")) { if(message[1].equalsIgnoreCase("join") || message[1].equalsIgnoreCase("summon") ) {
if (event.getMember().getVoiceState().getChannel() == null) { if (event.getMember().getVoiceState().getChannel() == null) {
new MessageBuilder("You must be in a voice channel to summon me!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("You must be in a voice channel to summon me!").setColor(event.getMember().getColor()).queue(event.getChannel());
return; return;
@ -114,16 +114,14 @@ public class MusicCommand implements CommandExec {
new MessageBuilder("The audio queue is empty! Add a track to the queue first!").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("The audio queue is empty! Add a track to the queue first!").setColor(event.getMember().getColor()).queue(event.getChannel());
} }
} else if (message[1].equalsIgnoreCase("leave")) { } else if (message[1].equalsIgnoreCase("leave")) {
new MessageBuilder("Leaving voice channel.").setColor(event.getMember().getColor()).queue(event.getChannel()); String desc = "";
guild.getAudioManager().setSendingHandler(null);
AudioTrack track = scheduler.nextTrack(); AudioTrack track = scheduler.nextTrack();
if(track != null) { if(track != null) {
new MessageBuilder("The current track has been skipped. Now Playiguild.getAudioManager().closeAudioConnection();\n" + desc += "Track skipped. ";
" } else if(message[1].equalsIgnoreCase(\"skip\")) {ng: " + track.getInfo().title).setColor(event.getMember().getColor()).queue(event.getChannel());
} else {
new MessageBuilder("Track Skipped. Queue Complete").setColor(event.getMember().getColor()).queue(event.getChannel());
} }
new MessageBuilder(desc + " Leaving voice channel...").setColor(event.getMember().getColor()).queue(event.getChannel());
guild.getAudioManager().setSendingHandler(null);
guild.getAudioManager().closeAudioConnection();
} else if(message[1].equalsIgnoreCase("link")) { } else if(message[1].equalsIgnoreCase("link")) {
if (player.getPlayingTrack() == null) { if (player.getPlayingTrack() == null) {
new MessageBuilder("There is no track currently playing.").setColor(event.getMember().getColor()).queue(event.getChannel()); new MessageBuilder("There is no track currently playing.").setColor(event.getMember().getColor()).queue(event.getChannel());
@ -242,7 +240,18 @@ public class MusicCommand implements CommandExec {
} }
} }
} else if(message[1].equalsIgnoreCase("play") || message[1].equalsIgnoreCase("playlist")) { } else if(message[1].equalsIgnoreCase("play") || message[1].equalsIgnoreCase("playlist")) {
if (event.getMember().getVoiceState().getChannel() == null) {
new MessageBuilder("You must be in a voice channel to summon me!").setColor(event.getMember().getColor()).queue(event.getChannel());
return;
}
try {
guild.getAudioManager().openAudioConnection(event.getMember().getVoiceState().getChannel());
loadAndPlay(mng, event.getChannel(), message[2], false); loadAndPlay(mng, event.getChannel(), message[2], false);
} catch (PermissionException e) {
if (e.getPermission() == Permission.VOICE_CONNECT) {
new MessageBuilder("I do not have permission to join the requested voice channel.").setColor(event.getMember().getColor()).queue(event.getChannel());
}
}
} else if(message[1].equalsIgnoreCase("vol") || message[1].equalsIgnoreCase("volume")) { } else if(message[1].equalsIgnoreCase("vol") || message[1].equalsIgnoreCase("volume")) {
try { try {
int newVolume = Math.max(10, Math.min(100, Integer.parseInt(message[2]))); int newVolume = Math.max(10, Math.min(100, Integer.parseInt(message[2])));
@ -254,8 +263,34 @@ public class MusicCommand implements CommandExec {
} }
} }
} // music youtube <query } // music youtube <query
if(message.length >= 3) { else if(message.length >= 3) {
if(message[1].equalsIgnoreCase("youtube") || message[1].equalsIgnoreCase("yt") || message[1].equalsIgnoreCase("search") if(message[1].equalsIgnoreCase("join")) {
VoiceChannel chan = null;
String channelName = getMessage(message, 2);
if (guild.getVoiceChannelsByName(channelName, true).size() >= 1) {
chan = guild.getVoiceChannelsByName(channelName, true).get(0);
} else {
for (VoiceChannel voiceChannel : guild.getVoiceChannels()) {
if (voiceChannel.getName().contains(channelName) || voiceChannel.getId().equalsIgnoreCase(channelName)) {
chan = voiceChannel;
break;
}
}
}
if (chan == null) {
new MessageBuilder("Sorry I was unable to find the VoiceChannel: `" + message[2] + "`.").setColor(event.getMember().getColor()).queue(event.getChannel());
} else {
guild.getAudioManager().setSendingHandler(mng.sendHandler);
try {
new MessageBuilder("Entering Voice Channel: " + chan.getName()).setColor(event.getMember().getColor()).queue(event.getChannel());
guild.getAudioManager().openAudioConnection(chan);
} catch (PermissionException e) {
if (e.getPermission() == Permission.VOICE_CONNECT) {
new MessageBuilder("I do not have permission to join the requested voice channel.").setColor(event.getMember().getColor()).queue(event.getChannel());
}
}
}
} else if(message[1].equalsIgnoreCase("youtube") || message[1].equalsIgnoreCase("yt") || message[1].equalsIgnoreCase("search")
|| message[1].equalsIgnoreCase("ytsearch")) { || message[1].equalsIgnoreCase("ytsearch")) {
String search = getMessage(message, 2); String search = getMessage(message, 2);
try { try {

View File

@ -25,6 +25,9 @@ public class CommandHandler {
return true; return true;
} else { } else {
for (CommandRegistrar commandRegistrar : getCommands().values()) { for (CommandRegistrar commandRegistrar : getCommands().values()) {
if (commandRegistrar.getAnnotation().mainCommand().equalsIgnoreCase(s)) {
return true;
}
for (String string : commandRegistrar.getAnnotation().aliases()) { for (String string : commandRegistrar.getAnnotation().aliases()) {
if (string.equalsIgnoreCase(s)) return true; if (string.equalsIgnoreCase(s)) return true;
} }

View File

@ -112,8 +112,10 @@ public class DatabaseManager {
PreparedStatement ps = connection.prepareStatement(string); PreparedStatement ps = connection.prepareStatement(string);
ResultSet rs = ps.executeQuery(); ResultSet rs = ps.executeQuery();
if(rs.next()) { if(rs.next()) {
rs.close();
return Result.TRUE; return Result.TRUE;
}else { }else {
rs.close();
return Result.FALSE; return Result.FALSE;
} }
} catch (SQLException e) { } catch (SQLException e) {

View File

@ -73,7 +73,6 @@ public class MySQL extends Database {
} }
Class.forName("com.mysql.jdbc.Driver"); Class.forName("com.mysql.jdbc.Driver");
// Class.forName("com.mysql.cj.jdbc.Driver");
connection = DriverManager.getConnection(connectionURL, connection = DriverManager.getConnection(connectionURL,
this.user, this.password); this.user, this.password);
return connection; return connection;

View File

@ -45,10 +45,10 @@ public class MessageEvent {
if (!(rixaGuild.getLevelsModule().isEnabled())) { if (!(rixaGuild.getLevelsModule().isEnabled())) {
return; return;
} }
if(!event.getAuthor().getId().equalsIgnoreCase("202944101333729280") && /*if(!event.getAuthor().getId().equalsIgnoreCase("202944101333729280") &&
!event.getAuthor().getId().equalsIgnoreCase("207322957075185665")) { !event.getAuthor().getId().equalsIgnoreCase("207322957075185665")) {
return; return;
} }*/
if(rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId()).awardIfCan()) { if(rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId()).awardIfCan()) {
new MessageBuilder(event.getAuthor().getAsMention() + " has leveled up to level " + new MessageBuilder(event.getAuthor().getAsMention() + " has leveled up to level " +
rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId()).getLevel()) rixaGuild.getLevelsModule().getUserData(event.getAuthor().getId()).getLevel())

View File

@ -1,10 +1,17 @@
package me.savvy.rixa.modules.levels; package me.savvy.rixa.modules.levels;
import lombok.Getter; import lombok.Getter;
import lombok.Setter;
import me.savvy.rixa.Rixa;
import me.savvy.rixa.commands.handlers.RixaPermission;
import me.savvy.rixa.enums.Result;
import me.savvy.rixa.guild.RixaGuild; import me.savvy.rixa.guild.RixaGuild;
import me.savvy.rixa.guild.user.UserData; import me.savvy.rixa.guild.user.UserData;
import me.savvy.rixa.modules.RixaModule; import me.savvy.rixa.modules.RixaModule;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
@ -20,6 +27,7 @@ public class LevelsModule implements RixaModule {
public LevelsModule(RixaGuild rixaGuild) { public LevelsModule(RixaGuild rixaGuild) {
this.rixaGuild = rixaGuild; this.rixaGuild = rixaGuild;
enabled = true; enabled = true;
load();
} }
@Override @Override
@ -52,4 +60,42 @@ public class LevelsModule implements RixaModule {
(getRixaGuild().getGuild().getJDA().getUserById(key), (getRixaGuild().getGuild().getJDA().getUserById(key),
getRixaGuild().getGuild()); getRixaGuild().getGuild());
} }
private void load() {
if (!(checkExists())) {
this.enabled = true;
insert();
}
String query = "SELECT `levels` FROM `modules` WHERE `guild_id` = ?;";
PreparedStatement ps = null;
ResultSet rs = null;
try {
ps = Rixa.getDbManager().getConnection().prepareStatement(query);
ps.setString(1, getRixaGuild().getGuild().getId());
rs = Rixa.getDbManager().getObject(ps);
this.enabled = rs.getBoolean("levels");
ps.close();
rs.close();
} catch (SQLException e) {
e.printStackTrace();
}
}
private boolean checkExists() {
String query = "SELECT `%s` FROM `%s` WHERE `%s` = '%s';";
Result r = Rixa.getDbManager().checkExists(String.format
(query, "guild_id", "modules", "guild_id", rixaGuild.getGuild().getId()));
return r == Result.TRUE;
}
private void insert() {
String query = "INSERT INTO `%s` (`%s`) VALUES ('%s');";
Rixa.getDbManager()
.insert(String.format(query, "modules", "guild_id", rixaGuild.getGuild().getId()));
}
public void setEnabled(boolean enabled) {
this.enabled = enabled;
Rixa.getData().update("modules", "enabled", "guild_id", enabled, rixaGuild.getGuild().getId());
}
} }