It is currently Mon Dec 11, 2017 9:45 pm

All times are UTC - 7 hours





Post new topic Reply to topic  [ 266 posts ]  Go to page Previous  1 ... 9, 10, 11, 12, 13, 14, 15 ... 18  Next
Author Message
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 4:01 pm 
Online

Joined: Sun Apr 13, 2008 11:12 am
Posts: 6509
Location: Seattle
NES Screen tool makes it easier to draw a screen for the NES, or set of screens.

To actually display on a NES, you will still need a little bit of program, but it's a task that could easily be done using cc65.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 4:02 pm 
Offline
User avatar

Joined: Sun Jan 22, 2012 12:03 pm
Posts: 5891
Location: Canada
caramelpuffpuff it is just a very nice tool for making NES screens. The nicest, actually.

It's not "needed"; there are lots of ways to make an NES screen. For example, some people just type nametables out as hex numbers in the assembly code. Shiru's tool is really convenient though, since it already obeys all the NES rules.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 5:17 pm 
Offline
User avatar

Joined: Sat Feb 23, 2013 4:16 pm
Posts: 63
RainyHero, so is this tool, "universal-usage" or "exclusive-usage", which is only use for certain games only, like SMB3 tools? And is this tool usable to everything I'd use it on, like title screen, background, game-over, stages, selection, etc? Or it has limitations/more than I said?

_________________
I am thinking of requesting a tutor [free] to learn NES programming in 6502 Assembly, as I am still baffled on the Bunnyboy 6504 lessons. If anyone want to help, I'm happy.
Bear in mind I may act silly or have trouble understanding, so please bear with me.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 6:00 pm 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19334
Location: NE Indiana, USA (NTSC)
It can be used on any screen, but some things related to nametables (such as collision or heavy compression) are best done with specialized tools.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 6:35 pm 
Offline
User avatar

Joined: Sat Feb 23, 2013 4:16 pm
Posts: 63
Is nametable the "entire group" of sprites and graphics and backgrounds? Or the is term is different?

_________________
I am thinking of requesting a tutor [free] to learn NES programming in 6502 Assembly, as I am still baffled on the Bunnyboy 6504 lessons. If anyone want to help, I'm happy.
Bear in mind I may act silly or have trouble understanding, so please bear with me.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 6:37 pm 
Online

Joined: Sun Apr 13, 2008 11:12 am
Posts: 6509
Location: Seattle
"pattern table" is the term for the group of small 8x8 pixel pictures that are combined to make sprites and backgrounds.

Name table is the term for the list of numbers that say what pattern table pattern is drawn where in the background.


Last edited by lidnariq on Thu Nov 07, 2013 6:39 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 6:39 pm 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19334
Location: NE Indiana, USA (NTSC)
A background consists of three parts of video memory: the pattern table ($0000-$0FFF), the nametable ($2000-$23FF), and the palette ($3F00-$3F0F). The pattern table is the 256 tiles, the nametable is a 32x30-tile map plus a 16x15-area coloration map that tells which part of the palette each 2x2 block of tiles uses. Sprites use OAM (a separate memory space) and typically use the other pattern table ($1000-$1FFF).


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 07, 2013 6:44 pm 
Offline
User avatar

Joined: Sat Feb 23, 2013 4:16 pm
Posts: 63
Oooooooooooooh. So nametable it's a file-code to organize on what sprites and background it appears and what does not.

_________________
I am thinking of requesting a tutor [free] to learn NES programming in 6502 Assembly, as I am still baffled on the Bunnyboy 6504 lessons. If anyone want to help, I'm happy.
Bear in mind I may act silly or have trouble understanding, so please bear with me.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Wed Nov 13, 2013 6:28 pm 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
Could you add export for nametable as .asm text file with .byt/.db instructions? I've found out that easiest method to put nametable into memory is to divide it into 6 "segments", each of 5 rows so we can load it each by 160 bytes with 6 loops, like this:

Code:
loop:
   lda face,y
   sta PPUDATA
   iny
   sty $A1
   lda $A1
   cmp #160
   bne loop
   ldy #00
   loop2:
   lda face2,y
   sta PPUDATA
   iny
   sty $A1
   lda $A1
   cmp #160
   bne loop2
   ldy #00
  ;snip for rest of loops as they are largely same

To do that, I need to put symbols (labels) every 5 rows of nametable, so I need text output (hex numbers) instead of binary (.nam files).


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Wed Nov 13, 2013 6:41 pm 
Offline
User avatar

Joined: Wed Apr 02, 2008 2:09 pm
Posts: 1046
You could split the binary file yourself using python/whatever other languages you know, or just add 160 to the pointer each time in 6502.

_________________
https://kasumi.itch.io/indivisible


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Wed Nov 13, 2013 6:42 pm 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19334
Location: NE Indiana, USA (NTSC)
You can copy a whole nametable from one label with (d),Y addressing mode. Load a pointer into two adjacent zero page locations, increase Y after each byte, and when Y wraps, increase the high byte of the pointer.


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Wed Nov 13, 2013 6:55 pm 
Offline

Joined: Sat Jan 23, 2010 11:41 pm
Posts: 1161
It is already possible, sans nametable attributes - just select the whole nametable, then Nametable/Put selection to clipboard as ASM.

Also, you can normally define labels as an absolute address or an expression, so you probably can just do something like

Code:
part1
part2=part1+160
part3=part2+160
...
 incbin "nametable.bin"


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 14, 2013 3:20 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
tepples wrote:
You can copy a whole nametable from one label with (d),Y addressing mode. Load a pointer into two adjacent zero page locations, increase Y after each byte, and when Y wraps, increase the high byte of the pointer.

Yeah, but my way is easier (and until it makes game too slow I'll keep it)

@Shiru: Thanks, will try that!


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Thu Nov 14, 2013 8:41 am 
Offline
User avatar

Joined: Mon Jan 03, 2005 10:36 am
Posts: 2982
Location: Tampere, Finland
darkhog wrote:
Code:
  ;snip for rest of loops as they are largely same

And this is when you should use macros. On ca65, you can even use macros to generate the labels Shiru was talking about.

_________________
Download STREEMERZ for NES from fauxgame.com! — Some other stuff I've done: kkfos.aspekt.fi


Top
 Profile  
 
 Post subject: Re: NES Screen Tool
PostPosted: Sat Nov 16, 2013 9:30 am 
Offline

Joined: Tue Jun 28, 2011 2:39 pm
Posts: 152
thefox wrote:
darkhog wrote:
Code:
  ;snip for rest of loops as they are largely same

And this is when you should use macros. On ca65, you can even use macros to generate the labels Shiru was talking about.

Shutup, I'm still learning ;).

Anyway, I suppose I'll eventually convert it into macro as I am big fan of code reuse, but first I want to make something that works. Then I will learn how to do it properly, but so it'd still be working.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 266 posts ]  Go to page Previous  1 ... 9, 10, 11, 12, 13, 14, 15 ... 18  Next

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group