1 package se
.umu
.cs
.dit06ajnajs
;
4 import java
.io
.IOException
;
7 import java
.util
.logging
.Logger
;
8 import org
.jdom
.JDOMException
;
9 import se
.umu
.cs
.dit06ajnajs
.map
.Level
;
10 import se
.umu
.cs
.dit06ajnajs
.util
.LevelsXMLParser
;
13 public static final int SQUARE_SIZE
= 45;
14 private static final URL DEFAULT_LEVELS_XML
15 = AntiTD
.class.getResource("/resources/levels.xml");
22 public static void main(String
[] args
) {
23 Logger
.getLogger("AntiTD").setLevel(java
.util
.logging
.Level
.INFO
);
25 System
.out
.println("******* THIS IS THE START *******");
30 if (args
.length
== 1) {
31 levels
= LevelsXMLParser
.parse(new File(args
[0]));
33 levels
= LevelsXMLParser
.parse(DEFAULT_LEVELS_XML
);
36 new ATDController(levels
);
37 } catch (IOException e
) {
38 // TODO - fix error message
41 } catch (JDOMException e
) {
42 // TODO - fix error message, invalid xml...
43 System
.err
.println("Error parsing XML-file containing level information: ");
44 System
.err
.println(e
.getMessage());