There is an array in the file server/common/treasure.c:337:
static const int difftomagic_list[DIFFLEVELS][MAXMAGIC+1] = {
, which limits the chance of pre-enchanted items spawning in random treasures , and therefore the spawn chance of artifacts with minimal "magic". To prevent or, conversely, make the occurrence of pre-enchanted items in random treasures fairly common, please , edit this array.
The changes :
1) arch-remove_fixed_pre-enchant.patch :
Remove fixed pre-enchant from all weapons' .arc in "/server/lib/arch/weapon/artifact/" and armours' .arc in "/server/lib/arch/armour/". That allows some rare weapon and armour to appear with artifact title , for example : "Firebrand of Gorokh" or "red dragon mail of Blazing Fires" — right in random treasure.
Note that god gift armour and weapon are still pre-enchanted.
2) arch-trs_coding_style.patch :
* Makes all .trs look clear and understandable, also saves from red eyes after working with .trs files for a very long time.
* Replace double space " " with tab.
* A clear logic has been carried out to make it clear which "yes" , "no" , "end" and "more" refer to.
* Since comments are commonly displayed in colour , "##" comments also added before each treasure and before each "god_grace_limit_" - since gods' treasure sequence is important , it depends on how much minimum grace a god's treasure item will require.
* Perhaps somewhere else minor typos are corrected with this patch.
__
3) arch-magic_4_and_adjustments.patch :
* Change/add random magic limit to 4 for all armour , weapon , bolts , arrows , boulders , acid spits , skill tools , containers , mapbuilding crafting containers , mapbuilding altar , mapbuilding light source. I'm working on a future patch to make items with magic "+1 .. +5" more powerful. In the future , I planning to make another patch for scrolls , which improve not only armour and weapons , but also other items.
* Added amethyst where there were other gems. Adjusted quantity and chance where an amethyst has already been added.
* Adjusted the number of paired limbs (nrof 2), teeth (nrof 32 for apes and for skulls) and other body parts. Set the chance for ghost's ectoplasm and scorpion's stinger to 50 instead of 5 and 10 as they are too rare and for some reason are used in formulae for arrows and bolts of Frost and Poison.
* Ice Warrior drops 50 sapphires instead of 50 shields. Thanks to the previous patch "arch-trs_coding_style.patch" I was able to spot this oddity.
* Renegade Priest is moved from Human/ to Dwarf/ folder since Renegade Priest and Renegade Wizard are race of dwarf.
* NPC's viking.trs , thief.trs , swashbuckler.trs , fireborn.trs are moved from player/ to monster/ folder. Note some ninjas NPC are still using player's ninja class .trs .
Wrong , actually ninja npc uses "treasure ninja" from the big treasure file.
I hope you find all these patches handy and useful and add them to the Invidious server.
Formatting patch applied as ed7a8ce6d, thanks.