Ok so for picking up an object, I don't want to use getOneObjectAtOffset(0, 0, <actor>.class); as this only picks it up at the centre, so I tried this:
But it doesn't work, so how would I do it? (and I can see how it doesn't work, just not how to make somthing that does work).
1 2 3 4 5 6 7 8 9 10 11 12 | public void getCoin() { Actor Coin; Coin = getObjectsInRange( 16 , Coin. class ); if (Coin != null ) { World world; world = getWorld(); world.removeObject(Coin); addMoney(); } } |