ql superbomber and m-crunch ..and more things

Anything QL Software or Programming Related.
User avatar
Cristian
Super Gold Card
Posts: 620
Joined: Mon Feb 16, 2015 1:40 pm
Location: Veneto

Re: ql superbomber and m-crunch ..and more things

Postby Cristian » Thu Mar 21, 2019 12:45 pm

Maybe converting the _scr file to _pic; but then we'll need a _pic reader.
Or, better, drawing the screen with few superbasic lines (the image is a simple a rainbow background made with horizontal bars, and some CSIZE 3,1 text).


User avatar
Dave
SandySuperQDave
Posts: 2409
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: ql superbomber and m-crunch ..and more things

Postby Dave » Thu Mar 21, 2019 6:13 pm

Sounds like any other way than a _scr would be smaller ;)


Martin_Head
Gold Card
Posts: 411
Joined: Tue Dec 17, 2013 1:17 pm

Re: ql superbomber and m-crunch ..and more things

Postby Martin_Head » Fri Mar 22, 2019 11:20 am

Working from memory, I'm pretty sure there's no compression going on. (Though there is encryption of the game code and data,. Which I have removed)

The lack of room to fit everything onto a microdrive may be down to my BOOT program, which is a lot larger than the original one. The original being something like RESPR : LBYTES : CALL

If you want to try disabling the turning off and on of the display. You could try this -

Enter 4 NOP's from the start of the code + $1C28. And 8 NOP's from the start of the code + $1C36. I've not actually tried it yet, just worked out what to do.

Here's the piece of code to overwrite

Code: Select all

Lab11C24  bsr       lab10a9a           ;*** 20mS delay via STOP instruction  ***
          ori.b     #2,$00018063      ;master chip status, turn display off
          rts

Lab11C32  bsr       lab10a9a           ;*** 20mS delay via STOP instruction  ***
          andi.b    #$fd,$00018063    ;master chip status, display on
          ori.b     #8,$00018063      ;master chip status, 8 colour mode
          rts

Nikosdoykas, If your QBIDE does not have a RES_128 equivalent, you could try something like doing a n=RESPR(512*1024) before loading the game. To reserve all of your memory on the QBIDE, forcing the game into the QL's internal RAM.

If I try to run the game in QPC2, I get display problems, Not just running too fast. If I can get it to run in QPC2, it may point to the problem.

EDIT: I had a look at the display problem in QPC2. And I think it's the window manger getting in the way. After you press 'S' to start the game. The game draws a black window with a blue border around it by poking the screen display. It then opens a console window, displays the 'LEVEL 1' message, and then immediately closes the console window. When the window closes, the message, and a lot of the blue border underneath it also disappears. Which I assume is the window manger trying to restore the underlying screen and getting it wrong. This all happens so quickly that you don't see the message at all.

With the blue borders missing on the left and right sides, I suspect the ball has problems finding something to bounce off. Which probably causes other problems.


Martin_Head
Gold Card
Posts: 411
Joined: Tue Dec 17, 2013 1:17 pm

Re: ql superbomber and m-crunch ..and more things

Postby Martin_Head » Thu Mar 28, 2019 10:05 am

I've dug out a QL with an original Trump card fitted, and done some tests.

The Trump card has V2.17c ROM with TK2 v2.23. The QL has JS ROMs and I'm pretty sure it's an issue 5 PCB.

For all tests I always start the QL in Monitor (F1) mode.

If I run the game from mdv2_ (mdv1_ dose not work too well in this QL) then game plays without problems. with 896K, or 128K of RAM

If I run the game from flp1_, then I get all the described problems of lockups.

If I try my STOP patch, then I still get the lockups, But I did once get the game to start, but the display was vertically stretched, with the bat off the bottom of the screen.

I then tried my patch to stop the display being turned on and off. The game now runs on my Trump card system.

I don't know what's going on, why the game works from mdv, but not flp. Unless something in the game looks at at memory that is usually empty, but gets used by the flp driver.

Here's a copy of the boot program I am using
Attachments
TCfix.zip
(712 Bytes) Downloaded 18 times


User avatar
tofro
QL Wafer Drive
Posts: 1578
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: ql superbomber and m-crunch ..and more things

Postby tofro » Thu Mar 28, 2019 12:45 pm

Martin_Head wrote:
EDIT: I had a look at the display problem in QPC2. And I think it's the window manger getting in the way. After you press 'S' to start the game. The game draws a black window with a blue border around it by poking the screen display. It then opens a console window, displays the 'LEVEL 1' message, and then immediately closes the console window. When the window closes, the message, and a lot of the blue border underneath it also disappears. Which I assume is the window manger trying to restore the underlying screen and getting it wrong. This all happens so quickly that you don't see the message at all.

With the blue borders missing on the left and right sides, I suspect the ball has problems finding something to bounce off. Which probably causes other problems.


I suspect it's rather this:

QPC2 Manual on QPC_QLSCREMU wrote:Please also note that this transition is one-way only, i.e. bytes written legally to the first 512x256 pix-els are not transferred back to the original QL screen (in the case of a high colour screens this would hardly be possible anyway). Unfortunately, this also means that not all old programs will run perfectly with this type of emulation. If you experience problems, start the misbehaving application in 512x256 mode.


That means a call to BORDER is not going to modify the emulated original QL's screen memory. Probably nothing to do with the window manager. The issue could be fixed by drawing the border not with the system call but rather with direct writes to the screen.

Tobias


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
mk79
Gold Card
Posts: 356
Joined: Sun Feb 02, 2014 10:54 am

Re: ql superbomber and m-crunch ..and more things

Postby mk79 » Thu Mar 28, 2019 3:34 pm

tofro wrote:That means a call to BORDER is not going to modify the emulated original QL's screen memory. Probably nothing to do with the window manager.
Quite possible, yes. In QPC2 v5 the emulation is two-way, so changes in the hires screen are also reflected in the $20000 area (even if the hires screen is also high-colour!)


Martin_Head
Gold Card
Posts: 411
Joined: Tue Dec 17, 2013 1:17 pm

Re: ql superbomber and m-crunch ..and more things

Postby Martin_Head » Fri Mar 29, 2019 11:09 am

tofro wrote:That means a call to BORDER is not going to modify the emulated original QL's screen memory. Probably nothing to do with the window manager. The issue could be fixed by drawing the border not with the system call but rather with direct writes to the screen.

Tobias
The blue border is drawn by poking the display directly, And I am running QPC2 in 512x256, QL colour mode. So screen emulation should be correct.

If I trace through the program, the screen with the blue border is drawn correctly, Then a CONsole channel is opened, "Level 1" is displayed, then the channel is closed. At which point, the message disappears, along with most of the blue border on the screen. Whereas in QDOS the message would be left displayed. Hence I think the window manager is trying to restore the display under the console window when it is closed.

I don't know if you could use OUTLN to disable this action, or maybe change the size of the console channel that displays the level 1 message. But I think the biggest problem with the game in QPC2, is that QPC2 is just so fast that the ball has bounced about a bit, and gone off the bottom of the screen, before you have even seen it. I tried using SLUG to slow things down, but it does not help very much. It slows things down, but the ball does not so much move across the screen, as leap from one point to another.



Who is online

Users browsing this forum: No registered users and 2 guests