Duke4.net Forums: Map Order Randomizer - Duke4.net Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Map Order Randomizer  "Changes how you approach Duke Nukem 3D"

User is offline   Daedolon 

  • Ancient Blood God

#1

Hey guys.

With the Duke Hard CBP talk about randomization (thanks to Lunick), I thought I'd try to write something small quickly just to see how it could be done. Well, it took a bit longer than I planned but that's how things always go. Anyway...

This is a "gameplay" modification with a custom CON file (literally eduke.con file that calls game.con, then my custom con file) that leaves the original GAME.CON, DEFS.CON and USER.CON untouched, so you can use this with one of your own mods as well as long as you make sure the gamevar definitions are correct. Basically what the mod does is randomize the level order of any of the four episodes in Duke Nukem 3D 1.5, without telling you (unless you're a cheater). For example the most hilarious order I got when testing this was on The Birth; The game instantly sent me to The Queen and Derelict right after that... with It's Impossible being the last map.

It's literally randomized, which, I noticed, made it surprisingly fun to play through episodes since you have no clue what's coming up next. Depending on the randomization, some orders can bring some new challenges to some of the levels as well if you're used to having weapons or inventory items from previous levels.

Few things to note:
  • The game creates a random level order every time you choose New Game from the main menu.
  • Killing bosses now instantly ends the level, I had to do this because how their episode ending code worked.
  • All nukebuttons are now regular nukebuttons, but you still can use the secret level ones (and visit the secret levels as well).
  • Whatever the last level of the episode ends up being, it ends in the correct cutscene and sends you back to the main menu after completion.
  • Cheating (DNSCOTTY) breaks the randomization until the next level as this doesn't change the "physical" map order. Don't be an asshole, don't cheat.
  • It's pretty rough overall since I wanted to get it to this point. It's as is, but I'll likely revise it a bit further.
  • EDuke32 only. Written and tested on r4309, can't promise it works in earlier revisions.
  • No original gameplay of Duke3D 1.5 has been changed except for what's written above.


There are really no screenshots to show, but here's one with the progress meter I added (which you can disable by typing "setvar showprogress 0" in the console).

Attached Image: duke0000.png
Here you can see I went through Pigsty, Duke Burger, Going Postal and then ended up in The Queen, with seven more levels to spare.


Have fun and let me know if you liked it (or alternatively, found any more issues etc.)!


Shout-outs to Mblackwell.


Attached File  MapRandomizer-0.2.zip (3.1K)
Number of downloads: 676

This post has been edited by Daedolon: 22 February 2014 - 11:13 PM

9

User is offline   Stabs 

#2

often wondered if you could make bits, like corners, crossroads, halls, etc etc like tilesets and run a script to make a random maze like map
1

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#3

View PostDaedolon, on 22 February 2014 - 10:47 PM, said:

[*]All nukebuttons are now regular nukebuttons, but you still can use the secret level ones (and visit the secret levels as well).

It would be cooler if you still had to use the Nukebutton to access all levels. Even better if the color of the Nukebutton changed if a level was made secret or not.
0

User is offline   Daedolon 

  • Ancient Blood God

#4

I think combining this with some code that randomly flips or mirrors the levels as well could be really interesting.

View PostFox, on 22 February 2014 - 11:01 PM, said:

It would be cooler if you still had to use the Nukebutton to access all levels. Even better if the color of the Nukebutton changed if a level was made secret or not.


I literally wasn't considering anything other than poking at making a map randomizer, but that sounds like a cool idea, especially if the secret level was chosen randomly.

This post has been edited by Daedolon: 22 February 2014 - 11:02 PM

0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#5

You could also add a monsters randomizer or something.
0

User is offline   Daedolon 

  • Ancient Blood God

#6

Changing anything within the levels isn't in my plans, though.

EDIT: Noticed that when I changed around some of the boss handling, now even mini-battlelords end the level, heh. I'll fix that tomorrow I guess.

This post has been edited by Daedolon: 23 February 2014 - 12:24 AM

0

User is offline   Helixhorned 

  • EDuke32 Developer

#7

Interesting mini-mod. I haven't tried it out yet, but I've got a couple of comments to make.

Please change these,
setuserdef THISACTOR.level_number temp

into
setuserdef .level_number temp

(A patch is attached.)

As discussed here in partucular, and on that whole page in general, userdef is a global structure, so it doesn't need an index to be accessed at. The real reason I'm asking is because LunaCON won't accept it syntactically. I already made it accept these (from lunatic/test/getuserdef.con):
    //  - all three are equivalent:
    getuserdef[THISACTOR].statusbarscale temp
    getuserdef .statusbarscale temp
    getuserdef[].statusbarscale temp

but it seems that C-CON accepts just about any garbage between the '*etuserdef' token and the '.xxx' member name. Sigh, C-CON.

The way you wrote it should make it possible to be used independently as a mutator in theory. Nice!

View PostDaedolon, on 22 February 2014 - 10:47 PM, said:

This is a "gameplay" modification with a custom CON file (literally eduke.con file that calls game.con, then my custom con file)

It would be more correct to say that game.con is textually included, then your randomizer.con. Because that's what include effectively is -- you can pick apart a single CON file at directive/block boundaries, and include the parts in the corresponding order. The result should be the same.

Attached File(s)


1

User is offline   MetHy 

#8

This is really cool! I'm liking it.

However, how would the numbers of level in the hud look like with 20+ maps? and how would it look like in lower resolutions?

Also I got a glitch. I strated by playing Critical Mass (map 8), but I died in the explosions upstairs after the start of the map. So, it got me to restart the map but the hud now showed maps 8 - 10,with 10 in red as if i was playing map 10 while I still was in 8. After that, everything went normal and the glitch didn't appear again when I killed myself on purpose several times to see if it would happen again.

Now what I wonder if, with this glitch, I wouldn't play map 10 at all since it thinks I already have. I have saved on the 4th map, I could try that.

Posted Image
0

User is online   Danukem 

  • Duke Plus Developer

#9

View PostDaedolon, on 22 February 2014 - 11:01 PM, said:

I think combining this with some code that randomly flips or mirrors the levels as well could be really interesting.


This mod is a good idea, although it makes more sense for collections of user maps so they can be played as episodes. Map order randomization is a major feature of my Attrition mod, although in that case it applies to a random subset of a large set of maps -- you must be doing it quite differently since in your mod every map is guaranteed to be played. Attrition also has random map mirroring (thanks to code from Plagman) and lots of other stuff. Your mod would appeal more to players who want the classsic Duke 3D experience but just want to mix things up a bit.

Unfortunately, all of the maps that can be played with the mod must be defined into episodes in the CON files before any randomization can occur. If it were possible to have the game read from a maps folder instead, then players could just drop the maps they want into the folder and then the code could select them randomly.
0

User is offline   DavoX 

  • Honored Donor

#10

Remember that the last map can't be random as it's located in the rooftop!
0

User is offline   Daedolon 

  • Ancient Blood God

#11

View PostHelixhorned, on 23 February 2014 - 03:08 AM, said:

Interesting mini-mod. I haven't tried it out yet, but I've got a couple of comments to make.

Thanks for the heads up, I'm a bit rusty these days. I'll add the changes when I fix few other issues.

View PostMetHy, on 23 February 2014 - 05:29 AM, said:

This is really cool! I'm liking it.

Yeah, I wasn't sure if a randomized order would work for the CBP, but seeing it work with the regular maps (and be fun) makes it plausible for the CBP as well, which is something that I wasn't expecting.

View PostMetHy, on 23 February 2014 - 05:29 AM, said:

However, how would the numbers of level in the hud look like with 20+ maps? and how would it look like in lower resolutions?

However I wanted? Like I said I just made this with 1.5 in mind, but it's easy to fix it for anything. I don't think the CBP, for example, should show these numbers.

View PostMetHy, on 23 February 2014 - 05:29 AM, said:

Also I got a glitch. I strated by playing Critical Mass (map 8), but I died in the explosions upstairs after the start of the map. So, it got me to restart the map but the hud now showed maps 8 - 10,with 10 in red as if i was playing map 10 while I still was in 8. After that, everything went normal and the glitch didn't appear again when I killed myself on purpose several times to see if it would happen again.

That's odd, though I really didn't try getting killed all that much since I just thought I'd throw this out here as an idea. I guess if anyone can figure out what that is, I could fix that.

View PostTrooper Dan, on 23 February 2014 - 08:30 AM, said:

you must be doing it quite differently since in your mod every map is guaranteed to be played.

It literally just counts the number of maps in the episode you're playing, and randomizes the order of those ones.

I pretty much just made this as a quick test to even see how viable something like this would be, so I made it with 1.5 in mind. I guess the idea could be expanded into something with more options and features (map mirroring etc.) for people who really want a randomized output.

View PostDavoX, on 23 February 2014 - 09:57 AM, said:

Remember that the last map can't be random as it's located in the rooftop!

That's an easy fix, but I wanted to play through all of the playable maps in 1.5 myself so I set it like this here.


I need to figure out what's causing that Critical Mass issue, then add few fixes and update this.
0

#12

it's kinda funny that this was made in 2014, but i'm now discovering it in 2019. i just randomly came across this when i was originally looking for a Super Mario 64 randomizer. i was on a site and saw a bunch of randomizers, and this was the 1 main thing for Duke. it's an interesting thing to see, and can provide a little challenge as well. i can sorta imagine this being a thing for the Duke Nukem 64 mod since you can go through all 3 episodes with everything in tact. i know it won't happen anytime soon, but it's just an interesting what if scenario. might try and do a little let's play of this in the future
0

#13

so i have done the normal 3 episodes of the game with this randomizer. and one thing i've come across is that, killing battlelords. least the mini ones ends levels early. i'm working on the thing as a let's play series, but i night not do the 4th episode until i get some kinda clarification as to knowing is there's a bug with the mini battlelords ending levels early or what. overall though it was quite an interesting thing to play. never had the experience of playing classic Duke 3D with it being randomized
0

User is offline   LakiSoft 

#14

I tried this little masterpeice and i can freely say i am impressed. I really like how it randomizes order of Classic Duke3D levels and that way it makes experince so unique and new but same goold clasic expericne all at the same time. I already did L.A. Meltdown and it ended with Hollywood Holocaust while lunar Apocalypse ended Space Port. Now i am at Shrpanel City testing. This mini mod is awesome in my opinion. Thnaks for uploading this little masterpice mini-mod.
0

User is offline   king karl 

#15

View PostTrooper Dan, on 23 February 2014 - 08:30 AM, said:

This mod is a good idea, although it makes more sense for collections of user maps so they can be played as episodes. Map order randomization is a major feature of my Attrition mod,



i want this more than anything, an excuse to use my giant folder of user maps!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options