Thread: Developer for Hire - Services - Content - Bugs - Interfaces - Considerate Prices

Page 1 of 4 123 ... LastLast
Results 1 to 10 of 36
  1. #1 Developer for Hire - Services - Content - Bugs - Interfaces - Considerate Prices 
    Registered Member
    Dexter Morgan's Avatar
    Join Date
    Nov 2008
    Age
    16
    Posts
    4,301
    Thanks given
    871
    Thanks received
    626
    Rep Power
    2734
    Quote Originally Posted by i dds you View Post
    Just a heads up for everyone: had an impostor add me earlier so just make sure you PM dexter on the forums and check the discord #

    Impostor Discord name:
    Dexter Morgan#6947
    Due to the imposter, I will not ask for money first.


    Contact:


    Make sure you are contacting the right person
    Make sure the discord number is correct.
    I am not responsible for any loses.
    Any uncertainty verify through PM on Rune-Server
    Right Discord: Not Dexter Morgan#1201

    Quote Originally Posted by i dds you View Post
    Just a heads up for everyone: had an impostor add me earlier so just make sure you PM dexter on the forums and check the discord #

    Impostor Discord name:
    Dexter Morgan#6947




    Hello I am interested in being hired as a full time developer for your server. Meanwhile, I am able to offer some services.


    Bio
    I am a self taught, dedicated, motivated, programmer. I have self taught Java so I have no real life qualifications.
    I am able to offer 4- 8 hours a day. Possibly more depending on the payment
    I can write almost anything from scratch such as skills, minigames, quests, bosses, etc.
    I can create custom interfaces without a problem

    Most recognized servers I have worked for are [Only registered and activated users can see links. ], [Only registered and activated users can see links. ], and most recently [Only registered and activated users can see links. ]

    Spoiler for Interface Work:

    Spoiler for Interfaces for Fury-PS (15 interfaces):











    Spoiler for Interfaces for Imagine-PS (7 Interfaces):










    Spoiler for Some Media:

    Most recent preview of work done for GrinderScape



    Example of code
    Spoiler for Code:

    Code:
    package com.elvarg.game.content.sanction;
    
    import java.util.Date;
    
    import com.elvarg.game.content.sanction.SanctionManager.Sanctions;
    import com.elvarg.game.entity.impl.player.Player;
    
    /**
     * Represents a sanction given to a player
     * 
     * @author 2012
     *
     */
    public class Sanction {
    
    	/**
    	 * The name of the player
    	 */
    	private String name;
    
    	/**
    	 * The ip address
    	 */
    	private String IPAddress;
    
    	/**
    	 * The mac address
    	 */
    	private String macAddress;
    
    	/**
    	 * The sn address
    	 */
    	private String snAddress;
    
    	/**
    	 * The hd address
    	 */
    	private String hdAddress;
    
    	/**
    	 * The rule broken
    	 */
    	private int ruleBroken;
    
    	/**
    	 * The description
    	 */
    	private String description;
    
    	/**
    	 * Who punished
    	 */
    	private String sanctionedBy;
    
    	/**
    	 * The date
    	 */
    	private String date;
    
    	/**
    	 * The duration of this sanction
    	 */
    	private long duration;
    
    	/**
    	 * When this sanction expires
    	 */
    	private long expiry;
    
    	/**
    	 * The sanction
    	 */
    	private Sanctions sanction;
    
    	/**
    	 * Represents a sanction
    	 * 
    	 * @param name
    	 *            the name
    	 * @param IPAddress
    	 *            the ip address
    	 * @param macAddress
    	 *            the mac address
    	 * @param snAddress
    	 *            the sn address
    	 * @param hdAddress
    	 *            the hd address
    	 */
    	public Sanction(Player player, Player staff, Sanctions sanction) {
    		this.setName(player.getUsername());
    		this.setIPAddress(player.getHostAddress());
    		this.setMacAddress(player.getMacAddress());
    		this.setSnAddress(player.getSnAddress());
    		this.setHdAddress(player.getHdSerialNumber());
    		this.setRuleBroken(staff.getSanction().getRuleSelected());
    		this.setSanctionedBy(staff.getUsername());
    		this.setDate(SanctionManager.SANCTION_FORMAT.format(new Date()).toString());
    		this.setDuration(staff.getSanction().getDurationSelected());
    		this.setExpiry(sanction.getExpiry());
    		this.setSanction(sanction);
    	}
    
    	/**
    	 * Sets the name
    	 *
    	 * @return the name
    	 */
    	public String getName() {
    		return name;
    	}
    
    	/**
    	 * Sets the name
    	 * 
    	 * @param name
    	 *            the name
    	 */
    	public void setName(String name) {
    		this.name = name;
    	}
    
    	/**
    	 * Sets the iPAddress
    	 *
    	 * @return the iPAddress
    	 */
    	public String getIPAddress() {
    		return IPAddress;
    	}
    
    	/**
    	 * Sets the iPAddress
    	 * 
    	 * @param iPAddress
    	 *            the iPAddress
    	 */
    	public void setIPAddress(String iPAddress) {
    		IPAddress = iPAddress;
    	}
    
    	/**
    	 * Sets the macAddress
    	 *
    	 * @return the macAddress
    	 */
    	public String getMacAddress() {
    		return macAddress;
    	}
    
    	/**
    	 * Sets the macAddress
    	 * 
    	 * @param macAddress
    	 *            the macAddress
    	 */
    	public void setMacAddress(String macAddress) {
    		this.macAddress = macAddress;
    	}
    
    	/**
    	 * Sets the snAddress
    	 *
    	 * @return the snAddress
    	 */
    	public String getSnAddress() {
    		return snAddress;
    	}
    
    	/**
    	 * Sets the snAddress
    	 * 
    	 * @param snAddress
    	 *            the snAddress
    	 */
    	public void setSnAddress(String snAddress) {
    		this.snAddress = snAddress;
    	}
    
    	/**
    	 * Sets the hdAddress
    	 *
    	 * @return the hdAddress
    	 */
    	public String getHdAddress() {
    		return hdAddress;
    	}
    
    	/**
    	 * Sets the hdAddress
    	 * 
    	 * @param hdAddress
    	 *            the hdAddress
    	 */
    	public void setHdAddress(String hdAddress) {
    		this.hdAddress = hdAddress;
    	}
    
    	/**
    	 * Sets the ruleBroken
    	 *
    	 * @return the ruleBroken
    	 */
    	public int getRuleBroken() {
    		return ruleBroken;
    	}
    
    	/**
    	 * Sets the ruleBroken
    	 * 
    	 * @param ruleBroken
    	 *            the ruleBroken
    	 */
    	public void setRuleBroken(int ruleBroken) {
    		this.ruleBroken = ruleBroken;
    	}
    
    	/**
    	 * Sets the description
    	 *
    	 * @return the description
    	 */
    	public String getDescription() {
    		return description;
    	}
    
    	/**
    	 * Sets the description
    	 * 
    	 * @param description
    	 *            the description
    	 */
    	public void setDescription(String description) {
    		this.description = description;
    	}
    
    	/**
    	 * Sets the sanctionedBy
    	 *
    	 * @return the sanctionedBy
    	 */
    	public String getSanctionedBy() {
    		return sanctionedBy;
    	}
    
    	/**
    	 * Sets the sanctionedBy
    	 * 
    	 * @param sanctionedBy
    	 *            the sanctionedBy
    	 */
    	public void setSanctionedBy(String sanctionedBy) {
    		this.sanctionedBy = sanctionedBy;
    	}
    
    	/**
    	 * Sets the date
    	 *
    	 * @return the date
    	 */
    	public String getDate() {
    		return date;
    	}
    
    	/**
    	 * Sets the date
    	 * 
    	 * @param date
    	 *            the date
    	 */
    	public void setDate(String date) {
    		this.date = date;
    	}
    
    	/**
    	 * Sets the duration
    	 *
    	 * @return the duration
    	 */
    	public long getDuration() {
    		return duration;
    	}
    
    	/**
    	 * Sets the duration
    	 * 
    	 * @param duration
    	 *            the duration
    	 */
    	public void setDuration(long duration) {
    		this.duration = duration;
    	}
    
    	/**
    	 * Sets the expiry
    	 *
    	 * @return the expiry
    	 */
    	public long getExpiry() {
    		return expiry;
    	}
    
    	/**
    	 * Sets the expiry
    	 * 
    	 * @param expiry
    	 *            the expiry
    	 */
    	public void setExpiry(long expiry) {
    		this.expiry = expiry;
    	}
    
    	/**
    	 * Sets the sanction
    	 *
    	 * @return the sanction
    	 */
    	public Sanctions getSanction() {
    		return sanction;
    	}
    
    	/**
    	 * Sets the sanction
    	 * 
    	 * @param sanction the sanction
    	 */
    	public void setSanction(Sanctions sanction) {
    		this.sanction = sanction;
    	}
    }
    Code:
    package com.elvarg.game.content.sanction;
    
    import java.io.File;
    import java.io.FileReader;
    import java.io.FileWriter;
    import java.nio.file.Path;
    import java.nio.file.Paths;
    import java.text.SimpleDateFormat;
    import java.util.ArrayList;
    import java.util.logging.Level;
    
    import com.elvarg.Server;
    import com.elvarg.game.entity.impl.player.Player;
    import com.google.gson.Gson;
    import com.google.gson.GsonBuilder;
    import com.google.gson.JsonObject;
    import com.google.gson.JsonParser;
    
    /**
     * Handles the sanctions given to player
     * 
     * @author 2012
     *
     */
    public class SanctionManager {
    
    	/**
    	 * The file location
    	 */
    	private static final String LOCATION = "./data/sanctions/sanctions.json";
    
    	/**
    	 * The date format
    	 */
    	public static final SimpleDateFormat SANCTION_FORMAT = new SimpleDateFormat("dd/MM/yyyyy hh:mm:ss");
    
    	/**
    	 * The sanctions
    	 */
    	public static ArrayList<Sanction> sanctions = new ArrayList<Sanction>();
    
    	/**
    	 * The black marks
    	 */
    	private int blackMarks;
    
    	/**
    	 * The duration selected in hours
    	 */
    	private int durationSelected;
    
    	/**
    	 * The rule selected
    	 */
    	private int ruleSelected;
    
    	/**
    	 * The sanctions
    	 */
    	public enum Sanctions {
    		JAIL(SanctionSeverity.LOW, -1),
    
    		MUTE(SanctionSeverity.MEDIUM, 7),
    
    		BAN(SanctionSeverity.MEDIUM, 21),
    
    		IP_MUTE(SanctionSeverity.HIGH, 28),
    
    		IP_BAN(SanctionSeverity.HIGH, 56),
    
    		MAC_BAN(SanctionSeverity.EXTREME, 90),
    
    		SN_BAN(SanctionSeverity.EXTREME, 90),
    
    		HD_BAN(SanctionSeverity.EXTREME, 90),
    
    		;
    
    		/**
    		 * The severity
    		 */
    		private SanctionSeverity severity;
    
    		/**
    		 * How many days to expire
    		 */
    		private int expiry;
    
    		/**
    		 * Represents a sanction
    		 * 
    		 * @param severity
    		 *            the severity
    		 */
    		Sanctions(SanctionSeverity severity, int expiry) {
    			this.setSeverity(severity);
    			this.setExpiry(expiry);
    		}
    
    		/**
    		 * Sets the severity
    		 *
    		 * @return the severity
    		 */
    		public SanctionSeverity getSeverity() {
    			return severity;
    		}
    
    		/**
    		 * Sets the severity
    		 * 
    		 * @param severity
    		 *            the severity
    		 */
    		public void setSeverity(SanctionSeverity severity) {
    			this.severity = severity;
    		}
    
    		/**
    		 * Sets the expiry
    		 *
    		 * @return the expiry
    		 */
    		public int getExpiry() {
    			return expiry;
    		}
    
    		/**
    		 * Sets the expiry
    		 * 
    		 * @param expiry
    		 *            the expiry
    		 */
    		public void setExpiry(int expiry) {
    			this.expiry = expiry;
    		}
    	}
    
    	/**
    	 * The severity of the punishment
    	 */
    	public enum SanctionSeverity {
    		/*
    		 * Low punishments like jail
    		 */
    		LOW,
    		/*
    		 * Medium punishments like mute
    		 */
    		MEDIUM,
    		/*
    		 * High punishment like ban
    		 */
    		HIGH,
    		/*
    		 * High punishment like ipban/mac ban
    		 */
    		EXTREME,
    	}
    
    
    	/**
    	 * Checking if player is muted
    	 * 
    	 * @param player
    	 *            the player
    	 * @return player muted
    	 */
    	public static boolean isMuted(Player player) {
    		/*
    		 * Loop through the sanctions
    		 */
    		for (Sanction san : sanctions) {
    			/*
    			 * Invalid
    			 */
    			if (san == null) {
    				continue;
    			}
    			/*
    			 * Muted
    			 */
    			if (san.getSanction().equals(Sanctions.MUTE) || san.getSanction().equals(Sanctions.IP_MUTE)) {
    				/*
    				 * Found player
    				 */
    				if (san.getName().equals(player.getUsername())) {
    					return true;
    				}
    			}
    		}
    		return false;
    	}
    
    	/**
    	 * Loading
    	 */
    	public static void load() {
    		Path path = Paths.get(LOCATION);
    		File file = path.toFile();
    		if (!file.exists()) {
    			return;
    		}
    		try (FileReader fileReader = new FileReader(file)) {
    			JsonParser fileParser = new JsonParser();
    			Gson builder = new GsonBuilder().create();
    			JsonObject reader = (JsonObject) fileParser.parse(fileReader);
    
    			if (reader.has("sanctions")) {
    				Sanction[] string = builder.fromJson(reader.get("sanctions").getAsJsonArray(), Sanction[].class);
    				for (Sanction l : string) {
    					sanctions.add(l);
    				}
    			}
    		} catch (Exception e) {
    			e.printStackTrace();
    		}
    	}
    
    	/**
    	 * Saving
    	 */
    	public static void save() {
    		Path path = Paths.get(LOCATION);
    		File file = path.toFile();
    		file.getParentFile().setWritable(true);
    
    		if (!file.getParentFile().exists()) {
    			try {
    				file.getParentFile().mkdirs();
    			} catch (SecurityException e) {
    			}
    		}
    		try (FileWriter writer = new FileWriter(file)) {
    
    			Gson builder = new GsonBuilder().setPrettyPrinting().create();
    			JsonObject object = new JsonObject();
    
    			object.add("sanctions", builder.toJsonTree(sanctions));
    
    			writer.write(builder.toJson(object));
    			writer.close();
    
    		} catch (Exception e) {
    			Server.getLogger().log(Level.WARNING, "An error has occured while saving a server settings file!", e);
    		}
    	}
    
    	/**
    	 * Sets the blackMarks
    	 *
    	 * @return the blackMarks
    	 */
    	public int getBlackMarks() {
    		return blackMarks;
    	}
    
    	/**
    	 * Sets the blackMarks
    	 * 
    	 * @param blackMarks
    	 *            the blackMarks
    	 */
    	public void setBlackMarks(int blackMarks) {
    		this.blackMarks = blackMarks;
    	}
    
    	/**
    	 * Sets the durationSelected
    	 *
    	 * @return the durationSelected
    	 */
    	public int getDurationSelected() {
    		return durationSelected;
    	}
    
    	/**
    	 * Sets the durationSelected
    	 * 
    	 * @param durationSelected
    	 *            the durationSelected
    	 */
    	public void setDurationSelected(int durationSelected) {
    		this.durationSelected = durationSelected;
    	}
    
    	/**
    	 * Sets the ruleSelected
    	 *
    	 * @return the ruleSelected
    	 */
    	public int getRuleSelected() {
    		return ruleSelected;
    	}
    
    	/**
    	 * Sets the ruleSelected
    	 * 
    	 * @param ruleSelected
    	 *            the ruleSelected
    	 */
    	public void setRuleSelected(int ruleSelected) {
    		this.ruleSelected = ruleSelected;
    	}
    }


    Restrictions:
    1. Not interested in doing data related work such as loading newer OSRS data.
    2. Not interested in technical difficulties such as not able to load cache, connection issues, etc.

    Expectations:

    5 days availability
    Up to 6-8 hours, overtime available at a higher rate
    $9+ an hour, negotiable.
    Can do paid per content.
    Can do weekly payment.
    All weekly payment will be done on a specified day through bank transfer or paypal.
    Not interested in monthly payment
    Expect payment as soon as possible. Best on the day or by schedule. No late payments or promises.

    Method/Approach (services):
    1. Gather a list of things you want done
    2. We estimate price and time
    3. In expensive cases, I expect a percentage of the payment upfront otherwise the whole payment comes first.

    Agreement:
    1. If, for whatever reason, I am not able to carry out paid work. Any outstanding amount paid which hasn't been used, I am obligated to work for you until that amount is resolved

    2. Any content I create, which has been paid for, and in future, bugs appear, these bugs are free to fix and will never be charged for.

    3. Please understand that an estimation is only an estimation, sometimes, it may take longer than expected. (Due to in real life situations, changes in availability, unsuspected occurrences, unexpected bugs and required time for debug)

    4. (Services only) I will not redistribute any source code from your source, or any code written by me for you which has been paid for. Unpaid work means it's in my ownership and I'm free to do as I wish. Vice versa, you aren't to release, redistribute, or sell any of my code individually.

    5. (Full time only) If being hired full time, anywhere from 0+ hours, a percentage of the payment, if not the full, is expected before starting. This is for protection.



    Vouches:
    Spoiler for Vouches (15):

    Quote Originally Posted by Stanaveli View Post
    Vouch, nigga knows what hes doing
    Goodluck with your services bro.
    Quote Originally Posted by Joseph69 View Post
    This guy is the best, very high quality and I would recommend him to anyone!
    Quote Originally Posted by T.N.T View Post
    Vouch for dexter, fast and reliable.
    I highly recommend using him
    Quote Originally Posted by Mack View Post
    Vouch for Dexter. Overall great programmer & trustworthy being.
    Quote Originally Posted by Kurdz View Post
    Vouched, reliable service works hard.
    Quote Originally Posted by Feature Marski View Post
    Vouch - Dexter has done multiple services for me, very quick and professional. Will be back for more
    Quote Originally Posted by zukke View Post
    vouch
    Quote Originally Posted by Gang View Post
    Dexter was working with me on Cendancy a while ago.
    it's definitly the go to guy in terms of rsps dev , Vouch.
    Quote Originally Posted by Unzy View Post
    Whoever works with a registered gang member, like gang, I vouch for.
    Quote Originally Posted by Aboo View Post
    Vouch; work is good
    Quote Originally Posted by Azeem View Post
    I know him from emulous, vouch.
    Glws mate
    Quote Originally Posted by Thrallix View Post
    Hired dexter years ago, vouch.
    Quote Originally Posted by Hank View Post
    Vouch for Dexter
    Quote Originally Posted by Bodih View Post
    Vouch for dexter, worked with him quite a bit off and on the past couple years.
    Quote Originally Posted by RS Wiki View Post
    Should add Summoning and a cheap version of dungeoneering.

    Vouch4dex











    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  2. Thankful user:


  3. #2  
    Donator

    zukke's Avatar
    Join Date
    Aug 2017
    Posts
    229
    Thanks given
    76
    Thanks received
    70
    Rep Power
    90
    vouch
    Reply With Quote  
     

  4. Thankful user:


  5. #3  
    Registered Gangster

    Gang's Avatar
    Join Date
    Nov 2013
    Posts
    675
    Thanks given
    141
    Thanks received
    313
    Rep Power
    5000
    Dexter was working with me on Cendancy a while ago.

    it's definitly the go to guy in terms of rsps dev , Vouch.
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  6. Thankful user:


  7. #4  
    Registered Gangster

    Unzy's Avatar
    Join Date
    Feb 2017
    Posts
    698
    Thanks given
    0
    Thanks received
    263
    Rep Power
    3269
    Quote Originally Posted by Gang View Post
    Dexter was working with me on Cendancy a while ago.

    it's definitly the go to guy in terms of rsps dev , Vouch.
    Whoever works with a registered gang member, like gang, I vouch for.
    Gang
    Reply With Quote  
     

  8. #5  
    Registered Member

    Join Date
    Jul 2009
    Posts
    503
    Thanks given
    149
    Thanks received
    137
    Rep Power
    554
    Lol not to be negative but

    - No freelance or services available.
    - Can do paid per content.

    You should charge a lot more then $80 min/week min, working 4 hours min a day brings you to $2.85 hourly. Not doing the work thou but just a suggestion

    Vouch; work is good
    Reply With Quote  
     

  9. #6  
    Donator

    zukke's Avatar
    Join Date
    Aug 2017
    Posts
    229
    Thanks given
    76
    Thanks received
    70
    Rep Power
    90
    Quote Originally Posted by Aboo View Post
    Lol not to be negative but

    - No freelance or services available.
    - Can do paid per content.

    You should charge a lot more then $80 min/week min, working 4 hours min a day brings you to $2.85 hourly. Not doing the work thou but just a suggestion

    Vouch; work is good
    its defo cheap af, but u know what, better be cheap and get more orders etc or wait couple months for some good contract. (probl making more with being cheap but 80 bucks for week is way too low).
    Reply With Quote  
     

  10. Thankful user:


  11. #7  
    Donator


    Join Date
    Oct 2012
    Posts
    4,677
    Thanks given
    1,672
    Thanks received
    1,073
    Rep Power
    1381
    10$ hour, most people charge 15$. So 4 hours a day by 5 work days. Easy 200$ week.
    Quote Originally Posted by Velocity View Post
    i'd love to get called in the middle of the night just to hear an indian voice whisper "the nulls are back friend, how i fix"
    Reply With Quote  
     

  12. Thankful user:


  13. #8  
    What about it?

    Tyrant's Avatar
    Join Date
    Jul 2013
    Age
    19
    Posts
    1,446
    Thanks given
    597
    Thanks received
    339
    Rep Power
    628
    I dont personally know you but by the code shown I'm not really impressed. Interface design is quite amateur, though thats just the design aspect. Goodluck tho





    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  14. Thankful user:


  15. #9  
    Registered Member
    Dexter Morgan's Avatar
    Join Date
    Nov 2008
    Age
    16
    Posts
    4,301
    Thanks given
    871
    Thanks received
    626
    Rep Power
    2734
    Quote Originally Posted by Tyrant View Post
    I dont personally know you but by the code shown I'm not really impressed. Interface design is quite amateur, though thats just the design aspect. Goodluck tho
    Thank you. Perhaps you could point me in the right direction in private message and explain a few things I could do better
    Reply With Quote  
     

  16. #10  
    Registered Gangster

    Gang's Avatar
    Join Date
    Nov 2013
    Posts
    675
    Thanks given
    141
    Thanks received
    313
    Rep Power
    5000
    Quote Originally Posted by Tyrant View Post
    I dont personally know you but by the code shown I'm not really impressed. Interface design is quite amateur, though thats just the design aspect. Goodluck tho
    Recoded it for U , are you impressed now ?
    Code:
    /*
     @author
    
    ________                   __                    _____                                    
    \______ \   ____ ___  ____/  |_  ___________    /     \   ___________  _________    ____  
     |    |  \_/ __ \\  \/  /\   __\/ __ \_  __ \  /  \ /  \ /  _ \_  __ \/ ___\__  \  /    \ 
     |    `   \  ___/ >    <  |  | \  ___/|  | \/ /    Y    (  <_> )  | \/ /_/  > __ \|   |  \
    /_______  /\___  >__/\_ \ |__|  \___  >__|    \____|__  /\____/|__|  \___  (____  /___|  /
            \/     \/      \/           \/                \/            /_____/     \/     \/ 
    */
    
    
    package com.elvarg.game.content.sanction;
    
    import java.io.File;
    import java.io.FileReader;
    import java.io.FileWriter;
    import java.nio.file.Path;
    import java.nio.file.Paths;
    import java.text.SimpleDateFormat;
    import java.util.ArrayList;
    import java.util.logging.Level;
    
    import com.elvarg.Server;
    import com.elvarg.game.entity.impl.player.Player;
    import com.google.gson.Gson;
    import com.google.gson.GsonBuilder;
    import com.google.gson.JsonObject;
    import com.google.gson.JsonParser;
    
    /**
     * Handles the sanctions given to player
     * 
     * @author 2012
     *
     */
    public class SanctionManager {
    
    	/**
    	 * The file location
    	 */
    	private static final String LOCATION = "./data/sanctions/sanctions.json";
    
    	/**
    	 * The date format
    	 */
    	public static final SimpleDateFormat SANCTION_FORMAT = new SimpleDateFormat("dd/MM/yyyyy hh:mm:ss");
    
    	/**
    	 * The sanctions
    	 */
    	public static ArrayList<Sanction> sanctions = new ArrayList<Sanction>();
    
    	/**
    	 private int blackMarks;
    
    	/**
    	 * The duration selected in hours
    	 */
    	private int durationSelected;
    
    	/**
    	 * The rule selected
    	 */
    	private int ruleSelected;
    
    	/**
    	 * The sanctions
    	 */
    	public enum Sanctions {
    		JAIL(SanctionSeverity.LOW, -1),
    
    		MUTE(SanctionSeverity.MEDIUM, 7),
    
    		BAN(SanctionSeverity.MEDIUM, 21),
    
    		IP_MUTE(SanctionSeverity.HIGH, 28),
    
    		IP_BAN(SanctionSeverity.HIGH, 56),
    
    		MAC_BAN(SanctionSeverity.EXTREME, 90),
    
    		SN_BAN(SanctionSeverity.EXTREME, 90),
    
    		HD_BAN(SanctionSeverity.EXTREME, 90),
    
    		;
    
    		/**
    		 * The severity
    		 */
    		private SanctionSeverity severity;
    
    		/**
    		 * How many days to expire
    		 */
    		private int expiry;
    
    		/**
    		 * Represents a sanction
    		 * 
    		 * @param severity
    		 *            the severity
    		 */
    		Sanctions(SanctionSeverity severity, int expiry) {
    			this.setSeverity(severity);
    			this.setExpiry(expiry);
    		}
    
    		/**
    		 * Sets the severity
    		 *
    		 * @return the severity
    		 */
    		public SanctionSeverity getSeverity() {
    			return severity;
    		}
    
    		/**
    		 * Sets the severity
    		 * 
    		 * @param severity
    		 *            the severity
    		 */
    		public void setSeverity(SanctionSeverity severity) {
    			this.severity = severity;
    		}
    
    		/**
    		 * Sets the expiry
    		 *
    		 * @return the expiry
    		 */
    		public int getExpiry() {
    			return expiry;
    		}
    
    		/**
    		 * Sets the expiry
    		 * 
    		 * @param expiry
    		 *            the expiry
    		 */
    		public void setExpiry(int expiry) {
    			this.expiry = expiry;
    		}
    	}
    
    	/**
    	 * The severity of the punishment
    	 */
    	public enum SanctionSeverity {
    		/*
    		 * Low punishments like jail
    		 */
    		LOW,
    		/*
    		 * Medium punishments like mute
    		 */
    		MEDIUM,
    		/*
    		 * High punishment like ban
    		 */
    		HIGH,
    		/*
    		 * High punishment like ipban/mac ban
    		 */
    		EXTREME,
    	}
    
    
    	/**
    	 * Checking if player is muted
    	 * 
    	 * @param player
    	 *            the player
    	 * @return player muted
    	 */
    	public static boolean isMuted(Player player) {
    		/*
    		 * Loop through the sanctions
    		 */
    		for (Sanction san : sanctions) {
    			/*
    			 * Invalid
    			 */
    			if (san == null) {
    				continue;
    			}
    			/*
    			 * Muted
    			 */
    			if (san.getSanction().equals(Sanctions.MUTE) || san.getSanction().equals(Sanctions.IP_MUTE)) {
    				/*
    				 * Found player
    				 */
    				if (san.getName().equals(player.getUsername())) {
    					return true;
    				}
    			}
    		}
    		return false;
    	}
    
    	/**
    	 * Loading
    	 */
    	public static void load() {
    		Path path = Paths.get(LOCATION);
    		File file = path.toFile();
    		if (!file.exists()) {
    			return;
    		}
    		try (FileReader fileReader = new FileReader(file)) {
    			JsonParser fileParser = new JsonParser();
    			Gson builder = new GsonBuilder().create();
    			JsonObject reader = (JsonObject) fileParser.parse(fileReader);
    
    			if (reader.has("sanctions")) {
    				Sanction[] string = builder.fromJson(reader.get("sanctions").getAsJsonArray(), Sanction[].class);
    				for (Sanction l : string) {
    					sanctions.add(l);
    				}
    			}
    		} catch (Exception e) {
    			e.printStackTrace();
    		}
    	}
    
    	/**
    	 * Saving
    	 */
    	public static void save() {
    		Path path = Paths.get(LOCATION);
    		File file = path.toFile();
    		file.getParentFile().setWritable(true);
    
    		if (!file.getParentFile().exists()) {
    			try {
    				file.getParentFile().mkdirs();
    			} catch (SecurityException e) {
    			}
    		}
    		try (FileWriter writer = new FileWriter(file)) {
    
    			Gson builder = new GsonBuilder().setPrettyPrinting().create();
    			JsonObject object = new JsonObject();
    
    			object.add("sanctions", builder.toJsonTree(sanctions));
    
    			writer.write(builder.toJson(object));
    			writer.close();
    
    		} catch (Exception e) {
    			Server.getLogger().log(Level.WARNING, "An error has occured while saving a server settings file!", e);
    		}
    	}
    
    	/**
    	 * Sets the blackMarks
    	 *
    	 * @return the blackMarks
    	 */
    	public int getBlackMarks() {
    		return blackMarks;
    	}
    
    	/**
    	 * Sets the blackMarks
    	 * 
    	 * @param blackMarks
    	 *            the blackMarks
    	 */
    	public void setBlackMarks(int blackMarks) {
    		this.blackMarks = blackMarks;
    	}
    
    	/**
    	 * Sets the durationSelected
    	 *
    	 * @return the durationSelected
    	 */
    	public int getDurationSelected() {
    		return durationSelected;
    	}
    
    	/**
    	 * Sets the durationSelected
    	 * 
    	 * @param durationSelected
    	 *            the durationSelected
    	 */
    	public void setDurationSelected(int durationSelected) {
    		this.durationSelected = durationSelected;
    	}
    
    	/**
    	 * Sets the ruleSelected
    	 *
    	 * @return the ruleSelected
    	 */
    	public int getRuleSelected() {
    		return ruleSelected;
    	}
    
    	/**
    	 * Sets the ruleSelected
    	 * 
    	 * @param ruleSelected
    	 *            the ruleSelected
    	 */
    	public void setRuleSelected(int ruleSelected) {
    		this.ruleSelected = ruleSelected;
    	}
    }
    Quote Originally Posted by Dexter Morgan View Post
    Thank you. Perhaps you could point me in the right direction in private message and explain a few things I could do better
    Your code is clean & documented , nothing to change pal'
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

Page 1 of 4 123 ... LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Delectable And Educated Developer For Hire
    By Shawn Patel in forum Selling
    Replies: 17
    Last Post: 08-13-2013, 11:16 PM
  2. Website developer for hire - buy a website
    By BCWD in forum Website Development
    Replies: 8
    Last Post: 06-13-2013, 04:57 PM
  3. Replies: 2
    Last Post: 05-25-2013, 02:31 AM
  4. Developer for hire.
    By Purple Pvm in forum Requests
    Replies: 1
    Last Post: 03-12-2013, 12:05 AM
  5. Developer for hire [PI]
    By Revival in forum Selling
    Replies: 12
    Last Post: 10-12-2012, 08:46 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •