Dawn of Magic 2

Dawn of Magic 2

Not enough ratings
Modding Dawn of Magic 1
By treborx555
How to create new: items, rune words, materials and balance: spells, characters etc!
   
Award
Favorite
Favorited
Unfavorite
How to Use the extractor tool
Tool is here: https://int0thegame.blogspot.com/2007/05/dawn-of-magic.html

Here's how to get all the files out of the media.bm:

1) open the tool.exe.
2) do "open" get the .bm file
3) extract all to some folder

Now you have all the files. Secondly you can do the same for DOM2's files because of one important reason: the lua files there are open source!

What I'd do next is collect all the files you want to edit, like item_generation.lua, runewords.mui etc.

After you modify those files, you want to compile all that into a mod right?

Here's how to compile those files into a mod:
1) edit the files in that folder to your liking
2) open the tool.exe again
3) do "add files", select folder with your edited files to and edited them
4) do save bm. Save as media1.bm in the game dir


Note, you just need to save the edited files because apparently the game loads all files named "media" something. I still am not totally sure how it works but "media1.bm" mod will work 100%.

In the past I replaced the entire media.bm file because I didn't know this was possible.

So, don't do that now, keep the original media.bm file there.


Editing .mui and .json files
The files are simple, but not nice to read. First line shows you what each element means.

For example:
@head;name;cost
apple;Apple;5

@head is usually the identifier, name is the name of it in game.

A more realistic example is:
@head;name_eng;droprate
amulet_medium_013;Cold Eye;0.001

To edit it you have 4 options that i know of:

* read the file in notepad++. This is not recommend for large files like items.mui but for smaller ones you can do this
* use a program to open and save the file as a .csv file, then rename it to .mui. Make sure you set the delimiter to ";" without the ". Probably excel or a free alternative
* Use my program[treborx555-gmail.visualstudio.com] to load it into code and manipulate the data or just to turn it into json for easy editing. Though it's not perfect.
* make your own program to edit it

Last 2 options are recommended if you want to automatically create variations of items for example. Say there's 200 items and you want 50 variations of each. That's 10.000 items. Not to mention doing this by hand means any mistake sets you back minutes or even hours to fix it, and you'll probably be playing the game and suddenly notice an item has the wrong name, or absurd stats because of a mistake.
Files you want to edit
First of all, you want to edit the .mui files. Search for .mui and copy all of them to a folder somewhere to pick which ones you want to edit.

I personally am editing these ones:

* characters.mui > this seems to have all the entities in the game: your heroes, enemies, your summons etc. I used this to buff the earth elemental skill.
* item_sets.csv > it seems some csv files are used too, but i didn't yet try edit this one.
* item_subclasses.mui > here you edit rune slot amounts. Every item has a subclass that determines it's rune slots and where it's worn
* items.mui > here you can do what most people want, add new unique items!
* rune_words.mui > here you add the stats of the unique items. But that's not all, here are the stats for most things that use stats, like: tattoos, morphing, item sets, materials and yes rune words.
* rune_stats.mui > all the stats in the game. they seem hard coded, you can't seem to add new stats even if you wanted to say make a stat that has a higher maximum and make it rare. But you can edit their values.
* spell.mui > edit nearly all values of spells like their mana cost, secondary dmg or even amounts of certain things like bones, twisters etc.
* version.txt > edit the game version so you can be sure you're using your mod.
* rune_sets.csv > another .csv file. Edit this to add new rune words, then add their stats to rune_words.mui
Editing Items.mui
  • Always_highlight > means it shows on the screen even if you aren't clicking the show items button.
  • Unique > all i know is that it means the name is yellow
  • generate_by_name > probably stops it from being dropped randomly, like totem of the fire termite. So only fire termites drop it. (but i don't think you can edit this if it's true, unless you can decompile .lua files
  • Item_lit_name > the name
  • use_char_required > whether it's a lvl, int, str or vit requirement
  • Use_char_value > the amount of the required stat/lvl
  • Available_from_level > means mobs and shops start dropping it at map that lvl
  • RuneWord_socketed > this is the stats of the item. Usually it's to give unique items stats, but some items like earrings have this too (tho it just adds +weight)
.lua files
These contain in game logic. In DOM1, 99% of these files are encrypted or compiled. This means you can't really edit them.

Good news is that DOM2's lua files are fully open source, which means we can easily edit them!
(you can also use luadec to decompile DOM1 files, but it will produce worse results)

Another good news is that all DOM2 lua files I tried also work on DOM1! So just use the readable DOM2 lua files and have an easy time modding the game!

We have:
item_generation.lua - most important file, you can change alchemy recepies, mob drops, boss drops, what traders sell etc etc
traders.lua - here you can edit to change how the genie chest is opened (I made a small mod that disables the cost hehe)
quest_rewards.lua - here's where you can see what quests give stat points and change stuff etc
13 Comments
treborx555  [author] 23 Oct, 2022 @ 7:07am 
Here's a new discord link, my bad:
https://discord.gg/HVNCqrdCxm
Hermes Trismegistus 23 Oct, 2022 @ 6:13am 
Hey, can you give another invite? This one is outdated(
Vaki 11 Oct, 2022 @ 2:07am 
also, the "generate_by_name" option in the csv and mui files, if changed to 0, will cause even totems to be sold in the shops, if you increase the drop chance, weirdly enough "drop_chance" increases both drops from monsters and appearances in shops. Another important note, if u have a CSV editing tool, you can open the MUI file as CSV and edit it as a CSV file, then just simply save it with an MUI extension.
Vaki 11 Oct, 2022 @ 2:00am 
do you know by any chance how to view/edit the lua code? i managed to extract some code but im unsure if it's complete since im quite unfamiliar with lua
Hermes Trismegistus 9 Oct, 2022 @ 7:05am 
Great news. thanks)
treborx555  [author] 8 Oct, 2022 @ 9:28am 
Updated the link.

Also NEWS! Dawn of Magic 2 can also be modded!
(you just need to use "Blood magic: smoke and mirrors" as the option in the tool linked in the guide)
Although this isn't really that important because the game is way shorter than DOM1, but there's a neat catch. The .lua files in DOM2 are all in plain source code! This means you can very easily use those files either completely or as reference to modding DOM1 lua files!
zenogasu 6 Sep, 2022 @ 11:50am 
Hey bro. Please help me crack this game by providing more detailed instructions. I really want to fulfill my childhood dream)
Vaki 9 Jun, 2022 @ 7:27pm 
yeah, adding the link again would be great :)
Hermes Trismegistus 8 Jul, 2021 @ 1:47am 
Link on a .bm-extractor is dead( Can I ask you for the fresh, actual one?
treborx555  [author] 25 Oct, 2020 @ 2:29am 
How did you go about doing that misaka? What i do is extract the files, edit them outside the tool. Then Add the files in the tool and create the .bm. It's also possible you didn't understand what you changed. Try with something that you can instantly see the difference of, like changing the name of an item you already have or something like that.