Tilt Cannons - v1.0
May I introduce to you my very first custom block pack
(with only two blocks lol),
Tilt Cannons!
Enter the pipe, tilt the cannon in the direction you want it and get blasted out!
They work like the ones of Super Mario 64 or the New Super Mario Bros Wii Mushroom Houses
Works with every vanilla character, though SMB2 characters have slightly different physics.
The very complex controls:
Rotate by holding left or right
Press the UP Key to get shot.
If you hold run while choosing the angle, the cannon rotates faster!
Utility options (Settings and Flight Canceller):
Max Angle (left) and Max Angle (right):
The value defines the highest rotation (in degrees) the tilt cannon can reach.
If the Base of your cannon is fully covered by ground on one side, you should set max angle on that side to 15.
If the Base of your cannon is half covered by ground on one side, you should set max angle on that side to 60.
A value over 90 is only recommended if there are no blocks right beneath it.
Power:
The value defines how long the player flies in a straight line. The higher the value, the further the cannon shoots the player.
The player is invulnerable while flying in a straight line, hurting enemies on their way.
If the value is 0, you will reach the same height as when shot out of a mortar and won't fly in a straigt line at all.
If the player touches a flight canceller hits the ground or the ceiling, the player stops flying in a straight line and regains control.
Doesn't affect the flight, if the Mortar is ticked.
Elasticity:
When hitting a wall, you will bounce off in the other direction.
The value defines how much of your momentum keeps when hitting a wall.
A value of 1 doesn't make you lose any of your momentum when bouncing.
A value of 0 doesn't bounce you off a wall at all.
Doesn't affect the flight, if the Mortar is ticked.
Mortar:
When ticked, the player performs a mighty ground pound when getting shot.
Until they hit solid ground, the player is able to tear through blocks without stopping.
A Mortar is not affected by the values of Elasticity and Power.
Flight Canceller:
When touched, the player will stop flying and regains control, is no longer invulnerable though.
Invisible ingame.
Some gifs to get a better idea of it:
How to use:
You just have to copy the files of the Tilt Cannons into your episode's or level's folder, reload the editor and you have it listed in the Custom Tilesets.
Place it down, set the values you want and have fun getting blasted away! (Don't cover the cannon in blocks please)
You want to use them?
Then here you go:
https://www.dropbox.com/sh/vkhf4ztqydxy ... uAlfa?dl=0
Please credit me if used, or else you will make a turtle very sad ):
Also, thanks to Marioman for help with the rotation code!
If you encounter any bugs, notify me and I can see if I can fix it!