tbe
tbe copied to clipboard
Set start direction of Pingus and Butterfly
There is currently no way to set the initial direction of a butterfly, it's always facing right.
For Pingus the starting direction appears to be … random? I have no idea how it works. It seems the only “safe” way is to place some obstacles to force a direction but this is not always what you want to have.
So I suggest to add some way in the editor to force the initial direction of a butterfly and a pingu.
I prefer to not think about this for this milestone, if you don't mind.
I totally understand. Milestone B has lots of tasks already. ;-)
Setting the start direction of a butterfly is going to be hard - the direction is hard-coded in the Butterfly class and there are no images for flying to the left or flying stationary.
For Pingus, I'm thinking along the lines of making subclasses of Pingus called LeftPingus
that walk left and RightPingus
that walk right. The default Pingus
class will then no longer be directly usable.
Those two commits should bring us rather close for Pingus. Wuzzy, can you check if this satisfies your needs?
Sorry, it doesn't seem to work in f72d737436b5dde2bb1b376329105fbe3340a08e. Sometimes the pingus just appear to turn around, just at the start of the simulation. So the initial direction is mostly useless. Maybe it has something to do with the drop height? No matter what causes this, the issue is obviously not ready to be closed yet. :/
Pingus should reliably walk left or right and not just randomly turn around after they dropped.
Do pingus maybe forget the direction they were walking as soon they fall? That might explain the problem.
Do pingus maybe forget the direction they were walking as soon they fall? That might explain the problem.
Yup. That's solvable, though.
Done. For good, I hope.
Penguins seem fine now, but what about the butterfly?