Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
even single pool fill commands are an array. I hope this helps
Because Steam doesn't notify if a new discussion was created.
This is the full line of code for each treasure patch. Can you explain what the error is exactly, or did you guys jump the gun?
[ ] = array = a bracket set in JSON that defines a list that code can chose keys from. Also allows additional keys to be added to the list.
" " = key
{ } = a bracket set in JSON that is used to contain additional parameters for a key.
[ ] = list
{ } = single key with parameters
TL;DR { } is a single option. [ ] creates a list that can have things added to it:
[ list
{Single thing},
{Single thing},
{Thing added from another patch file}
] end list
That doesn't make any sense. The json should be adding a key,value pair to the end of an already existing array, not overwriting a previous array and making it a pair. If changing it fixed the issue, there has to be some other thing at play here.
Also, you explaining in detail the difference between arrays and json objects like I don't know is kind of insulting.
testTreasure.config
testTreasure.config.patch
Output:
I know the difference between Objects and Arrays/Lists, and I know what Key/Value pairs are, so your lengthy explanation, maybe despite good intentions, comes off as rude and condescending.
Lo and behold, level 1 flying monsters start dropping both Experience Orbs and Infernal Scrolls, despite having patched in both separately, thus apparently 'over-writing' the fill array.
When I change to the 'fix' you suggest, it immediately crashes the area once you kill the monster in question, as it attempts to read a completely wrong datatype.
Also, I took the liberty to install your mod and took a look at your monster patch file:
So let's see... You aren't testing to see if "fill" already exists. Well that's no good, because then it will replace whatever fill already exists. If you have multiple mods that patch treasure like this, the last one to load will always simply erase what was previously there. That's why my patch files have explicit tests to prevent this from happening. Take a look:
So in this case, we use the "op" : "test" and "inverse" : false line to test if "fill" exists. If it does, we add our JSON object to the fill array usig "path" : "/erchiushorrorTreasure/0/1/fill/-".
The next test sets "inverse" to true: in that case, if "fill" was not found, we set "fill" to an array containing our JSON object.
By doing each patch like this, we ensure we never overwrite anyone's "fill" or any value for that matter, and we also prevent bad patch errors, etc.
It's a bit embarrassing that you went on an entire 'teaching' charade, but failed to apply tests to your patch files to ensure you don't overwrite other people's work.
I don't know how you guys 'fixed' the issue by changing my code, because that would most certainly crash the game whenever the game then tries to load the completely botched fill pool, most likely now containing [{}, [{}]]
What treasure patches are you working with, and when does your mod load. If you changed it to what you wrote, you'd most certainly ruin the fill array unless another mod overwrites it.
Awesome. Thanks for at least not being super condescending like Zancuno. I assume we both know how to code/mod, and things fall through the cracks all the time, so it was entirely possible I had made a mistake somewhere, but those lengthy, dumbed down instructions by Zancuno kind of hit a nerve.
Hope you find the issue, and please do let me know if there really isn't anything else causing it.