PC [Question] Moving RAM usage to the hard disk

Donoya

Terrarian
Is this possible without hacker level coding? Also, is there a reason this wasn't done, yet? I mean, sure, it'd probably function much slower (or just make the computer work that much harder), but it would have more capacity, thus allowing more modding capability (in theory). I really want to be able to make a mod with tens of thousands of items/weapons/armor/accessories and hundreds of monsters and bosses. Unfortunately, I doubt all that would fit as is. Well I'd want such a mod to exist, but making a mod that big is probably a stretch for me... But my point still remains. Could this be done and would it be bad? And if this is a terrible idea, please let me know why.
 
It's my understanding your computer actually does this automatically. If there isn't enough ram, some process memory will be stored on the disc (which is significantly slower).

The reason tModLoader only let you have so much content is because it's 32 bit. This essentially means each memory pointer is 32 bits, and once you have too much stuff in memory, it can no longer be represented by a 32 bit number. DradonHunter is working on a 64 bit version of tModLoader, however I have no clue how feasible 64 bit is, or how it will preform in comparison to 32 bit.
 
Yes, it's called a Page File, and computers do automatically do it. It stores less-commonly-used items, since storing all currently in use data there would probably wear down the HDD or SSD very quick due to the constant writing and reading, as well as being far slower, to the point where it wouldn't be useful.

But yes, the logistical problem is that Terraria, as a 32 bit program, is only capable of using 4GB of RAM, period. No ifs, ands, or buts about it. It's an inescapable limit without rewriting the entire game to be 64 bit.
The Linux and Mac versions of Terraria supposedly have 64 bit options, but the devs have stated that bringing 64 bit to Windows is "not a priority", so who knows if that will ever happen, much less if it will be any time soon. I assume tModLoader, 64 bit or not, would need to match the version of Terraria you have installed. Perhaps not; that would be nice.



That said, I wouldn't reccommend attempting to make such a mod. Many people have found that adding such an insane amount of content would do more harm than good. You would end up (metaphorically) with every concievable combination of every weapon type, damage amont, projectile, etc. The spritework would have to suffer thanks to the sheer number of sprites needed, the bosses, enemies, and weapons would likely end up being copypasted because giving even half of them unique behaviour would take years of work from a full-time paid dev team, much less one or a few modders. It would be an impossible mess to balance or bugfix.
It's not feasible on any level. Most of the mods that have even 300+ items, 50+ enemies, etc. suffer from these problems to an extent, even after years of additions and alterations and balance patches and updates, and many mods are being rewritten with a lot of content intentionally removed because it was unbalanced, repetetive, or pointless. Terraria is a huge game, and adding even more stuff gets overcomplicated fast.

If you do want to make a mod, try quality over quantity. Add unique things, make each item feel like a different item, integrate them seamlessly, make the bosses feel unlike the vanilla bosses, make the enemies new and exciting. More content does not make something better; good content makes something better.
 
It's my understanding your computer actually does this automatically. If there isn't enough ram, some process memory will be stored on the disc (which is significantly slower).

The reason tModLoader only let you have so much content is because it's 32 bit. This essentially means each memory pointer is 32 bits, and once you have too much stuff in memory, it can no longer be represented by a 32 bit number. DradonHunter is working on a 64 bit version of tModLoader, however I have no clue how feasible 64 bit is, or how it will preform in comparison to 32 bit.
Thanks for the advice. That was very helpful and I will try what I can. Perhaps eliminating a lot of the intermediate material ideas would be a good start. One more question, though. Could I make my mod alter other mod's item recipes to use my ingredients? Or should I try to make my own versions with the desired recipes?
 
Thanks for the advice. That was very helpful and I will try what I can. Perhaps eliminating a lot of the intermediate material ideas would be a good start. One more question, though. Could I make my mod alter other mod's item recipes to use my ingredients? Or should I try to make my own versions with the desired recipes?

I've never tried it, however I'd assume you can add recipes for other mods by doing something like..


Code:
            Mod otherMod = ModLoader.GetMod("otherModsName");

            ModRecipe recipe = new ModRecipe(this);
            recipe.AddIngredient(this, "YourModsItemName");
            recipe.SetResult(otherMod, "OtherModsItemName");

            recipe.AddRecipe();


I'd be careful when doing this. I remember someone changing recipes in another mod creating a huge fuss in the minecraft modding community.

Edit: Make sure to check if the other mod is enabled.
 
Back
Top Bottom