0 Members and 1 Guest are viewing this topic.
how would one do that?
foreach (var record in database.GetAll()) { if (record.TryGet("itemClassification", out var field)) { var value = field.Get<string>(); if (value == "Epic" || value == "Legendary") { record["itemClassification"] = "Rare"; record["--gx-itemClassification"] = value; // keep original value for later use } } }
Quote from: bernd on 05 August 2020, 20:43:26how would one do that?There is two ways nowadays:1. Download Titan Quest Lost Legacy mod, it solve this task by patching game.dll file. I'm doesn't play too much in this mod, but you generally even doesn't need their mod to play, just only need get patched executable files, and then run them over standard game or whatever mod you like.2. Absolutely legal way in sense what you not need patch executables: like i'm described above. But without right (development) skills it will be really a painful job. (Unpack database.arz, replace in about 1500 files for TQAE, or more than 5000 files for SV-AERA, then pack this changes back into form of mod or in original database.arz...)As for (2) i'm already done some good progress in reading and some naive writing of ARZ files, so applying patch like i'm described above (marking epic & legendary items as rare) is tooks few seconds... Actually i'm use this change as some sample. But there is still a lot of work before i'm be able to show tool. And generally it aims only to mod developers with some development skills (or who what to learn a bit).It will look similar to next code (API is not final and varied):Code: [Select] foreach (var record in database.GetAll()) { if (record.TryGet("itemClassification", out var field)) { var value = field.Get<string>(); if (value == "Epic" || value == "Legendary") { record["itemClassification"] = "Rare"; record["--gx-itemClassification"] = value; // keep original value for later use } } } PS: I'm keep aside fact, what applying this kind patch on regular game and then bit of tqvaultae magic - it is another grand easy mode, and generally considered as cheating.PPS: However i'm might reconsider and start publish less polished version, actually only small part of tool is near to finish (e.g. ARZ file support only). Road map bit bigger. However, for me there is case when writing tooling for modding more interesting than attempt to make mod. PPPS: I'm had similar functionality applied over .dbr files before. It was sucky, it was slow and it was lost on died HDD anyway, so today i have already better thing.
record["itemClassification"] = "Rare"; record["--gx-itemClassification"] = value; // keep original value for later use
I am mostly asking cause i wann alearn how to edit a mods properties.like I have downloaded an expx4 mod.I went into the folder, edited the gameengine.dbr file in both the game folder and the xpack/game folder (putting a constant at the end of the experienceequation) and saved them both.sadly that didnt do shit in the game and I seriously dont understand why....maybe i would need a new databse.arz file as well?but sadly I cant use art manager anymore (which claimwise can create .arz files) so I cant repack the now edited stuff anymore :-(I am at a loss what to do.
Why is editing an existing mod so difficult? :-(
Quote record["itemClassification"] = "Rare"; record["--gx-itemClassification"] = value; // keep original value for later useWouldnt it make sense to switch these 2 lines around?like saving the old value elsewhere before you actually change it?otherwise the gx-itemClassification will only save them all as "Rare" cause the old values had been already overwritten beforehand.would jsut be my guess as a programming noob :-)
Quote from: bernd on 08 August 2020, 12:27:08Why is editing an existing mod so difficult? :-(Can you explain once again what you exactly do, step by step?
...
You sure did help me there quite a bit!what I did:first delete all mods for a new start.then struggle cause subbing, unsubbing, subbing, unsubbing did subscribe me but didnt again download the mod files for me.after lots of mod workshopping and playing the main game, one of them suddenly appeared again.
anyways, I did the following:say A folder is the one were the actually used mods are.like the ones you see in "custom game".let B be the folder that for whatever sick reason art manager is programmed to think anyone would dump their mods in and where the game never looks for mods.
so at first I had the downloaded expx4 mod in the A folder. obviously.I copy pasted it to the B folder.deleted the database.arz inside it.so in B folder, the unpacked stuff of the mod still remained.did my good old "changing all gameenigne.dbr files by hand" thing.namely changed the "experienceequation" in the game -> gameengine.dbr file.also came to learn that the spawn desnity (spawn min and max) are located in the other gameengine.dbr, which can be found viaxpack->game->gameengin.dbr
anywas, i modified the experienceequation formula there.then got the art manager running (yep, got it to run on it's old default folder, folder B, again).loaded the mod.clicked "build".which created a new database.arz file for the mod.copy and pasted the whole mod folder (containing unpacked stuff as well as the .arz file) back to the A folder, the one the game actually uses for mods.start game, custom game.
Only bad thing:it wasnt as bouncy as before and ijnstead actually loaded the game map with my level 1 chatacter that I created jsut to use bounce mods.however, he did indeed get from level 1 to 10 just from killing a handful of monsters and the very first boss jsut across the bridge (like the thing you do in the first 5 minutes of the game, not really even leaving the first towns area).so that kind of worked.
what i probably did wrong and why it surely wanst a bounce map anymore is that when "building" the mod, at the very end before finishing it asks you to dlete unneeded stuff or something like that.I had clicked yes there.
so I went ahead and rinse and repeated EVERYTHING.
just choosing no this time, when asked about deleting "unallocated" stuff and such.well, now it works as a bounce mod again.(meaning I go custom game, select mod, click start, get error message, get thrown to main campaing menu.)but sadly the actual changes dont do anything right now.I had changed the movement speed minimum and the experience equation to like 400 times the normal value.but it surely didnt feel like it changed anything, still had the values of the mod from when I downloaded it.(which was only exp times 3 and no changed movement speed)
you said something about "forcing" the game to use the updated stuff.but I didnt exactly understand it. can you please explain again? :-)
Also, another guy (actual admin), had long and lengthy told me to change experience I would need to change the experienceequation as well as stuff under rewards and penalties:https://titanquestfans.net/index.php?topic=1059.msg15590#msg15590As the comments imply, I couldnt for the f*ck of it figure out when wherre and why this was to be found....wanna know who is the dumbass?me.I literally had the whole thing there the whole time whenever I opened art manager.but whenever you load a mod, the shit thing does load the "sources" first.and only thing on the left visible will be an modname/source file.which obviously confused me the f... off when everyone showed me directories and stuff there which I did not have.well, guess whoc accidentally 5 minutes ago saw 3 tabs "sources" "assets" and "database" right below there and clicked them for the first time ever?
problem remains that the mod is basically perfect, would love to sent it to you to confirm if that is okay.but I think it is in a workable state.jsut that the game hasnt "updated" itself yet and uses the mod in the "old" and no longer even exiting version.how can I make it "redownload" the mod from the folder, so it uses the ery current values and stuff?any good way to enforce that? :-)
Here is the mod as I have it now:https://easyupload.io/wrnijwit bounces, it does it's original exp times 3 thing (which it had BEFORE I modified it).but i dont see or feel anything from the changed values :-(the experienceequation had, when it was still expx3, ...*7 standing there.which I now changed to ...350 or something like that.still obviously should give me many times more exp than before.but it sadly doesnt and I dont know why :-(