QBasic Tutorial 36 – Making A Sub In QB64

www.SchoolFreeware.com As programs become more advanced, placing all the code in the main program can make the program more difficult to program, maintain, and understand. Slicing the program into sections can help. These sections are called by many names. The names include subs, sub-modules, sub-procedures, procedures and sub-programs. The way that the subs work is that the main program, another sub or function will call the sub. Once the sub is called, it will run. When the sub is done running the main program main program, another sub or function will continue with its code. Before we can start programming with subs we have to know how to create the subs. Subs can be created in QB64 by going to Edit — New Sub and typing the name of your new sub in the box. Subs, can also be created by manually typing the sub’s code.
Video Rating: 5 / 5

I’ve updated the engine for Globule and added some new stuff. Death – The staple of every platformer. Spikes, spike traps and falling off the screen now kill poor globule Push – Certain object can be pushed around the level, making them fall consistantly and correctly is proving to be a pain. Ceiling Crawl – On certain ceilings it’s possible to crawl along them, stopping still for too long however causes you to peel off the ceiling. Buster – You can now use the Buster move to break certain objects, it also leaves behind a cool looking trail effect. Collectables – Collecting these gives you points, what are you collecting, I have no idea. Wall Jump – During a Wallslide you can now jump off the wall. I also added a few graphics and other efects. Next: Add double jump, tweak the current jump height as it’s much too strong at the minute, improve and add more graphics (hardest part). Choose which direction to take the game – Traditional platformer ie Mario/Sonic, Hard platformer ie IWTBTG or something a little different (I have one interesting idea at the minute). Thats it. Oh and if any Pixel Artists want a game added to their CV/Blog/Portfolio drop me an email 🙂

Get the book now