Nobody is perfect.
This thread is dedicated to prove that we (the developers) make mistakes.
Very embarrassing mistakes....
Found in my old background application that would stream stuff to my phone.
Found in my old background application that would stream stuff to my phone.
using (Stream stream = WebRequest.Create(url).GetResponse().GetResponseStream()) { byte[] buffer = new byte[32768]; int read; while ((read = stream.Read(buffer,0,buffer.Length)) > 0) { ms.Write(buffer, 0, read); } }For a month straight I've been trying to figure out why it isn't working. Forgot to input a URL.-facepalm-
I see the url variable. Did you just forget to populate it?
package com.knockturnmc.quidditch;
import com.knockturnmc.quidditch.enums.PositionType;
public class Position {
private final PositionType position;
protected Position (PositionType position){
this.position = position;
}
public PositionType getPosition() {
return position;
}
}
WUT EVEN IS THIS !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ~~~ Was in my code. I cry.
public class Knockturn implements CommandExecutor {
KnockturnEssentials essentials;
boolean isPlayer;
public Knockturn() {
this.essentials = KnockturnEssentials.getInstance();
}
@Override
public boolean onCommand(CommandSender sender, Command cmd, String label,
String[] args) {
if (args.length == 0) {
sender.sendMessage(Lang.INCORRECT_COMMAND);
return true;
}
if (!(sender instanceof Player)) {
sender.sendMessage("You need to be a player to run this command.");
return true;
}
Player player = ((Player) sender);
if (isPlayer && !player.hasPermission(Permission.ADMIN_PERM)) {
player.sendMessage(Lang.INSUFFICIENT_PERMISSION);
return true;
}
0 members, 0 guests, 0 anonymous users