Back to Defold after 2 years, "Bouncy Catapult" hypercasual prototype

Yes, not so pretty code, but you could move those three lines to a utility function. It is not optimal from a performance standpoint of course to make three calls into the engine to do this, but this kind of thing is likely not done that often.