Search found 5 matches

by nesemu101
Tue Jan 19, 2021 1:43 am
Forum: NESemdev
Topic: My Nes emulator causes the main character's body in Kung Fu to split in half?
Replies: 7
Views: 2448

Re: My Nes emulator causes the main character's body in Kung Fu to split in half?

It could be a sprite 0 hit issue, or the execution time of the instructions. Are you keeping track of the CPU cycles relative to the PPU cycles? Many games will use timed code while the PPU is rendering in order to wait for specific moments and apply some sort of PPU effect, such as a scroll change...
by nesemu101
Mon Jan 18, 2021 2:22 am
Forum: NESemdev
Topic: My Nes emulator causes the main character's body in Kung Fu to split in half?
Replies: 7
Views: 2448

Re: My Nes emulator causes the main character's body in Kung Fu to split in half?

The main character in this game is drawn with background tiles, not sprites, so the game need to change the scroll mid-frame in order to control the positions of the background and the player. The scroll split is supposed to happen much closer to the top of the screen, so maybe this is a timing iss...
by nesemu101
Mon Jan 18, 2021 1:22 am
Forum: NESemdev
Topic: My Nes emulator causes the main character's body in Kung Fu to split in half?
Replies: 7
Views: 2448

My Nes emulator causes the main character's body in Kung Fu to split in half?

I've recently written my Nes emulator's ppu and almost every game(donkey kong, smb, ice climbers, balloon fight) runs fine except Kung Fu. Here's what happens to him: https://imgur.com/a/G4Chx8D https://imgur.com/a/G4Chx8D Does anyone have any idea as to what is causing this? I'm stuck and i can't f...
by nesemu101
Sun Jan 10, 2021 11:47 am
Forum: NESemdev
Topic: Could anyone help me figure out the flaws of my scrolling logic?
Replies: 3
Views: 2171

Re: Could anyone help me figure out the flaws of my scrolling logic?

isn''t this the loopy v and t method but? The formula is from converting from pixel coordinates to nametable byte using array maths and i just replaced x with x + sx where sx is the horizontal offset in pixels
by nesemu101
Sun Jan 10, 2021 9:04 am
Forum: NESemdev
Topic: Could anyone help me figure out the flaws of my scrolling logic?
Replies: 3
Views: 2171

Could anyone help me figure out the flaws of my scrolling logic?

I'm trying to write the scrolling portion of my nes emulator without using the loopy v or t registers but i'm stuck working out the maths and i was wondering if i could use a bit of help. I store the horizontal scroll position in a value sx and the vertical scroll position in sy but for smb, since t...