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

2020/3/15

Move Actor to Location of click of mouse

1
2
APCSP-6 APCSP-6

2020/3/19

#
Nevermind. I changed the wrong piece of code to private. Its working. If I wanted the Waitress to move faster just a little how would I put that in. I don't want her to move too fast but just a little faster than what she's doing.
danpost danpost

2020/3/19

#
You could add the following line in your world constructor:
Greenfoot.setSpeed(55);
That would, however, would not change the relative speed with the other actors. If that is what you want, you may need to employ a smooth moving system (a) my QActor class; or (b) greenfoot's SmoothMover class; or (c) implementing one on your own). As Hippo pointed out -- you will need extra code to avoid "glitching" about the target location.
APCSP-6 APCSP-6

2020/3/19

#
When I changed the code, the Waitress stopped "glitching" so I just needed to change the code. I think that was the only thing I needed to work on with the Waitress besides getting her to appear in front of the image I got of the counter. Thank you guys!!
You need to login to post a reply.
1
2