It is currently Fri Nov 17, 2017 10:40 am

All times are UTC - 7 hours





Post new topic Reply to topic  [ 131 posts ]  Go to page Previous  1 ... 5, 6, 7, 8, 9
Author Message
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Mon Sep 18, 2017 10:15 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
Oh my @#%(@# ... Wow, Finally squashed that one, turns out, it was in this part of the code:

Code:
 void handle_player_in_field(void)
 {
-  if ((stamps[STAMP_X(i)]==PIXEL_BOX_X(a)) && (stamps[STAMP_Y(i)]==PIXEL_BOX_Y(b)))
+   if ((stamps[STAMP_X(i)]==PIXEL_BOX_X(a)) && (stamps[STAMP_Y(i)]==PIXEL_BOX_Y(b)))
     {
       // We are aligned.
       if (PLAYER_PAD_RIGHT(i) && stamps[STAMP_LAST_STATE(i)] != STATE_PLAYER_RIGHT && !BOX_WALL_RIGHT(d))
-       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_RIGHT;
+       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_RIGHT;
       else if (PLAYER_PAD_LEFT(i) && stamps[STAMP_LAST_STATE(i)] != STATE_PLAYER_LEFT && !BOX_WALL_LEFT(d))
-       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_LEFT;
+       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_LEFT;
       else if (PLAYER_PAD_UP(i) && stamps[STAMP_LAST_STATE(i)] != STATE_PLAYER_UP && !BOX_WALL_UP(d))
-       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(d)]=STATE_PLAYER_UP;
+       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_UP;
       else if (PLAYER_PAD_DOWN(i) && stamps[STAMP_LAST_STATE(i)] != STATE_PLAYER_DOWN && !BOX_WALL_DOWN(d))
-       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(d)]=STATE_PLAYER_DOWN;
+       stamps[STAMP_STATE(i)]=stamps[STAMP_LAST_STATE(i)]=STATE_PLAYER_DOWN;
       else if (PLAYER_PAD_IDLE(i))
-         handle_pad_idle();
+         handle_pad_idle();




I was accidentally using (d) as an index into the stamps table, which in this case, literally was returning 0 if the opposing player had just aligned with the box.

*BLUSH* :)

welp, we all make mistakes, don't we? :)

Now it's on to shooting the phasor cannons and then to implement monster to cannon and monster to player collision. (I need to study the last one, it's not a bounding box detection, nor is it pixel detection, but I suspect it literally is a direct box alignment, need to observe.)

**WHEW** :)

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sat Sep 23, 2017 11:12 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
my OCD has gotten the better of me, and I'm spending the next couple of days shifting the maze downward, so that it can fit properly within NTSC overscan. which in my case means a minimum of one tile shift, but I'm doing two, so that the bottom of the dungeon will meet flush with the dungeon text, like it does in the arcade.

This does mean, that I had to make copies of the tops of my A-Z tiles, and paint horizontal rules above them to match the bottom of the dungeon. This also means that there currently is some attribute clash that I am working out, but the result will look a LOT better, when I'm done.

once this is done, I will start to implement player shooting.

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sat Sep 23, 2017 11:22 pm 
Offline

Joined: Sun Apr 13, 2008 11:12 am
Posts: 6437
Location: UK (temporarily)
Could you adjust the Y scroll instead?


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sat Sep 23, 2017 11:39 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
lidnariq wrote:
Could you adjust the Y scroll instead?


Not in this case, I'll post a before and after, and you'll see why i'm doing this.

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sat Sep 30, 2017 11:10 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
I was going to post this earlier, but nesdev was being moved. :)

So, I've managed to shift the playfield a bit down so that it looks a LOT better (there isn't that goofy gap between the dungeon and the dungeon name, and the radar, anymore.). I also color coded the player countdowns, and implemented teleporting (both players, as well as the enemies can utilize the teleport, which, given that it has a delay, definitely makes things interesting.)

https://www.youtube.com/watch?v=qYrk4bJcSeo

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sat Sep 30, 2017 11:13 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
Now i've got an interesting problem, I'm running out of CHR-ROM space for my sprites. Shit.

Basically, I need space for two things:

* The Wizard of Wor needs 36 CHR tiles (2x3, all different, can't reuse bits, 3 frames horizontal, and 3 frames vertical.)
* The between level messages need approximately 32 tiles a piece, of which there are basically four.

I've made the concession that the between level messages always wind up on their own screen. (instead of in the arcade where some of the messages appear over the playfield)

So basically, I need...two more CHR ROM banks. How can I best pull this off?

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sun Oct 01, 2017 6:09 am 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19219
Location: NE Indiana, USA (NTSC)
I've got a solution in mind, but to pull it off, I need to know the following:

  • Are there any pairs of enemies that never appear at once?
  • How much background manipulation are you doing during vblank?
  • How much PRG ROM space is free?


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sun Oct 01, 2017 8:23 am 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
The Worluk and the Wizard of Wor appear only once on the playfield, no other enemies present.

I'm doing my background manipulation very much interleaved, I spin between four background updating states:

* score (28 tiles)
* teleports (6 tiles)
* Doors (12 tiles)
* Box timers (up to 4 tiles)

and the memory map: https://i.imgur.com/ZoXgCe7.png .. which shows 14K of PRG left (but I haven't implemented the rest of gameplay yet.)

-Thom


p.s. And maybe the sprite CHR rom has enough space, because I calculated the space for all 6 different sprites, with 6 tiles each, with 6 possible states + 36 tiles for the player shooting, so that means 252 tiles... which once you add in the 3 radar dots and the laser, that's all the cells....wheee.)


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sun Oct 01, 2017 8:30 am 
Offline

Joined: Sun Sep 19, 2004 11:12 pm
Posts: 19219
Location: NE Indiana, USA (NTSC)
You should be able to store the CHR data in PRG ROM and copy it to CHR RAM, following these instructions. Then in levels with normal enemies, you can load their tiles, and in levels with the bosses, you can load their tiles.


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Sun Oct 01, 2017 3:44 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
tepples wrote:
You should be able to store the CHR data in PRG ROM and copy it to CHR RAM, following these instructions. Then in levels with normal enemies, you can load their tiles, and in levels with the bosses, you can load their tiles.


Cool! Thanks! :)

-Thom


Top
 Profile  
 
 Post subject: Re: WIP: Wizard of Wor
PostPosted: Mon Oct 16, 2017 10:08 pm 
Offline

Joined: Mon Jul 03, 2017 4:37 pm
Posts: 98
Am A/Bing my game/vs the arcade...not happy with the walk cycles.. going to mess with the delay and the frames so that the walking tweens are close enough.

Yeah..yeah...procrastinating on the shooting...but this is part of me trying to make sure what I have so far will withstand later testing and polishing.

Some may think this is nuts, but I _really_ want this to be good.

-Thom


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 131 posts ]  Go to page Previous  1 ... 5, 6, 7, 8, 9

All times are UTC - 7 hours


Who is online

Users browsing this forum: No registered users and 1 guest


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