Projects >> Haven-and-Hearth-client-modified-by-Ender >>ccb63e0f3c75cd1be1baca468d1aaf44e7d29c22

Chunk
Conflicting content
import javax.imageio.*;
import java.awt.image.BufferedImage;

<<<<<<< HEAD
public class Resource implements Comparable {
=======
public class Resource implements Comparable, Serializable {
	private static File basedir = new File("Y:\\res");
>>>>>>> 182252634aa960e7643a5f3722d6769be7069eca
	public static URL baseurl = null;
	private static Map cache = new TreeMap();
	private static Loader loader;
Solution content
import javax.imageio.*;
import java.awt.image.BufferedImage;

public class Resource implements Comparable, Serializable {
	public static URL baseurl = null;
	private static Map cache = new TreeMap();
	private static Loader loader;
File
Resource.java
Developer's decision
Combination
Kind of conflict
Attribute
Class signature
Method invocation
Chunk
Conflicting content
	}
	
	private static InputStream getres(String name) {
<<<<<<< HEAD
		InputStream s = Resource.class.getResourceAsStream("/res/" + name);
		if(s == null)
			throw(new LoadException("Could not find resource locally: " + name));
		return(s);
=======
		String fn = "";
		for(int i = 0; i < name.length(); i++) {
			char c = name.charAt(i);
			if(c == '/')
				fn += File.separator;
			else
				fn += c;
		}
		File f = new File(basedir, fn + ".res");
		try {
			return(new FileInputStream(f));
		} catch(FileNotFoundException e) {
			throw(new LoadException("Resource not found locally", e, null));
		}
>>>>>>> 182252634aa960e7643a5f3722d6769be7069eca
	}
	
	public static BufferedImage loadimg(String name) {
Solution content
	}
	
	private static InputStream getres(String name) {
		InputStream s = Resource.class.getResourceAsStream("/res/" + name + ".res");
		if(s == null)
			throw(new LoadException("Could not find resource locally: " + name, null));
		return(s);
	}
	
	public static BufferedImage loadimg(String name) {
File
Resource.java
Developer's decision
Manual
Kind of conflict
For statement
If statement
Method invocation
Return statement
Try statement
Variable
Chunk
Conflicting content
							while(true) {
								String layer = msg.string();
								int ver = msg.uint16();
<<<<<<< HEAD
								if(layer.equals(""))
									break;
								layers.add(layer);
								vers.add(ver);
=======
								oc.cres(id, frame, res, ver);
							} else if(type == OD_LINBEG) {
								Coord s = msg.coord();
								Coord t = msg.coord();
								int c = msg.int32();
								oc.linbeg(id, frame, s, t, c);
							} else if(type == OD_LINSTEP) {
								int l = msg.int32();
								oc.linstep(id, frame, l);
							} else if(type == OD_SPEECH) {
								Coord off = msg.coord();
								String text = msg.string();
								oc.speak(id, frame, off, text);
							} else if((type == OD_LAYERS) || (type == OD_AVATAR)) {
								String baseres = "";
								int basever = 0;
								if(type == OD_LAYERS) {
									baseres = msg.string();
									basever = msg.uint16();
								}
								List layers = new LinkedList();
								List vers = new LinkedList();
								while(true) {
									String layer = msg.string();
									int ver = msg.uint16();
									if(layer.equals(""))
										break;
									layers.add(layer);
									vers.add(ver);
								}
								if(type == OD_LAYERS)
									oc.layers(id, frame, baseres, basever, layers, vers);
								else
									oc.avatar(id, frame, layers, vers);
							} else if(type == OD_DRAWOFF) {
								Coord off = msg.coord();
								oc.drawoff(id, frame, off);
							} else if(type == OD_LUMIN) {
								oc.lumin(id, frame, msg.coord(), msg.uint16(), msg.uint8());
							} else if(type == OD_END) {
								break;
							} else {
								throw(new MessageException("Unknown objdelta type: " + type, msg));
>>>>>>> 182252634aa960e7643a5f3722d6769be7069eca
							}
							if(type == OD_LAYERS)
								oc.layers(id, frame, layers, vers);
Solution content
							while(true) {
								String layer = msg.string();
								int ver = msg.uint16();
								if(layer.equals(""))
									break;
								layers.add(layer);
								vers.add(ver);
							}
							if(type == OD_LAYERS)
File
Session.java
Developer's decision
Version 1
Kind of conflict
Break statement
If statement
Method invocation
Throw statement
Variable
While statement