supression du chat.
ajout de la configuration de la commande faite lors de l'arrivé sur un téléporteur
This commit is contained in:
parent
aadfde75f5
commit
fcd0ab767f
10
.idea/artifacts/Menoria.xml
generated
Normal file
10
.idea/artifacts/Menoria.xml
generated
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
<component name="ArtifactManager">
|
||||||
|
<artifact type="jar" name="Menoria">
|
||||||
|
<output-path>$PROJECT_DIR$/out/artifacts/Menoria</output-path>
|
||||||
|
<root id="archive" name="Menoria.jar">
|
||||||
|
<element id="module-output" name="Menoria" />
|
||||||
|
<element id="file-copy" path="$PROJECT_DIR$/Menoria/config.yml" />
|
||||||
|
<element id="file-copy" path="$PROJECT_DIR$/Menoria/plugin.yml" />
|
||||||
|
</root>
|
||||||
|
</artifact>
|
||||||
|
</component>
|
22
.idea/compiler.xml
generated
Normal file
22
.idea/compiler.xml
generated
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="CompilerConfiguration">
|
||||||
|
<resourceExtensions />
|
||||||
|
<wildcardResourcePatterns>
|
||||||
|
<entry name="!?*.java" />
|
||||||
|
<entry name="!?*.form" />
|
||||||
|
<entry name="!?*.class" />
|
||||||
|
<entry name="!?*.groovy" />
|
||||||
|
<entry name="!?*.scala" />
|
||||||
|
<entry name="!?*.flex" />
|
||||||
|
<entry name="!?*.kt" />
|
||||||
|
<entry name="!?*.clj" />
|
||||||
|
<entry name="!?*.aj" />
|
||||||
|
</wildcardResourcePatterns>
|
||||||
|
<annotationProcessing>
|
||||||
|
<profile default="true" name="Default" enabled="false">
|
||||||
|
<processorPath useClasspath="true" />
|
||||||
|
</profile>
|
||||||
|
</annotationProcessing>
|
||||||
|
</component>
|
||||||
|
</project>
|
3
.idea/copyright/profiles_settings.xml
generated
Normal file
3
.idea/copyright/profiles_settings.xml
generated
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
<component name="CopyrightManager">
|
||||||
|
<settings default="" />
|
||||||
|
</component>
|
7
.idea/encodings.xml
generated
Normal file
7
.idea/encodings.xml
generated
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="Encoding">
|
||||||
|
<file url="file://$PROJECT_DIR$/Menoria/src/net/DeltaWings/Nemoria/Commands/SetTP.java" charset="UTF-8" />
|
||||||
|
<file url="file://$PROJECT_DIR$/Menoria/src/net/DeltaWings/Nemoria/Listeners/PlayerPositionListener.java" charset="UTF-8" />
|
||||||
|
</component>
|
||||||
|
</project>
|
13
.idea/libraries/Jobs3_6_3Experimental.xml
generated
Normal file
13
.idea/libraries/Jobs3_6_3Experimental.xml
generated
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<component name="libraryTable">
|
||||||
|
<library name="Jobs3.6.3Experimental">
|
||||||
|
<CLASSES>
|
||||||
|
<root url="jar://$PROJECT_DIR$/Menoria/lib/Jobs3.6.3Experimental.jar!/" />
|
||||||
|
<root url="jar://$PROJECT_DIR$/Menoria/lib/spigot-1.10.2.jar!/" />
|
||||||
|
<root url="jar://$PROJECT_DIR$/Menoria/lib/Vault.jar!/" />
|
||||||
|
</CLASSES>
|
||||||
|
<JAVADOC />
|
||||||
|
<SOURCES>
|
||||||
|
<root url="jar://$PROJECT_DIR$/Menoria/lib/spigot-1.10.2.jar!/" />
|
||||||
|
</SOURCES>
|
||||||
|
</library>
|
||||||
|
</component>
|
57
.idea/misc.xml
generated
Normal file
57
.idea/misc.xml
generated
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ClientPropertiesManager">
|
||||||
|
<properties class="javax.swing.AbstractButton">
|
||||||
|
<property name="hideActionText" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JComponent">
|
||||||
|
<property name="html.disable" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JEditorPane">
|
||||||
|
<property name="JEditorPane.w3cLengthUnits" class="java.lang.Boolean" />
|
||||||
|
<property name="JEditorPane.honorDisplayProperties" class="java.lang.Boolean" />
|
||||||
|
<property name="charset" class="java.lang.String" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JList">
|
||||||
|
<property name="List.isFileList" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JPasswordField">
|
||||||
|
<property name="JPasswordField.cutCopyAllowed" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JSlider">
|
||||||
|
<property name="Slider.paintThumbArrowShape" class="java.lang.Boolean" />
|
||||||
|
<property name="JSlider.isFilled" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JTable">
|
||||||
|
<property name="Table.isFileList" class="java.lang.Boolean" />
|
||||||
|
<property name="JTable.autoStartsEdit" class="java.lang.Boolean" />
|
||||||
|
<property name="terminateEditOnFocusLost" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JToolBar">
|
||||||
|
<property name="JToolBar.isRollover" class="java.lang.Boolean" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.JTree">
|
||||||
|
<property name="JTree.lineStyle" class="java.lang.String" />
|
||||||
|
</properties>
|
||||||
|
<properties class="javax.swing.text.JTextComponent">
|
||||||
|
<property name="caretAspectRatio" class="java.lang.Double" />
|
||||||
|
<property name="caretWidth" class="java.lang.Integer" />
|
||||||
|
</properties>
|
||||||
|
</component>
|
||||||
|
<component name="EntryPointsManager">
|
||||||
|
<entry_points version="2.0" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectLevelVcsManager" settingsEditedManually="false">
|
||||||
|
<OptionsSetting value="true" id="Add" />
|
||||||
|
<OptionsSetting value="true" id="Remove" />
|
||||||
|
<OptionsSetting value="true" id="Checkout" />
|
||||||
|
<OptionsSetting value="true" id="Update" />
|
||||||
|
<OptionsSetting value="true" id="Status" />
|
||||||
|
<OptionsSetting value="true" id="Edit" />
|
||||||
|
<ConfirmationsSetting value="0" id="Add" />
|
||||||
|
<ConfirmationsSetting value="0" id="Remove" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" default="true" assert-keyword="true" jdk-15="true" project-jdk-name="1.7" project-jdk-type="JavaSDK">
|
||||||
|
<output url="file://$PROJECT_DIR$/out" />
|
||||||
|
</component>
|
||||||
|
</project>
|
8
.idea/modules.xml
generated
Normal file
8
.idea/modules.xml
generated
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/Menoria/Menoria.iml" filepath="$PROJECT_DIR$/Menoria/Menoria.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
124
.idea/uiDesigner.xml
generated
Normal file
124
.idea/uiDesigner.xml
generated
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="Palette2">
|
||||||
|
<group name="Swing">
|
||||||
|
<item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
|
||||||
|
<initial-values>
|
||||||
|
<property name="text" value="Button" />
|
||||||
|
</initial-values>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
|
||||||
|
<initial-values>
|
||||||
|
<property name="text" value="RadioButton" />
|
||||||
|
</initial-values>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
|
||||||
|
<initial-values>
|
||||||
|
<property name="text" value="CheckBox" />
|
||||||
|
</initial-values>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
|
||||||
|
<initial-values>
|
||||||
|
<property name="text" value="Label" />
|
||||||
|
</initial-values>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
|
||||||
|
<preferred-size width="150" height="-1" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
|
||||||
|
<preferred-size width="150" height="-1" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
|
||||||
|
<preferred-size width="150" height="-1" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
|
||||||
|
<preferred-size width="150" height="50" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
|
||||||
|
<preferred-size width="200" height="200" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
|
||||||
|
<preferred-size width="200" height="200" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
|
||||||
|
<preferred-size width="-1" height="20" />
|
||||||
|
</default-constraints>
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
|
||||||
|
</item>
|
||||||
|
<item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
|
||||||
|
<default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
|
||||||
|
</item>
|
||||||
|
</group>
|
||||||
|
</component>
|
||||||
|
</project>
|
6
.idea/vcs.xml
generated
Normal file
6
.idea/vcs.xml
generated
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
34
Menoria/Menoria.iml
Normal file
34
Menoria/Menoria.iml
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="JAVA_MODULE" version="4">
|
||||||
|
<component name="EclipseModuleManager">
|
||||||
|
<libelement value="file:///home/florian/Documents/Libs/Minecraft/Plugin/Spigot/1.10.2/spigot-1.10.2.jar" />
|
||||||
|
<libelement value="file:///home/florian/Documents/Libs/Minecraft/Plugin/Vault/Vault.jar" />
|
||||||
|
<libelement value="file:///home/florian/Documents/Libs/Minecraft/Plugin/Jobs Reborn/3.5.6/Jobs3.5.6.jar" />
|
||||||
|
<src_description expected_position="0">
|
||||||
|
<src_folder value="file://$MODULE_DIR$/src" expected_position="0" />
|
||||||
|
</src_description>
|
||||||
|
</component>
|
||||||
|
<component name="NewModuleRootManager" inherit-compiler-output="false">
|
||||||
|
<output url="file://$MODULE_DIR$/bin" />
|
||||||
|
<exclude-output />
|
||||||
|
<content url="file://$MODULE_DIR$">
|
||||||
|
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
|
||||||
|
</content>
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
<orderEntry type="jdk" jdkName="1.7" jdkType="JavaSDK" />
|
||||||
|
<orderEntry type="module-library" scope="PROVIDED">
|
||||||
|
<library>
|
||||||
|
<CLASSES>
|
||||||
|
<root url="file://$MODULE_DIR$/lib" />
|
||||||
|
</CLASSES>
|
||||||
|
<JAVADOC />
|
||||||
|
<SOURCES>
|
||||||
|
<root url="file://$MODULE_DIR$/lib" />
|
||||||
|
</SOURCES>
|
||||||
|
<jarDirectory url="file://$MODULE_DIR$/lib" recursive="false" />
|
||||||
|
<jarDirectory url="file://$MODULE_DIR$/lib" recursive="false" type="SOURCES" />
|
||||||
|
</library>
|
||||||
|
</orderEntry>
|
||||||
|
<orderEntry type="library" exported="" scope="PROVIDED" name="Jobs3.6.3Experimental" level="project" />
|
||||||
|
</component>
|
||||||
|
</module>
|
@ -4,5 +4,6 @@ teleporteurs:
|
|||||||
x: 0
|
x: 0
|
||||||
y: 0
|
y: 0
|
||||||
z: 0
|
z: 0
|
||||||
|
command: bs
|
||||||
list:
|
list:
|
||||||
- default
|
- default
|
@ -6,16 +6,14 @@ import net.DeltaWings.Nemoria.Main;
|
|||||||
|
|
||||||
public class Files {
|
public class Files {
|
||||||
|
|
||||||
|
private static Main main = Main.getInstance();
|
||||||
public static FileConfiguration getConfig(){
|
public static FileConfiguration getConfig(){
|
||||||
return Main.getInstance().getConfig();
|
return main.getConfig();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void saveFiles(){
|
public static void saveConfig() {
|
||||||
Main.getInstance().saveConfig();
|
main.saveConfig();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void yolo(){
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
@ -29,12 +29,13 @@ public class DelTP implements CommandExecutor {
|
|||||||
Files.getConfig().set("teleporteurs."+args[0]+".x", "");
|
Files.getConfig().set("teleporteurs."+args[0]+".x", "");
|
||||||
Files.getConfig().set("teleporteurs."+args[0]+".y", "");
|
Files.getConfig().set("teleporteurs."+args[0]+".y", "");
|
||||||
Files.getConfig().set("teleporteurs."+args[0]+".z", "");
|
Files.getConfig().set("teleporteurs."+args[0]+".z", "");
|
||||||
|
Files.getConfig().set("teleporteurs."+args[0]+".command", "");
|
||||||
Files.getConfig().set("teleporteurs."+args[0], "");
|
Files.getConfig().set("teleporteurs."+args[0], "");
|
||||||
p.sendMessage("teleporteur detruis !");
|
p.sendMessage("teleporteur detruis !");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Main.getInstance().saveConfig();
|
Files.saveConfig();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,11 +25,12 @@ public class SetTP implements CommandExecutor {
|
|||||||
Files.getConfig().set("teleporteurs."+args[0]+".x", p.getLocation().getBlockX());
|
Files.getConfig().set("teleporteurs."+args[0]+".x", p.getLocation().getBlockX());
|
||||||
Files.getConfig().set("teleporteurs."+args[0]+".y", p.getLocation().getBlockY());
|
Files.getConfig().set("teleporteurs."+args[0]+".y", p.getLocation().getBlockY());
|
||||||
Files.getConfig().set("teleporteurs."+args[0]+".z", p.getLocation().getBlockZ());
|
Files.getConfig().set("teleporteurs."+args[0]+".z", p.getLocation().getBlockZ());
|
||||||
p.sendMessage("Teleporteur crée");
|
Files.getConfig().set("teleporteurs."+args[0]+".command", "bs");
|
||||||
|
p.sendMessage("§bMenoria §> §cTeleporteur crée");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Main.getInstance().saveConfig();
|
Files.saveConfig();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -14,7 +14,8 @@ import net.minecraft.server.v1_10_R1.PacketPlayOutChat;
|
|||||||
|
|
||||||
public class ChatListener implements Listener {
|
public class ChatListener implements Listener {
|
||||||
|
|
||||||
@EventHandler(priority=EventPriority.HIGHEST)
|
//reste chat
|
||||||
|
/**@EventHandler(priority=EventPriority.HIGHEST)
|
||||||
public void onPlayerChat(AsyncPlayerChatEvent e){
|
public void onPlayerChat(AsyncPlayerChatEvent e){
|
||||||
String msg = MinecraftToJSON.main(e.getMessage(), e.getPlayer());
|
String msg = MinecraftToJSON.main(e.getMessage(), e.getPlayer());
|
||||||
e.setCancelled(true);
|
e.setCancelled(true);
|
||||||
@ -22,5 +23,5 @@ public class ChatListener implements Listener {
|
|||||||
PacketPlayOutChat packet = new PacketPlayOutChat(link);
|
PacketPlayOutChat packet = new PacketPlayOutChat(link);
|
||||||
((CraftPlayer) e.getPlayer()).getHandle().playerConnection.sendPacket(packet);
|
((CraftPlayer) e.getPlayer()).getHandle().playerConnection.sendPacket(packet);
|
||||||
System.out.println(e.getPlayer().getName()+" > "+e.getMessage());
|
System.out.println(e.getPlayer().getName()+" > "+e.getMessage());
|
||||||
}
|
}**/
|
||||||
}
|
}
|
@ -8,13 +8,15 @@ import net.DeltaWings.Nemoria.Main;
|
|||||||
import net.DeltaWings.Nemoria.API.Files;
|
import net.DeltaWings.Nemoria.API.Files;
|
||||||
|
|
||||||
public class PlayerPositionListener extends BukkitRunnable {
|
public class PlayerPositionListener extends BukkitRunnable {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
for(int a = 0; a<Files.getConfig() .getStringList("list").size(); a++){
|
for(int a = 0; a<Files.getConfig() .getStringList("list").size(); a++){
|
||||||
int x = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getStringList("list").get(a)+".x");
|
int x = Files.getConfig().getInt("teleporteurs."+Files.getConfig().getStringList("list").get(a)+".x");
|
||||||
int y = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getStringList("list").get(a)+".y");
|
int y = Files.getConfig().getInt("teleporteurs."+Files.getConfig().getStringList("list").get(a)+".y");
|
||||||
int z = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getStringList("list").get(a)+".z");
|
int z = Files.getConfig().getInt("teleporteurs."+Files.getConfig().getStringList("list").get(a)+".z");
|
||||||
String world = Files.getConfig() .getString("teleporteurs."+Files.getConfig() .getStringList("list").get(a)+".world");
|
String command = Files.getConfig().getString("teleporteurs."+Files.getConfig().getStringList("list").get(a)+".command");
|
||||||
|
String world = Files.getConfig().getString("teleporteurs."+Files.getConfig() .getStringList("list").get(a)+".world");
|
||||||
for(Player player : Bukkit.getServer().getOnlinePlayers()){
|
for(Player player : Bukkit.getServer().getOnlinePlayers()){
|
||||||
Boolean on;
|
Boolean on;
|
||||||
if(Files.getConfig() .isSet("players."+player.getName()+".on") == false){
|
if(Files.getConfig() .isSet("players."+player.getName()+".on") == false){
|
||||||
@ -40,16 +42,16 @@ public class PlayerPositionListener extends BukkitRunnable {
|
|||||||
}
|
}
|
||||||
if(Files.getConfig().getBoolean("players."+player.getName()+".on") == false){
|
if(Files.getConfig().getBoolean("players."+player.getName()+".on") == false){
|
||||||
if(on){
|
if(on){
|
||||||
//make player execute command //bs open Téléportation player
|
//make player execute command //bs open T?l?portation player
|
||||||
Bukkit.dispatchCommand(player, "bs téléportation");
|
Bukkit.dispatchCommand(player, command);
|
||||||
Files.getConfig().set("players."+player.getName()+".on", true);
|
Files.getConfig().set("players."+player.getName()+".on", true);
|
||||||
Files.getConfig().set("players."+player.getName()+".latest", Files.getConfig() .getStringList("list").get(a));
|
Files.getConfig().set("players."+player.getName()+".latest", Files.getConfig() .getStringList("list").get(a));
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
int lx = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".x");
|
int lx = Files.getConfig().getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".x");
|
||||||
int ly = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".y");
|
int ly = Files.getConfig().getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".y");
|
||||||
int lz = Files.getConfig() .getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".z");
|
int lz = Files.getConfig().getInt("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".z");
|
||||||
String lworld = Files.getConfig() .getString("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".world");
|
String lworld = Files.getConfig().getString("teleporteurs."+Files.getConfig() .getString("players."+player.getName()+".latest")+".world");
|
||||||
if(player.getLocation().getWorld().getName().equalsIgnoreCase(lworld)){
|
if(player.getLocation().getWorld().getName().equalsIgnoreCase(lworld)){
|
||||||
if(player.getLocation().getBlockX() == lx){
|
if(player.getLocation().getBlockX() == lx){
|
||||||
if(player.getLocation().getBlockY() == ly){
|
if(player.getLocation().getBlockY() == ly){
|
||||||
@ -67,8 +69,9 @@ public class PlayerPositionListener extends BukkitRunnable {
|
|||||||
}else{
|
}else{
|
||||||
Files.getConfig().set("players."+player.getName()+".on", false);
|
Files.getConfig().set("players."+player.getName()+".on", false);
|
||||||
}
|
}
|
||||||
|
Files.saveConfig();
|
||||||
}
|
}
|
||||||
Main.getInstance().saveConfig();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,6 @@ import org.bukkit.plugin.java.JavaPlugin;
|
|||||||
import net.DeltaWings.Nemoria.Commands.DelTP;
|
import net.DeltaWings.Nemoria.Commands.DelTP;
|
||||||
import net.DeltaWings.Nemoria.Commands.PlayerInfos;
|
import net.DeltaWings.Nemoria.Commands.PlayerInfos;
|
||||||
import net.DeltaWings.Nemoria.Commands.SetTP;
|
import net.DeltaWings.Nemoria.Commands.SetTP;
|
||||||
import net.DeltaWings.Nemoria.Listeners.ChatListener;
|
|
||||||
import net.DeltaWings.Nemoria.Listeners.PlayerPositionListener;
|
import net.DeltaWings.Nemoria.Listeners.PlayerPositionListener;
|
||||||
import net.milkbowl.vault.economy.Economy;
|
import net.milkbowl.vault.economy.Economy;
|
||||||
|
|
||||||
@ -28,9 +27,8 @@ public class Main extends JavaPlugin implements Listener{
|
|||||||
//creation de l'instance
|
//creation de l'instance
|
||||||
instance = this;
|
instance = this;
|
||||||
main = Main.getInstance();
|
main = Main.getInstance();
|
||||||
setupEconomy();
|
|
||||||
//create chatlistener
|
//create chatlistener
|
||||||
getServer().getPluginManager().registerEvents(new ChatListener(), this);
|
/**getServer().getPluginManager().registerEvents(new ChatListener(), this);**/
|
||||||
Bukkit.getScheduler().scheduleSyncRepeatingTask(this, new PlayerPositionListener(),20,20);
|
Bukkit.getScheduler().scheduleSyncRepeatingTask(this, new PlayerPositionListener(),20,20);
|
||||||
getCommand("PlayerInfos").setExecutor(new PlayerInfos());
|
getCommand("PlayerInfos").setExecutor(new PlayerInfos());
|
||||||
getCommand("SetTP").setExecutor(new SetTP());
|
getCommand("SetTP").setExecutor(new SetTP());
|
||||||
@ -46,7 +44,8 @@ public class Main extends JavaPlugin implements Listener{
|
|||||||
//plugin disabled
|
//plugin disabled
|
||||||
System.out.println("[Menoria]Plugin disabled");
|
System.out.println("[Menoria]Plugin disabled");
|
||||||
}
|
}
|
||||||
private boolean setupEconomy()
|
//reste chat
|
||||||
|
/**private boolean setupEconomy()
|
||||||
{
|
{
|
||||||
RegisteredServiceProvider<Economy> economyProvider = getServer().getServicesManager().getRegistration(net.milkbowl.vault.economy.Economy.class);
|
RegisteredServiceProvider<Economy> economyProvider = getServer().getServicesManager().getRegistration(net.milkbowl.vault.economy.Economy.class);
|
||||||
if (economyProvider != null) {
|
if (economyProvider != null) {
|
||||||
@ -54,7 +53,7 @@ public class Main extends JavaPlugin implements Listener{
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (eco != null);
|
return (eco != null);
|
||||||
}
|
}**/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user