ScratchData LogoScratchData
Back to kriblo_test's profile

Example: Projectile Motion

KRkriblo_test•Created April 4, 2022
Example: Projectile Motion
117
91
1553 views
View on Scratch

Instructions

Click to launch a projectile from the "Cannon" in the lower left corner. The stage height is arbitrarily defined as 10 m, so pixels / meter is 360/10=36 px/m. In this example, gravity is 9.81 m/s² or 9.81 m/s² * 36 px/m ≈ 353 px/s². Initial velocity (m/s) is determined by the distance from the "Cannon" to the mouse pointer. See inside, Cannon sprite. x & y of the projectile is calculated using launch angle, initial velocity & time since launch time. y is affected by gravity. See inside, Ball sprite.. All code by me (@kriblo). Thanks to @RokCoder for some help with the "think" ;) Inspired by @IAmSpeed123's project "Trig Projectile Launching": https://scratch.mit.edu/projects/667153012 It made me start thinking "How would I do that?". Thanks!

Project Details

Project ID671086964
CreatedApril 4, 2022
Last ModifiedJanuary 27, 2023
SharedApril 4, 2022
Visibilityvisible
CommentsAllowed