Arrows-move and jump
Hold Z to Zoom out and see the entire cave
G-generate a new cave
Random cave capx
Random cave example
UPDATE:you can find above the link to the capx., this is slightly different from the example but you can use your own tiles for the auto-tile function.
Edit:i forgot to paste the comments to this example so if you have any doubts just ask here if you like.