Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void move() {
- super.move();
- Location temp = getLocation();
- temp = head.getLocation();
- int tmp = head.getSpeed();
- int hehe = head.getHeading();
- head.move();
- if(newSegCount > 0){
- list.add(new BodySegment(temp, tmp, hehe));
- newSegCount--;
- }
- else{
- list.get(0).setLocation(temp);
- list.get(0).setSpeed(tmp);
- list.get(0).setHeading(hehe);
- list.add(list.remove(0));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement