This site requires JavaScript, please enable it in your browser!
Greenfoot back
rosh11
rosh11 wrote ...

2016/7/6

Location

rosh11 rosh11

2016/7/6

#
how can I print the location of an object when another actor removed it?
SPower SPower

2016/7/6

#
You need to print it right before removing it:
Actor tobeRemoved = ...;
System.out.println("x: "+tobeRemoved.getX()+", y: "+tobeRemoved.getY());
getWorld().removeObject(tobeRemoved);
You need to login to post a reply.