Cheap custom Plugins Dev

Status
This thread has been locked.

mobieljoy

Feedback score
0
Posts
6
Reactions
0
Resources
0
Cheap plugin developement


I am offering to make small plugins for little. I imagine this being great for small servers who don't have a lot to spend. I started coding about 4 years ago but I quit for a while. If you are looking for some plugins made, contact me on skype: skypenaam3211

We can discuss if, when and for how much if you add me. I am willing to adjust if you're budget is really low depending on the type of plugin.

Code:
package com.mobieljoy;

import java.util.logging.Logger;

import org.bukkit.Bukkit;
import org.bukkit.ChatColor;
import org.bukkit.Location;
import org.bukkit.World;
import org.bukkit.command.Command;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Item;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.block.BlockBreakEvent;
import org.bukkit.event.block.BlockPlaceEvent;
import org.bukkit.event.player.PlayerDropItemEvent;
import org.bukkit.event.player.PlayerJoinEvent;
import org.bukkit.event.player.PlayerPickupItemEvent;
import org.bukkit.plugin.java.JavaPlugin;

public class MainClass extends JavaPlugin implements Listener{
   
    public static Logger logger = Logger.getLogger("Minecraft");
   
    @Override
    public void onEnable() {
        logger.info("[MobieljoyHub] Plugin Enabled!");
        Bukkit.getServer().getPluginManager().registerEvents(this, this);
    }
   
    @Override
    public void onDisable() {
        logger.info("[MobieljoyHub] Plugin Disabled!");
    }
   
    @Override
    public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) {
       
        Player player = (Player) sender;
       
        if(label.equalsIgnoreCase("jhub")){
            player.sendMessage(ChatColor.WHITE + "[" + ChatColor.RED + "Mobieljoyhub" + ChatColor.WHITE + "] " + ChatColor.GRAY + "Mobieljoy hub plugin v1.0 is up and running!");
        }
        return super.onCommand(sender, cmd, label, args);
    }
   
    @EventHandler
    public void onjoin(PlayerJoinEvent event){
       
        Player player = event.getPlayer();
        World world = player.getWorld();
        Location spawn = new Location(world, 271.5, 89, 340.5, 180, 0);
       
        player.teleport(spawn);
    }
   
    @EventHandler
    public void onplace(BlockPlaceEvent event){
        Player player = event.getPlayer();
       
        if(player.isOp()){
            return;
        }
        else{
            event.setCancelled(true);
            player.sendMessage(ChatColor.WHITE + "[" + ChatColor.BLUE + "Server" + ChatColor.WHITE + "] " + ChatColor.RED + "You don't have permission to do that!");
        }
    }
   
    @EventHandler
    public void onbreak(BlockBreakEvent event){
        Player player = event.getPlayer();
       
        if(player.isOp()){
            return;
        }
        else{
            event.setCancelled(true);
            player.sendMessage(ChatColor.WHITE + "[" + ChatColor.BLUE + "Server" + ChatColor.WHITE + "] " + ChatColor.RED + "You don't have permission to do that!");
        }
    }
   
    @EventHandler
    public void ondrop(PlayerDropItemEvent event){
        Player player = event.getPlayer();
       
        if(player.isOp()){
            return;
        }
        else{
            event.setCancelled(true);
            player.sendMessage(ChatColor.WHITE + "[" + ChatColor.BLUE + "Server" + ChatColor.WHITE + "] " + ChatColor.RED + "You don't have permission to do that!");
        }
    }
   
    @EventHandler
    public void onpickup(PlayerPickupItemEvent event){
        Player player = event.getPlayer();
        Item item = event.getItem();
       
        if(player.isOp()){
            return;
        }
        else{
            event.setCancelled(true);
            player.sendMessage(ChatColor.WHITE + "[" + ChatColor.BLUE + "Server" + ChatColor.WHITE + "] " + ChatColor.RED + "You don't have permission to do that!");
            item.remove();
        }
    }

}

Here is a really simple plugin I made for a Lobby server. It prevents players from building and breaking blocks if they are not OP and it teleports you to the spawn location of my server. It also has one command to show you the version of the plugin. This is all custom made without a config file so it is really easy to use. I can however use config files if needed.

I hope to talk to you on skype.
 
PebbleHost
High performance, consistent uptime and fast support. Minecraft hosting that just works.

Eric

Software Engineer
Supreme
Feedback score
14
Posts
1,760
Reactions
1,648
Resources
1
You coded for 4 years and made that?

Sorry, that's bullshit.
 

SystemUpdate

Freelance Developer
Premium
Feedback score
4
Posts
119
Reactions
128
Resources
0
I started coding about 4 years ago but I quit for a while.
*Programs for a month*
*Quits*
- 4 years later
"Hello, I have four years experience in the Java & Bukkit worlds!"

You conventions are spot on, btw! Good job, since many struggle with that.
 

Eric

Software Engineer
Supreme
Feedback score
14
Posts
1,760
Reactions
1,648
Resources
1
*Programs for a month*
*Quits*
- 4 years later
"Hello, I have four years experience in the Java & Bukkit worlds!"

You conventions are spot on, btw! Good job, since many struggle with that.
Java conventions don't particularly matter, it goes through a compiler at the end of the day. Wouldn't say it's not good practice, but it's just picky.

The kid is bullshitting though, right?[DOUBLEPOST=1500767156][/DOUBLEPOST]
*Programs for a month*
*Quits*
- 4 years later
"Hello, I have four years experience in the Java & Bukkit worlds!"

You conventions are spot on, btw! Good job, since many struggle with that.
Just realised his main class is literally called "MainClass". Oops.
 

mobieljoy

Feedback score
0
Posts
6
Reactions
0
Resources
0
Lol I told you it is a simple plugin and this is just a small example.
 

Kuzni

If you signed up after 2016 don't diss me thx
Supreme
Feedback score
12
Posts
1,688
Reactions
950
Resources
0
Lol I told you it is a simple plugin and this is just a small example.

I know you said this was a simple plugin but to save time you should use colour codes instead of writing out ChatColor.RED every time.
 

Tyler

Developer
Supreme
Feedback score
14
Posts
2,589
Reactions
2,238
Resources
0
If you had 4 years experience, you should know you don't have to use the logger class to tell console your plugin has been enabled, you would use proper naming conventions (your event methods), you wouldn't use useless else statements, instead of if player is op return, else blah blah, you could simple do if ! player is op (to simplify) then blah blah. You even declare Logger as static and you have one class. To be honest I don't really know if naming your main class 'Main' is bad practice or not, but I see more new developers doing it, and I always just name it the name of my project, like if I was making a plugin called 'CoolLobby', I'd name my main class 'CoolLobby'.
 
Status
This thread has been locked.
Top