GOSUBS totally new LOOP?

Blitz3D Forums/Blitz3D Beginners Area/GOSUBS totally new LOOP?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

;My code looks something like this


;graphics3d 800,600,16
;;; create global variables
;;;etc
;;;
;;

While not key down(0)


;gosub updatetime
;other gosubs

;frame limiting code

end while



.updatetime

if time<600
time=time +1
endif

Return


.othergosubs

return


;;;MY QUESTION is I have frame limiting code in my while loop, do I have to Include the frame limiting code in my GOSUBS also for my program to run at the SAME speed while in a gosub?

In other words, while in a gosub does the program just LOOP their until it hits the return statement? For example in my updatetime gosub, the time variable increases until it hits 599.

Does the time variable increase at the COMPUTERS fatest process time or does it computes this at the frame limittting code time I have in the main loop.