Guides and Ressources for RMS

Hello everyone
I love to create random map scripts for AoE2 and because i love Age of Mythology i wanted to learn more about creating random map scripts for AoM: Retold. Of course retold is fresh off the table and so i couldn’t find ressources or guides that help me learning how it works in retold. So i thought it would be nice to have a place to collect and share sources, guides for that in the future. If there’s already some magic place where people meet in the internet for exactly that purpose please tell me because i couldn’t find anything about rms for retold and scrolling through the files showed me that there is a lot to learn :smiley:

Have a nice day and thank you for any future informations :slight_smile:

There is no real tutorial yet. However thankfully the devs made the choice of releasing an almost complete documentary. Look for the doxygen_retail.7z
in your root aom retold folder.
You can extract it somewhere and just run the index.html with the browser of your choice and you will be able to navigate the libraries of most functions and their parameters.

2 Likes

Ah okay, that sounds useful. I will look into it. Thank you :slight_smile:

I’d like to add, all the random map scripts from AoMR are available in plain text, just like AI scripts and reusable libraries. you can have a peek in there to check out some of the syntax and combine that reading up on the function definitions from doxygen_retail.7z to have a better understanding of what they are doing. Most of all, experiment! There are currently no good guides just yet, but as people are learning, there will be guides out soon!

1 Like

I filtered mods by random map, downloaded one, made a local copy, renamed the files and folders and restarted the game, you can then test the map generation by clicking new map in the editor and selecting your new local mod. If you edit the xs file and save, each generation uses the new script, no need ro restart the game between tests.

1 Like

I wrote a bit of a guide to get you started: AoMR Random Map Scripting. This is an introduction to writing… | by Liam Appelbe | Sep, 2024 | Medium

2 Likes

This is awesome Tiusic. Thank you very much :slight_smile:
I will look into it this weekend.

Okay, i’ve checked out the starting guide from tiusic and it was very helpful to get started. Big thanks for this pioneering work in the name of everyone who wants to start rms for retold. Next step we could need are some indepth explainations like which number does what etc. and some sort of library/list for textures, objects and stuff.

I have plenty of fun already figuring things out at this point.
Again, thank you tiusic for your starter guide :slight_smile:
Have a nice week everyone

There’s some documentation available for the APIs, and I explain how to access it in the guide (the bit about doxygen_retail.7z). But it’s true that most of the functions only have a brief explanation of what they do, and the parameters are undocumented. If you’re trying to figure out the details of a particular function, comment out as much of your script as possible, leaving only that function (and the stuff it depends on), then adjust one param at a time and see what happens. You can usually figure it out.

Documenting all that is too much for one person to try to do, but maybe the modding community could start a wiki for this?

As for lists of objects/textures etc, someone on reddit told me how to get those lists, and I’ve updated the guide. You need to make a user.cfg file, run any map script, then look in the game folder for MythRMConstants.txt. Details in the guide.

1 Like

Hello everyone
I’m having a blast figuring everything out for retold RMS so far. Thanks again tiusic for your guide. Lately i encountered a problem i couldn’t solve. All cliffs in my generation are walkable by units. They don’t seem to have the walk and build restrictions that the cliff terrains normally offer. Any idea? I guess the answer is very simple but after 3 hours searching for the problem i thought it would be an idea to ask here for some help. :smiley:

Edit: Code. It’s a very basic and messy ‘‘try around’’ code. Maybe someone can find the issue in it.

int cliff_typeID = rmCustomCliffCreate(“cliff_type”);
rmCustomCliffSetTerrain(cliff_typeID, 0, cTerrainNorseGrass1, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 1, cTerrainNorseGrassRocks2, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 2, cTerrainNorseGrassRocks1, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 3, cTerrainNorseGrassRocks2, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 4, cTerrainNorseGrassRocks1, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 5, cTerrainNorseCliff2, 0.0);
rmCustomCliffSetTerrain(cliff_typeID, 6, cTerrainNorseCliff1, 0.0);

int hill_areaID = rmAreaDefCreate(“hill_area”);
rmAreaDefAddToClass(hill_areaID, hill_classID);
rmAreaDefSetSize(hill_areaID, rmTilesToAreaFraction(600), rmTilesToAreaFraction(620));
rmAreaDefSetCliffType(hill_areaID, cliff_typeID);
rmAreaDefSetHeightRelative(hill_areaID, 5.0);
rmAreaDefAddHeightBlend(hill_areaID, cBlendAll, cFilter5x5Gaussian);
rmAreaDefSetEdgeSmoothDistance(hill_areaID, 10);
rmAreaDefSetCoherence(hill_areaID, 0.25);
rmAreaDefSetBlobs(hill_areaID, 6, 8);
rmAreaDefSetBlobDistance(hill_areaID, 5.0);
rmAreaDefSetCliffEmbellishmentDensity(hill_areaID, 0.25);
rmAreaDefSetCliffRamps(hill_areaID, 3, 0.125, 0.1, 1.0, 1);
rmAreaDefSetCliffRampSteepness(hill_areaID, 1.5);
rmAreaDefAddConstraint(hill_areaID, vDefaultAvoidSettlementRange);
rmAreaDefAddConstraint(hill_areaID, createTownCenterConstraint(40.0));
rmAreaDefAddConstraint(hill_areaID, rmCreateClassDistanceConstraint(forest_classID, 10.0));
rmAreaDefAddConstraint(hill_areaID, rmCreateClassDistanceConstraint(hill_classID, 10.0));

rmAreaDefCreateAndBuildAreas(hill_areaID, 2 * cNumberPlayers);

If there’s a better place to share problems like that, like a retold rms forum/discord, please tell me :wink:

Actually I read about what these do;
" I don’t know what cannotReplace and landmap /watermap do (presumably landmap /watermap describes what sort of map it is, but I don’t know what this actually does functionally). Let me know if you have any solid information about any of that."

cannotReplace is when you’ve made a final version and you want it to not be replaced by updates

land/watermap is for random map maps, so it knows to add it to the pool of land or watermaps to choose from when you choose one of the “random maps”

thx for the guide I have already learned a bunch and am not done reading yet lol

One of the devs told me on discord that cannotReplace is deprecated, so we should probably just ignore it.

1 Like

I spent some time testing this tonight. I changed every map except Vinlandsaga to be a land map, deleted all the maps from watermaps.set , and added Alfheim to the set instead. When I started a Naval Maps game, it created an Alfheim map, so that means it’s using the hard coded map list, not the landmap /watermap tags.

Oh well looks like it’s not needed for anything anymore then :stuck_out_tongue: was excited I was able to contribute but seems my information was outdated xD
currently taking my first steps, wish me luck lol

Found the answer. You were close. Turns out there’s some filter buttons in the map picker for land maps and naval maps. I didn’t even notice those buttons, but they’re based on the landmap/watermap tags.

Good luck! :+1:

1 Like

Thanks :slight_smile:
I have a question if you don’t mind, I made the debugger UI user.cfg file at the designated location but I don’t get the debugger UI when I mess up. It just goes “failed to load” every time. Do you have any idea what I might have done wrong?

Not sure. Could be all sorts of issues, so I’ll need more info. Join the modding discord and ask there: AoM:R Scripting

1 Like

Hello again. I really don’t want to be this annoying guy but i still couldn’t solve my problem here. Why are my cliffs still walkable and buildable? Maybe someone has the solution out there. It drives me crazy :smiley:

Try asking on the modding discord: AoM:R Scripting

1 Like