ft* inz_server_plugin ta src ) I
t> 13 Project ▼
2* ▼ fe* inz_server_plugin ~/ldeaProjects/inz_serv«
► ta .idea src
▼ ta main
▼ tajava
▼ ta pl.otlet.inz_server_plugin O ApiConnect 0 CreateWebAccount 0 Depo sit
0 Loot 0 Main
▼ i|resources
H plugin.yml
► ta test ▼ tatarget
► ta classes
► ta generated-sources
► ta maven-archiver
► ta maven-status
|| inz_server_plugin-1.0-SNAPSHOT.jar O .gitignore
inz_server_plugin.iml m pom.xml
► lilii External Libraries
► Scratches and Consoles
▼ ijj, inz_server_plugin
▼ ta Lifecycle
i> clean validate l> compile O test l> package <x verify $ install O site $ deploy ► ta Plugins
▼ iifi Dependencies
► lilii org.spigotmc:spigot-api:1.13.2-R0.1-SNA
► lilii org.apache.httpcomponents:httpclient:4. lilii org.apache.httpcomponents:httpcore:4.*
# Ant Build £ Maven f))) Database
inz_server_plugin [~/ldeaProjects/inz_server_plugin] - .../src/main/java/pl/otlet/inz_server_plugin/CreateWebAccount.java [inz_server_plugin]
I main ) ta java ta pl ta otlet ; ta inz_server_plugin > 0 CreateWebAccount
^ Add Configuration... Git: / ✓ O t) ta n O,
0 Loot.java 0 CreateWebAccount.java 0 ApiConnect.java |
Maven | |
package pl.otlet.inz_server_plugin; 2 |
” 5 k i. + |
w # o n t > |
] import
public class CreateWebAccount implements CommandExecutor { private FileConfiguration config; private StringU help = {
ChatColor.RED + JmU online mÓZl dane:",
ChatColor.RED + email M$&2",
ChatColor.YELLOW + "Email:" + ChatColor.KfD + " atet e-mail, Kto toto
ChatColo r.YELLOW + i 2:" + ChatColo r.RED + " J&gię do KSG&3 online, gl
private String two_different_passwords = ChatColor.RED + "Ale być dwa iSKAg sani
private String bad_email = ChatColor.RED + "No *&&£§, ale pgjJ&i nam MCKS e-mail, a nie:
private static finał Pattern VALID_EMAIL_ADDRESS_REGEX =
Pattern.compilei regex: "~[A-Z0-9._%+-]+<a[A-Z0-9.-]+\\. [A-ZK2,6}$", Pattern.CASE_INSENST>
private static boolean validate(String emailStr) {
Matcher matcher = VALID_EMAIL_ADDRESS_REGEX.matcher(emailStr); return matcher.find();
}
CreateWebAccount() {
Plugin plugin = Bukkit.getServer().getPluginManager().getPlugin( s: "inz_server_plugin"); if (plugin != nuli)
this.config = plugin.getConfig();
else
getLoggerO.warning( msg: "Nie plugin! Coś się >;
>
§
@Override|
public boolean onCommand(CommandSender sender, Command cmd, String label, StringU args) { if (!validateArgs(sender, args))
return false;
String email = args[0];
String password = argsll];
getLogger().info(cmd.toSt ring());
CreateWebAccount onCommand()
a Terminal 0 Event Log 46:14 LF i UTF-8 i 4 spaces i Git: master i ^
i= 6: TODO 9: Version Control
D 6 Files Updated // View (a minutę ago)
<*>
\
o