Displaying Debug Info and User Lives, Score, Bomb, etc.

Ask anything your want about Megadrive/Genesis programming.

Moderator: BigEvilCorporation

Post Reply
MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Displaying Debug Info and User Lives, Score, Bomb, etc.

Post by MintyTheCat » Tue Sep 24, 2013 9:21 pm

Hello all,

I can see a need for being able to display Debug Information using either Sprites or one of the Planes for development and also being able to display the Player's Score, Lives, Bombs. etc.

I was wondering, is the Window Plane meant to be used for this sort of thing?

Also, can anyone give any Examples of MD Games that use the Window a fair amount?

I want to know if it's generally better to implement Scores, Lives, etc using Sprites with higher priorities or to use the Window if indeed it is meant to be used as such. Any Ideas, anyone?

Cheers.

KanedaFr
Administrateur
Posts: 1139
Joined: Tue Aug 29, 2006 10:56 am
Contact:

Post by KanedaFr » Wed Sep 25, 2013 10:01 am

I made this mistake when I developed my first "game" (ooga booga)

I don't remember what I did but using window disabled my plane A :(
so be careful with window...I personnaly avoid it since that time !

else look at the doc, since I surely missed something

MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Post by MintyTheCat » Wed Sep 25, 2013 10:24 am

KanedaFr wrote:I made this mistake when I developed my first "game" (ooga booga)

I don't remember what I did but using window disabled my plane A :(
so be careful with window...I personnaly avoid it since that time !

else look at the doc, since I surely missed something
Aha.... So:

1. What is Window meant to be used for?

2. Did you have some kind of Priority Issue wrt the Rules for the MD's VDP's Plane-A, Plane-B, Window, Sprite, etc having priority and did you investigate it further to find out why your Plane-A was disabled?

3. Which document are you referring to?

The aim here is to work out firstly what the Window is good for and then to work out how to use it.

Cheers.

TmEE co.(TM)
Very interested
Posts: 2440
Joined: Tue Dec 05, 2006 1:37 pm
Location: Estonia, Rapla City
Contact:

Post by TmEE co.(TM) » Wed Sep 25, 2013 11:55 am

Window is the non scrollable tilemap that can grow out of 2 sides of the screen.
Window behaves exactly like BG A, and replaces BG A whatever the Window occupies.

Thunder Force III and IV, Devil Crash MD, Cool Spot to name some use it for their status bars.

I find it incredibly useful.
Mida sa loed ? Nagunii aru ei saa ;)
http://www.tmeeco.eu
Files of all broken links and images of mine are found here : http://www.tmeeco.eu/FileDen

KanedaFr
Administrateur
Posts: 1139
Joined: Tue Aug 29, 2006 10:56 am
Contact:

Post by KanedaFr » Wed Sep 25, 2013 8:36 pm

if it replaces A, why not simply use A with correct scroll value ?!

TmEE co.(TM)
Very interested
Posts: 2440
Joined: Tue Dec 05, 2006 1:37 pm
Location: Estonia, Rapla City
Contact:

Post by TmEE co.(TM) » Wed Sep 25, 2013 8:47 pm

But then you lose one BG layer :P

W replaces A wherever W is.
Mida sa loed ? Nagunii aru ei saa ;)
http://www.tmeeco.eu
Files of all broken links and images of mine are found here : http://www.tmeeco.eu/FileDen

Mask of Destiny
Very interested
Posts: 616
Joined: Thu Nov 30, 2006 6:30 am

Post by Mask of Destiny » Wed Sep 25, 2013 10:17 pm

KanedaFr wrote:if it replaces A, why not simply use A with correct scroll value ?!
If you're not using vertical scrolling, it's pretty straightforward to use a row or two of Scroll A by using column or line horizontal scrolling. If you're using vertical scrolling though, there's no way to keep the HUD from scrolling with everything else unless you use the window plane.

MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Post by MintyTheCat » Thu Sep 26, 2013 6:30 pm

TmEE co.(TM) wrote:Window is the non scrollable tilemap that can grow out of 2 sides of the screen.
Window behaves exactly like BG A, and replaces BG A whatever the Window occupies.

Thunder Force III and IV, Devil Crash MD, Cool Spot to name some use it for their status bars.

I find it incredibly useful.
Thank you! I loaded up Devil's Crash using an Emulator and can see exactly how the Window is used on the Pinball Table :D

I then wrote a small Experiment to display a Score, Lives and Bombs on the Window.

My Settings:

Reg #17: 00 : 0 Cells from left.
Reg #18: 02 : 2 Cells from bottom.

0x9100
0x9202

I am actually using vertical and horizontal scrolling so I shall update you once I've added the Window handling code into the Scroller.

Thanks for the Advice.

MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Post by MintyTheCat » Thu Sep 26, 2013 6:33 pm

TmEE co.(TM) wrote:But then you lose one BG layer :P

W replaces A wherever W is.
I found that there are Rules here to be followed. I have not tried out every combination of overlaying Plane-A, B, Sprite, Window with and without Priority set but I'd wager that Window was meant to used as the highest Priority Plane so it makes perfect sense to me to use it instead of some priority setting for Plane-A.

MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Post by MintyTheCat » Thu Sep 26, 2013 7:05 pm

Mask of Destiny wrote:
KanedaFr wrote:if it replaces A, why not simply use A with correct scroll value ?!
If you're not using vertical scrolling, it's pretty straightforward to use a row or two of Scroll A by using column or line horizontal scrolling. If you're using vertical scrolling though, there's no way to keep the HUD from scrolling with everything else unless you use the window plane.
My next Experiment will be to try my Vertical Scroller using the Window. I also allow horizontal scrolling too when the Player presses left or right up to a limit so this is directly applicable to my case - cheers.

MintyTheCat
Very interested
Posts: 484
Joined: Sat Mar 05, 2011 11:11 pm
Location: Berlin, Germany

Post by MintyTheCat » Wed Oct 09, 2013 12:05 pm

Hello all,

I can report that Window works correctly with my Vertical Scroller. Window displays some basic Player State Parameters for Score, Lives and Bombs. In my Demo the Player presses A,B or C Buttons to circularly increment the Values for the Parameters. There are no issues with priority and I can say that the Window serves the original Purpose that I had expected of it.

Many thanks for the Comments, Blokes.

Post Reply