/////////////////////////////////////////////////////////////////////
////subscribe(obj, func)
def subscribe(Object obj, Closure FunctionToCall) {
- objectList.add(obj)
- eventList.add("Touched")
- functionList.add(FunctionToCall)
+ if (obj == app) {
+ objectList.add(obj)
+ eventList.add("Touched")
+ functionList.add(FunctionToCall)
+ } else if (obj == location) {
+ objectList.add(obj)
+ eventList.add("Location")
+ functionList.add(FunctionToCall)
+ }
}
////subscribe(obj, event, func)
def subscribe(Object obj, String event, Closure FunctionToCall) {