News:

Don't forget to visit the main site! There's lots of helpful docs, patches, and more!

Main Menu

Super Metroid Maker

Started by gurno, March 24, 2023, 12:38:22 PM

Previous topic - Next topic

gurno

So far so good generating randomized maps w/ structured exploration/key/bosses/routes/etc. Working on formalizing bosslocks which dovetails into some of the more creative aspects of the mazemaking process. It's nice getting focus on the fun stuff like room/map/puzzle design logic now.

Quick Build-to-Play Demo:
https://www.youtube.com/watch?v=rLTLqxvWqh4

VacantShadeGames

This looks really cool!
Is it generating the individual rooms too?

gurno

Quote from: VacantShadeGames on March 24, 2023, 07:00:28 PM
Is it generating the individual rooms too?

Yes indeed. It takes the larger map & regions and breaks them down into smaller spaces and goes from there.

Zhs2

I feel uncomfortable around the idea of collecting some item and experiencing zero feedback about which doors opened up anywhere from one to one million miles away. It triggers my Metroid Mission Rescue PTSD.

RT-55J

This looks extremely neat and I am interesting at seeing how far you can take this.

gurno

Quote from: RT-55J on March 25, 2023, 01:26:55 AM
This looks extremely neat and I am interesting at seeing how far you can take this.

Thanks! I'm making it up as I go haha. Still such a fun game even to this day.

TobiMikami

I've actually seen this done with LUA in Zelda games like the random maze generator in Metroid Prime where the dungeons are standard but each playthrough the room layout is a bit different.

I think the concept is interesting, after all it's like, a level randomizer lol. My only concern really is with AI in general. I find game design and programming to be a sense of accomplishment and enjoyment. I fear one day AI may replace creativity as a whole, considering Unity wants to incorporate all this AI crap to do everything for you. I think we should know it's place, stuff like this, it's absolutely awesome for. But too far and it becomes the communist bloc. Super Metroid #9, now available in gray!

gurno

This saves me the trouble of coming up with an overworld map and key/boss/lock layouts. I can randomize and tweak exploration design until I find a build I like and then mod from there. It can be any number of keys and with adjustable amounts of criss-crossing exploration; lots of flexibility in how to build worlds. This is where I'm living right now as I build out more map planning logic on top of some quality of life features (e.g. using the mouse to draw your own regions/define other restrictions on the world map build). Even the way mazes plot can be heavily influenced so I want to tie that to different regions to mix it up further. The notes on this stuff I've been amassing is pretty nutty and this should keep me busy until around 2045 :)

Now I'm wondering how far I take individual room building. Tools like SMILE already do a better job at letting users design/modify levels. I have some basic room crafting in place that's macro'd right now but can be done on an individual room by room basis, too:

https://i.imgur.com/ECCh1eZ.mp4
https://i.imgur.com/GYF4Yvl.mp4
https://i.imgur.com/nUG1CuV.mp4

VacantShadeGames

Oh, I may have misunderstood the intent of the project at first!

Is the idea to essentially generate a base rom hack layout with progression, ect, that should then be hand crafted/tweaked through SM editors? Basically helping creators kickstart a personal project.

Or is it to essentially be a "make hack" button that does everything including tiling/theming the individual rooms, ect? Which would be geared more toward players who want a unique randomized SM run.

gurno

Quote from: VacantShadeGames on March 25, 2023, 12:18:08 PM
Oh, I may have misunderstood the intent of the project at first!

Is the idea to essentially generate a base rom hack layout with progression, ect, that should then be hand crafted/tweaked through SM editors? Basically helping creators kickstart a personal project.

Or is it to essentially be a "make hack" button that does everything including tiling/theming the individual rooms, ect? Which would be geared more toward players who want a unique randomized SM run.

It's both of those. In getting all the technical bits working (bosses, keys, progression, items, item locks, etc.) I have the "make hack" button that populates everything according to some basic rules so it's a playable game. From there I figure you can add/subtract/modify as you see fit using the better, more purpose-built editors. This is by no means a replacement for a well built romhack but I also want an absolute beginner to be able to start the program, hit a button, and be able to dive right in. The idea of managing pointers and level data when coming up with a larger world design didn't seem too appetizing to me. This way my nephew can play and create his own 10-room adventure which makes him happy.

TobiMikami

I kinda know what you're saying it's like that Seinfeld AI where it has so many basic rooms and posturing to generate, I think I remember the Skyrim devs saying something about having rneric "base rooms" they had to manually drag and drop, it sounded a lot like map tiles in Super Metroid, but as if the whole 3D room layout was generated as a base and then I'd imagine they'd skin the graphics like we'd tile over the objects but still, to have something randomly throw together a logical map of these pre generated map tiles and rooms, that's enigh to get someone saying alright keep this and throw that away. It's no different than what I do really, I have tons of randomly put together rooms that can be connected as halls and shortcuts and build the map off the way they begin to work with other rooms. I think this could have some potential.

gurno

Quote from: TobiMikami on March 26, 2023, 11:38:20 PM
I kinda know what you're saying it's like that Seinfeld AI where it has so many basic rooms and posturing to generate, I think I remember the Skyrim devs saying something about having rneric "base rooms" they had to manually drag and drop, it sounded a lot like map tiles in Super Metroid, but as if the whole 3D room layout was generated as a base and then I'd imagine they'd skin the graphics like we'd tile over the objects but still, to have something randomly throw together a logical map of these pre generated map tiles and rooms, that's enigh to get someone saying alright keep this and throw that away. It's no different than what I do really, I have tons of randomly put together rooms that can be connected as halls and shortcuts and build the map off the way they begin to work with other rooms. I think this could have some potential.

I absolutely wanted to stay away from prefab rooms to maintain Euclidean geometry throughout, so taking it from a top-down map-to-level perspective made the most sense to me. The slice and dice that's taking place to convert the map into smaller room segments can be tweaked to restrict room sizes. Right now I still have it set to the max that the game can allow so I think max 16 screens h/w and/or 50 screens iirc. We're getting some pretty gargantuan rooms at the moment lol

I'm pumped for where this can lead. It's such a headache learning how to mod such a cool game for a beginner.

I have some crap this morning but will post an .IPS later on and maybe someone smarter than myself can make it work in SMILE. I have it outputting the offsets for the roomheaders and level data headers but haven't gotten it to open yet (although the ROM works fine for SNES9x).

Gotta kick this thing into an online instance so people can design, draft, and download their own prefab games to mod and play with. Ughhhhh....so much crap to do lol


H A M

SMART can detect room headers and export MDB  to SMILE by saving to rom

gurno

I don't think I know what SMART is plus I'd have to learn some new software. I still can't get this thing to work! I've included the level_entries and mdb files but I probably broke something somewhere. It's weird because if you open up the ROM without replacing level_entries or mdb then you at least get the first room. I bet it's something simple. I don't even really know how to use SMILE beyond when I started reading the tutorials and then decided to go this route with building an overworld map first. One day!

Anyways, I've attached a very boring ROM hack that took about 3 seconds to create on auto-populate. It has seven "keys" which are energy tanks that further open up the map's gray doors. There are only the same random enemies scattered about each room because this is an auto build. There are no items beyond the e-tanks and this is very very boring so don't think I'm kidding.

Included screenshots showing the map routes. It's something I haven't figured out how to do yet because I actually am generating the map data in conformance with the ROM (scaled, of course), but there is more to how maps work than meets the eye. I think I need to define some other weirdness in the game to make it works. You'll want to use the map routes I've included unless you like drawing your own.

Enjoy the ennui!!! Someone help me figure out how to roll credits I have no idea how to end the game.


H A M

here's how to roll credits:

Quote from: OmegaDragnet9 on March 07, 2023, 10:15:24 PM
Thanks TobiMikami, Aran Jaeger, and Quote58 for the input last week. Tiling and graphic Resources and tips are always appreciated.

Here's a modification to PHOSPHOTiDYL's No Planet Explosion script. I realized was a simple hijack to give the ending credits music again. The solution was right under my nose:

Edit: Realized what I had was inadequate as I was not properly silencing sounds from Libraries 1, 2, and 3. So I wrote to free space to properly silence all offending sounds before the credit roll.

Also tried to comment my changes better.

lorom

;Code by PHOSPOTiDYL
;Music Hijack OmegaDragnet7

;--------------------------------------------------------------;
org $828506 : lda #$de80 ;//[no planet explosion] instead of lda LDA #$D480 which is cinematic function $D480.

org $82850F ;Music Hijack

LDA #$0000 ;Track 0
JSL $808FC1
LDA #$FF0F  ;Song Set 0F
JSL $808FC1
LDA #$0005  ;Song 05
JSL $808FC1
LDA #$0002  ;Sound 2, sound library 1, silence
JSL $82F70F ;JSL to Freespace

org $82F70F ;Freespace

JSL $809021
LDA #$0071  ;Sound 71h, sound library 2, silence
JSL $8090A3
LDA #$0001  ;Sound 1, sound library 3, silence
JSL $809125
RTL

org $8be7b5 : jsl screwcreditz ;instead of JSL $80824F which is "Write Super Metroid to SRAM" hijack
org $8bfd00
screwcreditz:
lda #$381a : sta $7e319c : sta $7e31dc : sta $7e31a2 : sta $7e31e2 ;//[:]
ldx #$0000 : lda $09e0 : jsr timemath
ldx #$0006 : lda $09de : jsr timemath
ldx #$000c : lda $09dc : jsr timemath : rtl
timemath:
sta $4204 : jsr mathone : jsr mathreset : lda $4214 : jsr tricktimeone
lda $4216 : jsr tricktimetwo : rts
tricktimeone:
asl a : asl a : tay : lda $e741,y : sta $7e3198,x : lda $e743,y : sta $7e31d8,x : rts
tricktimetwo:
asl a : asl a : tay : lda $e741,y : sta $7e319a,x : lda $e743,y : sta $7e31da,x : rts
mathone:
sep #$20 : lda #$0a : sta $4206 : rts
mathreset:
rep #$20 : rts
;--------------------------------------------------------------;

Quote from: OmegaDragnet9 on January 02, 2023, 04:08:19 PM
On the Discord channel, Smiley was kind enough to provide me a disassembled version of squishy_ichigo's Endgame BTS. However, every time I applied it to my ROM, grapple beam would crash the game even when used against normal air tiles.

After a brief discussion amongst Oi27,  P.JBoy, and myself, Smiley pointed out the original freespace just happens to coincide with where Grapple Beam operates in the code.

Fortunately there is another suitable freespace alternative in Bank $94, so I repointed there.

I decided to post here so others can use this. Thanks to Smiley for pointing that out and Oi27 and P.JBoy for helping me troubleshoot.

Original Endgame BTS by squishy_ichigo.

gurno

Quote from: H A M on March 27, 2023, 07:52:53 PM
here's how to roll credits:

Oh dang - I've never seen this before. Thank you!!! Hopefully I can figure out how to make this trigger when some end condition is satisfied.

TobiMikami

When you said large rooms my first thought was to suggest maybe you could find some way to script a criteria for "types of rooms" even if it has to be with mathematical logic like rectangle 1x width by 4x height 1:4 ratio for shafts or inverse 4:1 for halls, have the units represent scroll boxes? It's the same as my viewport/screen size, my map engine functions off of a similar logic which is based on Super Metroid and the 2D metroid's maps anyways. Either way it sounds like you have a pretty solid idea of what you're doing though, I'm almost envious. I've only just discovered the wonders of scripting AI, State Machines and math formulas that combined with scripts are just amazing.

Also SMART is an improved version of SMILE, which is open source. I'm pretty sure they used the original as a basis, but it's got more tools for repointing stuff and doing HEX tweaks, like doors and stuff. I think they said it also overwrites free space in different banks when the room space is full instead of overwriting your ROM. I haven't played with it myself as SMILE was the only tool on the playground when I was hacking before I took to my own Metroid engine. From what I hear though, that's something you'd almost need for something this ambitious. Otherwise the best people to ask as far as integration of this into SMILE, I'd say try and talk to the guys who made SMART, or maybe Scyzer too.

gurno

Quote from: TobiMikami on March 28, 2023, 12:02:38 AM
When you said large rooms my first thought was to suggest maybe you could find some way to script a criteria for "types of rooms" even if it has to be with mathematical logic like rectangle 1x width by 4x height 1:4 ratio for shafts or inverse 4:1 for halls, have the units represent scroll boxes? It's the same as my viewport/screen size, my map engine functions off of a similar logic which is based on Super Metroid and the 2D metroid's maps anyways. Either way it sounds like you have a pretty solid idea of what you're doing though, I'm almost envious. I've only just discovered the wonders of scripting AI, State Machines and math formulas that combined with scripts are just amazing.

Funny because what you just described is how a lot of it is built at the moment. Room sizes are cool because they can be anything at all. Logic right now is to examine rooms and shape them down further by adding walls and doors in advantageous spots. This is primarily to constrain rooms for the SM engine itself however you can script this to create larger or smaller rooms at different points/regions of the map. Same would go for room shapes during the maze making process; Tourian should look different than Maridia imo.

Here's an 88 key map with larger rooms too big for the engine, but chopped up so it all fits:
https://i.imgur.com/IVSosBJ.png

Next step is adding different shapes like circles, arches, or whatever looks nice. I also want to allow the user to pre-fill some room shapes of their own before building the maze around/through it.

Quote
Also SMART is an improved version of SMILE, which is open source. I'm pretty sure they used the original as a basis, but it's got more tools for repointing stuff and doing HEX tweaks, like doors and stuff. I think they said it also overwrites free space in different banks when the room space is full instead of overwriting your ROM. I haven't played with it myself as SMILE was the only tool on the playground when I was hacking before I took to my own Metroid engine. From what I hear though, that's something you'd almost need for something this ambitious. Otherwise the best people to ask as far as integration of this into SMILE, I'd say try and talk to the guys who made SMART, or maybe Scyzer too.

Huh. I only played with SMILE a little bit at first then peeled off to start working on this so I also missed out. I built a ROM exploring module that picks up from Zebes and reads the map via door pointers. It picks up everything related to level data plus region maps and load stations. Once we have all this data I erase it so I have a clean ROM to work with. Once a map is created then that information is converted to SM data types and loaded into the ROM. Because the ROM is already wiped out it's just a matter of finding free space in the correct banks and everything gets placed neatly. It includes the expanded ROM space, too.


...so I just scoped out your profile - you've made a game engine and rebuilt MP as a 2d game!?!? What the heck I just made a map maker haha.

H A M

i tried to post a decompiled version of smart to convince the developers into open-sourcing it

Conner

Quote from: TobiMikami on March 28, 2023, 12:02:38 AMAlso SMART is an improved version of SMILE, which is open source. I'm pretty sure they used the original as a basis, but it's got more tools for repointing stuff and doing HEX tweaks, like doors and stuff. I think they said it also overwrites free space in different banks when the room space is full instead of overwriting your ROM. I haven't played with it myself as SMILE was the only tool on the playground when I was hacking before I took to my own Metroid engine. From what I hear though, that's something you'd almost need for something this ambitious. Otherwise the best people to ask as far as integration of this into SMILE, I'd say try and talk to the guys who made SMART, or maybe Scyzer too.

SMART is not open source and its also not build on SMILE

H A M

maybe start a petition to make smart open-source
being open-source means faster development

MetroidNerd#9001

If the developers don't want to make it open source, it is completely in their right to keep the source code to themselves. You are the only person complaining about this.

H A M

only option is to steal the source code
edit-sm.art is a github page
the us federal law states that all non-commercial software must be open-source

OmegaDragnet9

Quote from: H A M on March 28, 2023, 03:08:11 PM
only option is to steal the source code

Don't do that man. We got a good thing as it is. I admire the desire to improve stuff but that'll just cause problems. I guarantee those guys are always working behind the scenes on stuff we have no clue about.

Scyzer

Quote from: H A M on March 28, 2023, 03:08:11 PM
the us federal law states that all non-commercial software must be open-source

This is not true.
Also, posting a badly decompiled code that would never work is not going to convince anyone to open source anything. It's not up to anyone except Amoeba and Testrunner if they want to release the source.
Also, what makes you think that even if you got the code that you would be able to do anything meaningful with it? There's no guarantee it would be neatly laid out and commented code, since the devs dont expect anyonr except themselves to ever look at it.
Also, the US federal law requires you to shut the hell up please. Stop trying to overrun other people's forum posts with your own unhealthy obsession with SMART.