Revision as of 05:01, 18 October 2019 by TenType (talk | contribs) (Categorized, added STUB, fixed SB)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Document stub.png This article is a stub. It may be incomplete, unfinished, or have missing parts/sections. If the article can be expanded, please do so! There may be suggestions on its talk page. (October 2019)

Example

Projectiles are used in a wide variety of games, such as shooters, and are not very complicated to make. You will only need 35 blocks.

when gf clicked
forever
hide
set rotation style [all around v ] // rotation mode
go to (player1 v) // go to sprite currently shooting
point towards (mouse pointer v) // to aim your projectile
if <mouse down?> then
if <<(direction) < (120)> and <(direction) > (-120)>> then // to stop unwanted glitches
if <(direction) < (0)> then
show
repeat until <<touching (edge v)?> or<touching (player2 v)?>> // repeat until collision
move [10] steps // move forward
turn left [2] degrees // constantly dip downwards
end
move [10] steps // continue colliding with object after initial collision
hide
else
show
repeat until <<touching (edge v)?> or<touching (player2 v)?>> // repeat until collision
move [10] steps // move forward
turn right [2] degrees // constantly dip downwards
end
move [10] steps // continue colliding with object after initial collision
hide
end
end
end
end

The most important part to this is that the projectile is in the center of its costume, otherwise, the projectile will not travel smoothly in the air.