Search found 38 matches

by MikeHawk
Thu Jan 21, 2021 3:25 am
Forum: QBASIC and QB64 Questions & Answers
Topic: structure array within a structure
Replies: 2
Views: 1371

Re: structure array within a structure

QBasic doesn't support namespaces, which is what I think you're trying to do with "maindata." I'm afraid you'll have to create a set of shared variables instead (see this topic for shared variables.) It's dirty but there's no other way that I'm aware of: DIM SHARED mdStoreName AS STRING * 30 DIM SHA...
by MikeHawk
Sat Jan 16, 2021 9:22 am
Forum: QBASIC and QB64 Questions & Answers
Topic: shortening loading time for call absolute
Replies: 4
Views: 2644

Re: shortening loading time for call absolute

Way back when, we used to simply store assembly code in hexadecimal text-form in DATA statements... I'd replace the target string with an INTEGER array and use POKE to fill it faster. This would remove the need for the CHR$() and would also avoid resizing strings on-the-fly, which is much slower tha...
by MikeHawk
Tue Jan 05, 2021 10:47 am
Forum: News and Announcements
Topic: QB 4.0 ERROR: Length incorrect with certain string variables
Replies: 1
Views: 2394

Re: QB 4.0 ERROR: Length incorrect with certain string variables

Fairly certain it's working as intended. Fixed-length strings will always return the same length, regardless of their content. DIM v AS STRING * 50 v = "Fifty" PRINT "*";STRING$(50, "-");"*" PRINT "*";v;"*" Consider the following: DECLARE FUNCTION var% (variable%) DIM SHARED dummy AS INTEGER dummy =...
by MikeHawk
Sun Jan 03, 2021 3:19 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: Caling custom interrupt without using "call interrupt"
Replies: 1
Views: 1378

Re: Caling custom interrupt without using "call interrupt"

That's probably more an ASM question than a QB question. Anyway, a while back Hans Lunsing wrote a replacement for Call InterruptX in assembly so QBasic 1.1 could also support interrupts. The code is available right here . I don't know much about assembly but it should be possible to retrieve the in...
by MikeHawk
Tue Dec 22, 2020 3:44 pm
Forum: News and Announcements
Topic: PlayMATE - a PLAY composer
Replies: 3
Views: 2700

Re: PlayMATE - a PLAY composer

Okay, I think I removed the crash on exit bug again. Let's see how long that lasts. Version .4 fixes a few things (like changes not warranting a confirmation prompt, and some crashes caused by saving/loading empty documents) and includes folder browsing for file load/save. Also, the interface librar...
by MikeHawk
Sat Dec 12, 2020 8:02 am
Forum: News and Announcements
Topic: PlayMATE - a PLAY composer
Replies: 3
Views: 2700

Re: PlayMATE - a PLAY composer

Let me know how it goes; I worked a little bit more on it (v.4, it's not online) and the crash on exit came back. I still have no idea what's the cause of this thing, or how it vanished in v.3...
by MikeHawk
Tue Nov 24, 2020 8:31 am
Forum: News and Announcements
Topic: PlayMATE - a PLAY composer
Replies: 3
Views: 2700

PlayMATE - a PLAY composer

I'm not much of a musician so writing PLAY strings from scratch can be a hassle for me... so I wrote a PLAY "tracker" to provide visual support. Right now, it features simple stuff like changing time signature and tempo, copy/insert bars, transposition and note length rescaling. It can import PLAY s...
by MikeHawk
Fri May 08, 2020 7:56 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

I gave it another go, I hope this prevents the lock up. There's still no proper sound mixing and no ISR, but if it can at least play reliably one sound at a time, then I'm okay with it for now (that's enough to fix the previous games.)
by MikeHawk
Wed May 06, 2020 4:49 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

Also just for kicks I took out all my sound configs from my autoexec.bat and config.sys and wavetest behaved the exact same way. (even played the sound still). Yeah, that's on me: if there's no config string found, it defaults to "A220 I5 D1 H5" (base port 0x220, IRQ 5, low DMA 1, high DMA 5,) I do...
by MikeHawk
Mon May 04, 2020 5:20 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

But at least there's sound, so it's getting somewhere... I should probably stop the DMA transfer manually, or maybe attempt auto-init DMA transfer, which would also provide sample mixing... I'm just not sure how to do it yet... I'll look into it, thanks again for your help!
by MikeHawk
Sat May 02, 2020 10:05 am
Forum: QBASIC and QB64 Questions & Answers
Topic: how to share Common declare between modules
Replies: 6
Views: 31068

Re: how to share Common declare between modules

Erik wrote:
Sat May 02, 2020 3:36 am
Does this mean that a "stand alone" compiled EXE with COMMON vars will not carry over if the program isn't recompiled to require BRUN45?
Yep.
by MikeHawk
Sat May 02, 2020 9:56 am
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

I suppose I could pull my overdrive chip out of the expansion slot and see how it runs on a 25MHz 486SX but that thing is wedged in there pretty good right now. Thanks for the help Erik! I'm fairly certain removing the overdrive chip won't be necessary... last patch fixed a stupid mistake where I w...
by MikeHawk
Fri May 01, 2020 4:47 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

Okay, I think I have some sound code that should work. It kind of works in VirtualBox (as well as it could given VB's faulty DMA transfer status port emulation and the lack of support for the SB16 command 0x41) but it works perfectly under DOSBox (but then my other junky code also worked under DOSBo...
by MikeHawk
Thu Apr 30, 2020 5:54 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

Glad it gets the game running at least. I really need to check how I initialized mode Y in Panda. Given the vertical tear in the 13rd "slice of Doom," it could be an issue with the display page offset... that game was my first attempt at mode Y so this may explain that. Right now I'm having sound is...
by MikeHawk
Thu Apr 30, 2020 9:14 am
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

Good news! I managed to get most games to crash under a virtual machine (I really need to get my hands on a genuine DOS PC.) Panda crashes when hovering one of the menu options, so it might be related to sound effects (although it shouldn't attempt to play anything if it fails to find the Sound Blas...
by MikeHawk
Wed Apr 29, 2020 5:07 pm
Forum: News and Announcements
Topic: Panda BLAST!
Replies: 23
Views: 33093

Re: Panda BLAST!

Thanks for the feedbacks! Panda loads up to the title screen but once the mouse moves it gets hung up. That's kind of good news: Panda still uses some ASM code and CALL ABSOLUTE to get the mouse input, while Minesweeper DUO uses CALL INTERRUPTX. I replaced that part of the code and I'm eager to see ...
by MikeHawk
Mon Apr 27, 2020 10:15 am
Forum: News and Announcements
Topic: Cody McCloud in: Rain of Terror
Replies: 3
Views: 20704

Re: Cody McCloud in: Rain of Terror

Glad you like it and thanks for the feedback, I really appreciate it!

For keyboard controls, right ctrl launches the ball and holding shift increases movement speed. I should probably add a way to customize controls in the menu.
by MikeHawk
Sat Apr 18, 2020 10:49 pm
Forum: QBASIC and QB64 Questions & Answers
Topic: For/Next/Step
Replies: 2
Views: 8008

Re: For/Next/Step

Hi there. To keep things short, the FOR...NEXT loop is initialized once by QBASIC before it starts, so you can't mess with the upper limit ("128" in your example) and you can't modify the value fed to STEP either. When you type: FOR a = b TO c STEP d PRINT a NEXT a QBASIC is actually doing: from = b...
by MikeHawk
Mon Apr 13, 2020 5:43 am
Forum: QBASIC and QB64 Questions & Answers
Topic: how to share Common declare between modules
Replies: 6
Views: 31068

Re: how to share Common declare between modules

Okay, there's another way to share a variable only between certain routines: define the variable as usual in the main module, then use SHARED within the routine: DECLARE SUB test1 () DECLARE SUB test2 () DIM something AS STRING something = "anything, really" test1 test2 END SUB test1 SHARED somethin...
by MikeHawk
Wed Apr 08, 2020 6:49 pm
Forum: News and Announcements
Topic: Cody McCloud in: Rain of Terror
Replies: 3
Views: 20704

Cody McCloud in: Rain of Terror

It's a Breakout clone with a cloud... 30 levels of ball busting fun! It has a save game feature, SoundBlaster effects, joystick, mouse and keyboard support, particle effects, animated backgrounds (using palette-cycling tricks,) a handful of instruction screens, a high-score table, 3 difficulty setti...