08-17-2022, 02:09 PM
The "squiggle" just after variable name means "_UNSIGNED". For this reason, which causes confusion, I don't advocate type sigils any longer and would like QB64 to get with the times about function declaration heading (such as "FUNCTION foo(parameters) AS _UNSIGNED _INTEGER64" instead of "FUNCTION foo~&&(parameters)").
The loop including "_MOUSEINPUT" is often used to drain out the mouse message queue, which is very important because this programming system doesn't have something like found in Purebasic, about handling keyboard and mouse input. The routine to deal with the mouse in QB64 are almost quick and dirty. That's why it's more difficult to check for mouse button press then release, to keep track of mousewheel and a few other things than while programming an ordinary Windows application on Purebasic.
"_LIMIT" is helpful to bring down the CPU usage of programs. Without it, your program would be intolerable to other people, even if one of them has an 8-core system. Oh well LOL I don't know about that really. Many programs written for M$QB and Qbasic rely on ordinary "FOR...NEXT" loops to delay program run, which is needed in an arcade game so the enemies don't go too fast on the player. That was good while computers were built with Intel's older processors like 8086. After systems became 32-bit and 64-bit the programming language loops became too blinding fast to use a "FOR... NEXT" arrangement. The alternative to "_LIMIT" is "_DELAY" but it could be another PITA trying to get precise input from the user and he/she doesn't lose patience.
If you're not an "advanced" programmer you shouldn't be discussing anything about the "_MEM" gang. IJS.
The loop including "_MOUSEINPUT" is often used to drain out the mouse message queue, which is very important because this programming system doesn't have something like found in Purebasic, about handling keyboard and mouse input. The routine to deal with the mouse in QB64 are almost quick and dirty. That's why it's more difficult to check for mouse button press then release, to keep track of mousewheel and a few other things than while programming an ordinary Windows application on Purebasic.
"_LIMIT" is helpful to bring down the CPU usage of programs. Without it, your program would be intolerable to other people, even if one of them has an 8-core system. Oh well LOL I don't know about that really. Many programs written for M$QB and Qbasic rely on ordinary "FOR...NEXT" loops to delay program run, which is needed in an arcade game so the enemies don't go too fast on the player. That was good while computers were built with Intel's older processors like 8086. After systems became 32-bit and 64-bit the programming language loops became too blinding fast to use a "FOR... NEXT" arrangement. The alternative to "_LIMIT" is "_DELAY" but it could be another PITA trying to get precise input from the user and he/she doesn't lose patience.
If you're not an "advanced" programmer you shouldn't be discussing anything about the "_MEM" gang. IJS.