Legend of Zelda (RPG game)

Use this forum to share and discuss Uzebox games and demos.
User avatar
nicksen782
Posts: 397
Joined: Wed Feb 01, 2012 8:23 pm
Location: Detroit, United States
Contact:

Legend of Zelda (RPG game)

Post by nicksen782 » Fri Mar 10, 2017 1:21 am

Hey! I know it's been a while but there is some progress on Zelda!

Since I've started with Uzebox my programming skills have changed dramatically. I've been learning along the way and I think that I am at a point where I can publicly show off the current progress of the game. Thanks Uzebox!

Features completed:
Sprite animation (player, enemies.)
Collision detection via lower-numbered tile ids.
Able to walk through the entire Hyrule Overworld.
Able to walk through the entire Hyrule Underworld (with reduced colors.)
When moving to the next screen an appropriate scroll transition effect is used. (game is -DSCROLLING=0 btw.)
Transition effects for open/close horizontally (open/close left/right by column.)
Title screen with flashing Triforce and rolling waterfalls (All ram_tiles.)
Title screen darkening that darkens based on timers rigged up with vsync counters.
Darkening (via DDRC modification) is done with a similar technique as FadeIn() and FadeOut() but with my own table.
Ability to open a message text box with text and font tiles from the SD card binary. (Unlimited messages as long as the font tiles used are <= RAM_TILES_COUNT.)
Can draw graphics with ram_tiles sourced from the SD card binary.
Inventory sub-screen will draw all the inventory items currently in your possession.
Ram_tile screens with scrolling effects.
Sound test menu.
Character structure that will hold positions, frames used, etc. Shared between all characters spawned.

Features being developed:
Music! I have some initial ports from D3thAdd3r.
Game structure that will hold all shared values in the game (such as the map X/Y and what world you are in, etc.)
Per map screen data structure that will contain data on enemy type, number of enemies, enemy location, secrets location, unlocked doors, bombed walls, locked doors, etc.

Features planned:
Initial 512 bytes of SD binary file to store game save data (need to figure out how to update that data on the SD card.)
Screen test menu.
SD binary save data viewer/editor.

NOTE: At any given point the public demo URL may or may not show some or all of the features. I update the public demo at solid points in development and mostly to make it easier to show people a certain stage of development. Additionally, I keep some old versions available there.


LINKS:
  • PUBLIC DEMO (updated often):
    http://www.nicksen782.net/r_uzezelda.php
    NOTE: If you want to use a local emulator or real Uzebox hardware you can download the files from the link above. In the "GAME LOADED" section on the upper left you will see 'file0', and 'file1'. Those the .uze and .bin files for the game.
UPDATES
  • UPDATE: 20170406:
    New features:
    Boss Manhandla! Consists of 5 individual characters moving in sync.
    Improved player/non-boss sprite to background tile collision detection.
    Sprite hit detection enabled.
    If player loses all hearts then the game over animation and screen appears.
  • UPDATE: 20170310:
    Triforce flashes at last intro screen. Press start at title screen to see every overworld and underworld screen VERY fast. Press select (may have to do it twice) to exit.
  • UPDATE 20170320:
    Intro screens fixed. Overworld and Underworld available to explore (most screen scroll transition effects are disabled currently.) Collision detection re-implemented. Press L or R to switch between Over/Underworld. Hold the X button to override collision detection (especially needed in the dungeons.)
LATEST DOWNLOADABLE VERSION:
UzeZeldaDemo2.zip
Version: 20170320
(41.12 KiB) Downloaded 34 times
ALWAYS UP TO DATE VERSION: http://www.nicksen782.net/r_uzezelda.php
Last edited by nicksen782 on Thu Apr 06, 2017 6:19 pm, edited 4 times in total.

User avatar
uze6666
Site Admin
Posts: 4337
Joined: Tue Aug 12, 2008 9:13 pm
Location: Montreal, Canada
Contact:

Re: Legend of Zelda (RPG game)

Post by uze6666 » Fri Mar 10, 2017 2:49 am

Hey, nice come back, I though this one was dead for good! Pretty good start on the intro music. However I can't seem to pass the intro (I'm running on the harware)...is that normal? Also wondering, why not mode3 with scrolling for the game/intro?

User avatar
nicksen782
Posts: 397
Joined: Wed Feb 01, 2012 8:23 pm
Location: Detroit, United States
Contact:

Re: Legend of Zelda (RPG game)

Post by nicksen782 » Fri Mar 10, 2017 3:38 am

Yeah, I should have been more clear. I have the code in there for the game and movement and such but right now the game is locked to the title screen. That's what I have been working on. Each of those screens takes 0 flash tiles.

User avatar
D3thAdd3r
Posts: 2184
Joined: Wed Apr 29, 2009 10:00 am
Location: Minneapolis, United States

Re: Legend of Zelda (RPG game)

Post by D3thAdd3r » Fri Mar 10, 2017 3:39 pm

Pretty good progress, I'd suggest people take a look at the other roms on the wiki link too. There you can move around the overworld and there is enemy animations/etc, cool stuff. Kudos for keeping at this, it is a big project for sure and you keep tackling it piece by piece.

Music will need to get touched over and finished, sound effects are not far off. For the PCM stuff not really sure what to say yet as the most direct PCM solution takes massive space. Perhaps a custom HSYNC that allows 1 bit ADPCM like NES. In general I think we should have some mechanism to cleanly have custom HSYNCs for games.

Not sure how open you are to investigating different technology at this point in development. IMO a 4bpp non-scrolling video mode would make this all much easier and the result could be closer to original than what could be done with mode 3. SD music streaming(since you already have the SD card as requirement) seems like something that needs to be done also. MOD or a custom format still takes space and converting that would probably be as much work as the superior result of streamed MIDI.

Did you ever have a demo showing the Underworld? I thought you did but can't' seem to find it.

User avatar
nicksen782
Posts: 397
Joined: Wed Feb 01, 2012 8:23 pm
Location: Detroit, United States
Contact:

Re: Legend of Zelda (RPG game)

Post by nicksen782 » Fri Mar 10, 2017 4:20 pm

NOTE: The original upload is JUST the title screen stuff. The next big update will have actual player movement and world exploration enabled. It's coming!
uze6666 wrote: Also wondering, why not mode3 with scrolling for the game/intro?
Mode 3 with scrolling is what I originally started with. However, scrolling isn't critical to the game and adds complexity that I just don't want to deal with. Besides, the screen can scroll well enough without it. You'll see this on the screen transitions in the overworld/underworld/subscreen.
D3thAdd3r wrote: I'd suggest people take a look at the other roms on the wiki link too.
Yes, I do have some older versions there and I do intend to update the list at solid development points.
D3thAdd3r wrote: Music will need to get touched over and finished, sound effects are not far off.
Flash is really at a premium considering all the tiles for the worlds and sprites. Anything that can be streamed from SD has my interest, especially big data-hogs like music. Not so sure if sound effects should be streamed.
D3thAdd3r wrote: IMO a 4bpp non-scrolling video mode would make this all much easier and the result could be closer to original than what could be done with mode 3.
I'm not opposed to this actually although it is out of my current experience zone. I keep seeing the need to look at the ASM of the kernel and I am pretty sure that I cannot escape learning some ASM. If that is the case then so be it. I will learn some ASM.
D3thAdd3r wrote: Did you ever have a demo showing the Underworld? I thought you did but can't' seem to find it.
Yes, a demo was active at one point with it when I was working on the screen scroll transitions and subscreens. It is not currently active. I'll be re-enabling it when I finish refactoring that code.
Last edited by nicksen782 on Mon Mar 13, 2017 9:48 am, edited 1 time in total.

User avatar
D3thAdd3r
Posts: 2184
Joined: Wed Apr 29, 2009 10:00 am
Location: Minneapolis, United States

Re: Legend of Zelda (RPG game)

Post by D3thAdd3r » Fri Mar 10, 2017 5:34 pm

nicksen782 wrote:Not so sure if sound effects should be streamed.
Streamed music I think is doable on all cards, just that it might take a lot more cycles on some and break thing? I think it is not possible to stream the music and PCM from the card simultaneously anyways. I think the game will have to do without PCM unless some miraculous space savings is found, since I imagine space was already tight before the (possibly streamed free) music was added.

Video modes, there are so many of them possible but then when you get to the 4bpp stuff there becomes lots of trade offs. I don't think M74 fits the game since every screen would need to be drastically narrowed which affects gameplay(not really in the underworld though). Mode 13 non-scrolling could be great if it can be made to work with multiple 128 rom tile banks, but I don't think it currently does so. A difficult change to make especially if it requires custom video mode, but it does seem like an immense benefit in the end...if you can then blit the sprites fast enough...otherwise then requiring shorter screen...lots of things to consider for sure but getting the core going like you are doing seems the smartest thing to do first.

User avatar
Jubatian
Posts: 903
Joined: Thu Oct 01, 2015 9:44 pm
Location: Hungary
Contact:

Re: Legend of Zelda (RPG game)

Post by Jubatian » Fri Mar 10, 2017 6:29 pm

Nice intro, I actually like the music :)

What about this video mode concept? Mode 64 - does anyone want it

Mode 64 could give you 128 4bpp ROM tiles, some 1bpp ROM tiles, and the rest 4bpp RAM tiles, and it could use Mode 74's quite fast blitter.

In an alternative Mode 13 (that is sticking to LDD-LDD instead of LD-SWAP-LD which M74 uses) you could possibly have multiple tile banks displayed (the 4 extra cycles compared to M64 / M74 tile cycle budget could permit this) at the cost of needing a slower blitter (due to the remapping necessary to work with LDD-LDD).

Just ideas. I am rather exhausted recently, though, I wouldn't likely do much work with video modes these days.

User avatar
nicksen782
Posts: 397
Joined: Wed Feb 01, 2012 8:23 pm
Location: Detroit, United States
Contact:

Re: Legend of Zelda (RPG game)

Post by nicksen782 » Fri Mar 10, 2017 6:59 pm

I don't really understand the other video modes yet. They sound nice but at this point I'm not having issues with slowdown.

If flash tiles could take up less space that would be a plus.

If music could be compressed and/or retrieved from SD that would be great.

I don't think I am ready to switch video modes at this point. I will be considering this over time though since I need to refactor often to make better use of resources. My ram tile screen drawing functions are really going to come in handy for things like credits... or cut scenes (Ninja Gaiden anyone?)

User avatar
nicksen782
Posts: 397
Joined: Wed Feb 01, 2012 8:23 pm
Location: Detroit, United States
Contact:

Re: Legend of Zelda (RPG game)

Post by nicksen782 » Mon Mar 13, 2017 9:41 am

New progress!

I've rewritten and then rewritten again the ram tile draw and scroll functions. Less code, more predictable.

I've added a proper music test mode. Access it by pressing SELECT at the main title screen. There is a sprite on the screen (flash tile) for a cursor. I used SetUserRamTilesCount() and gave it the number of unique tiles in the ram tileset. This way, the sprite blitter will leave those ram tiles alone and I can still have sprites.

Increased the dimensions used by the first scrolling intro screen. The new draw routines break up the ram tileset and the map in different stages. Step 1: Load ram tile set. Step 2: Draw rows from ram tile map, directly to vram instead of the ram_tiles array. You don't need the whole map in memory if you are scrolling up or just drawing the whole screen at once.

Also, I've made some changes to my UAM toolset. Each of these ram tilemaps have their own individual tileset. A gConvert XML file supports 1 tileset. Or, more accurately, gConvert will only output 1 tileset. I modified my gConvert and changed some of its behavior. I still use XML files like the official gConvert but now I enclose each ram tileset in a <tileset> tag. The software runs gConvert on each one. There is also a save all feature. The intro screens have 14 separate screens.

You can see the public demo version here (updated often):
http://www.nicksen782.net/r_uzezelda.php

If you want to use a local emulator or real Uzebox hardware you can download the files from the link above. In the "GAME LOADED" section on the upper left you will see 'file0', and 'file1'. Those are the .uze and .bin files for the game.

... I'm going to work on the logic for the 'PLAYING' gamestate... Ya know, the actual game. ;)

User avatar
uze6666
Site Admin
Posts: 4337
Joined: Tue Aug 12, 2008 9:13 pm
Location: Montreal, Canada
Contact:

Re: Legend of Zelda (RPG game)

Post by uze6666 » Sun Mar 19, 2017 3:17 pm

Underworld!! :mrgreen: Very cool to see these graphics on the Uzebox, nice progress, keep it up!

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest