We have to let the character jump when the up arrow key is pressed. But this must only happen when the character is currently on the floor.
Add an <Up> event. We first test whether the position below the character creates a collision...
Now add a Step event...add a Comment action (type in the box "check whether in the air")
If character is in the air, if the position just below character is empty (no solid objects), then set the gravity to a positive number.
We also want to limit the vertical speed so if it's more than 12, we'll set back to 12. So add a few more actions:
Test it out and see that it works. Your character should go up.
In the character object, we have to make sure he lands correctly on the floor (when collides with a block object). We need to place the character back to its previous position just before the collision; if it's already at the current position, it doesn't move.
So add the Collision with block event.
In your room, add a couple platforms so you can test it out (note: the character can only jump about 6 grid squares up)