We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hello! I have been working on a program and have run into a problem: I want to make a class where you can name the "Program" that this class is defining, and then run that function. Basically, call a function like you do in a thread, but I want to be able to display things. here is the class:
class App {
String Name;
int ID;
App(String n,int i){
Name = n;
ID = i;
}
void Run(){
//This is what I need! :0
}
}
//and this is how I want to be able to use it:
App Test = new App("Test",0);
void Test(){
background(255);
//Do some other stuff
}
//run the function like this:
void draw(){
Test.Run();
}
so what I want to know is, how do I do it? :-/
Answers
thread()Use method().
Testing...
it worked! thanks so much! ^:)^