removed a unused method and moved initialization into the onFrame method