Thanks Javier for the feedback. I've stripped the code down as much as possible.
This file will run within processing, but not export. I can export other files to applets without any problems.
The error I get when trying to export is:
/Users/frank/6.914/final project/final merged/final/applet/final.java:1:621:1:625: Syntax Error: Identifier expected instead of this token
processing.app.RunnerException: Identifier expected instead of this token at processing.app.Compiler.message (Compiler.java:360) at processing.app.MessageSiphon.run( MessageSiphon.java:60) at java.lang.Thread.run (Thread.java:552)
The pde file:
Code:
//object array for countries
CountryObject[] country = new CountryObject[1];
void setup(){
size(1000, 500); // window of size 500 x 500
setupCountries();
}
void draw(){ background(100);}
class CountryObject {
//attributes
String name;
int[] pop = new int[101];
float[] percentUrban = new float[101];
float xPos;
float yPos;
int[] neighbor = new int[5]; //upper limit on # neighbors
//constructor
CountryObject (String n, float x, float y) {
name = n;
xPos = x;
yPos = y;
}
void drawBlob(int firstYear, int secondYear) {
}
void loadPop(String fiveYearPop) {}
void loadNeighbors(int n0, int n1, int n2, int n3, int n4) {}
void loadUrb(String fiveYearUrb) {}
void printPopArray() {}
void printUrbArray() {}
}
void writeLog(String logString) {}
void checkPause() {}
float adjustedXPos(float x) {return 1;}
float adjustedYPos(float y) { return 1;}
void drawInfo() {}
String numFormat(float pop) {return "foo";}
void drawUI() {}
void setupCountries() {}
Modified 2/25 to fix code formatting, thanks Javier.