Search found 9 matches

by rgreenlaw
Tue Aug 07, 2007 5:53 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: New to QBASIC, I have a question.
Replies: 9
Views: 6874

Put it all together

When you put it all together (and fix syntax errors) you get the following: DIM scr$(10, 10)' create an array to hold data FOR x = 1 TO 10 FOR y = 1 TO 10 READ s$ IF LEN(s$) > 1 THEN scr$(x, y) = CHR$(VAL(s$)) ELSE scr$(x, y) = s$ NEXT y NEXT x DATA 177,177,177,177,177,177,177,177,177,177 DATA 177,0...
by rgreenlaw
Tue Aug 07, 2007 5:02 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: New to QBASIC, I have a question.
Replies: 9
Views: 6874

Looks good!

I viewed your program yesterday, but don't see my posting about it here. I'll try again. I think the solid walls improve the program appearance, but did you do anything about the screen data? Try this for an example: To load the screen into an array dim scr$(10,10) ' create an array to hold data for...
by rgreenlaw
Tue Aug 07, 2007 10:18 am
Forum: News and Announcements
Topic: Munshkin
Replies: 8
Views: 10530

Looks good!

Keep working on it! The changes are nice.
by rgreenlaw
Mon Aug 06, 2007 6:43 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: how to get the timer to count down
Replies: 5
Views: 8968

Alternative countdown timer

You could also use this: t = 35' 35 seconds ON TIMER(1) GOSUB tickme CLS PRINT PRINT PRINT "timer has started" TIMER ON k$ = "" PRINT "Enter your name? "; WHILE t > 0 AND k$ <> CHR$(13) k$ = INKEY$ IF k$ <> CHR$(13) THEN a$ = a$ + k$: PRINT k$; : k$ = "" IF TIMER = 0 THEN PRINT : PRINT "Your name is...
by rgreenlaw
Mon Aug 06, 2007 6:24 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: game problem
Replies: 11
Views: 10777

Help for entering your code.

When you placed your code in the posting you entered it within the text box. Try the following to make it easier to read. Press the button above marked Code before inserting the code and pressing it again after you have finished. The difference will make the code change from this: wild$(8)="demo" to...
by rgreenlaw
Mon Aug 06, 2007 6:08 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: can I do this in a SUB?
Replies: 2
Views: 3206

While learning qbasic and subs try this

While learning to program in Qbasic and using subroutines you might want to try this:

Code: Select all

call dog
instead of

Code: Select all

dog
This will help you to remember that "dog" is a subroutine that you coded.
by rgreenlaw
Mon Aug 06, 2007 5:58 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: A VERY VERY QUICK question!
Replies: 3
Views: 3266

Do you mean an elapsed game timer?

This code shows how to do a timer on the screen showing hours, minutes and seconds that the timer has been running. If used within a game it can be used to show the elapsed time of any selected event or the entire length of time that the game has been running. CLS ON TIMER(1) GOSUB timetick timecoun...
by rgreenlaw
Mon Aug 06, 2007 4:15 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: New to QBASIC, I have a question.
Replies: 9
Views: 6874

Program works in QB4.5

I just downloaded and ran your code in QB 4.5 and it works. You have a potential problem for expanding your code. As your program gets larger you will keep expanding the code by about 10 lines for each move. This program was written as if you never plan to move very far. For screen appearance you mi...
by rgreenlaw
Mon Aug 06, 2007 1:25 pm
Forum: News and Announcements
Topic: Microsoft fails to kill DOS with Vista
Replies: 3
Views: 6317

Microsoft fails to kill DOS with Vista

One might think that Microsoft has finally killed off DOS when trying to run a compiled Qbasic program or trying to use Qbasic to load a basic program. Microsoft's decision to make it impossible to expand the CMD prompt screen to full size has made it impossible to directly load Qbasic and programs ...