Caves of Qud

Caves of Qud

Joppa Chests Aren't Stealing
36 Comments
Borbe 25 Dec, 2024 @ 7:17pm 
Good mod, I love stealing :steamthumbsup:
Kaktus021 23 Jun, 2024 @ 7:54pm 
Cool, removed mine since it's redundant now.
Flurshin Turlet  [author] 23 Jun, 2024 @ 3:12pm 
Technical details for the curious:
Joppa's furniture used to be their own unique objects, like JoppaChest which inherited properties from the generic Chest. I used to just overwrite the JoppaChest object.

Those objects were removed, likely for cleaner code, and now *are* generic chests like all the others in the game but with Owner=Joppa defined in Joppa's map definition file.

So now I have to overwrite each of the furniture entries in the Joppa map file, which is messier and a future update or a different mod that affects Joppa might be overwritten by my mod and you might end up with chests inside walls and such.

Also it breaks backwards compatibility which is unfortunate.
Flurshin Turlet  [author] 23 Jun, 2024 @ 3:09pm 
Thanks for your efforts.
I had figured out what changed but was really hesitating on how to proceed.

Overwriting Joppa.rpm like you did has the potential to conflict with any future updates to Joppa or other mods that affect Joppa.

I was instead considering a complete rewrite as a C# mod that strips ownership on the fly, but various things kept getting in the way.

I've decided to just take the overwriting Joppa approach for now but stripped the file to the minimal amount of changes required.

Mod is now updated, just be aware of possible conflicts with other Joppa mods.
Kaktus021 21 Jun, 2024 @ 6:36pm 
I've figured it out. In the redesign of Joppa they changed how the chests are owned. They're not in ObjectBlueprints.xml anymore. They're in Joppa.rpm. Just rebuilt the whole thing and it works fine.
Flurshin Turlet  [author] 10 Jun, 2024 @ 2:44pm 
Thanks for saying so. I'll take a look when I can and see what changed.
Lancewholelot 8 Jun, 2024 @ 3:08am 
Doesn't seem to work with the Spring Molting update.
Wakko 9 Feb, 2023 @ 7:22am 
Fuck Joppa Chests Aren't Stealing
All my homies uses No Chests in Joppa
Flurshin Turlet  [author] 15 Nov, 2022 @ 3:03pm 
Updated with a new image and minor maintenance stuff. No functionality changes. Works on Moon Stair beta.
Tekno 3 May, 2022 @ 7:51pm 
Works for me still in case anyone sees this
Flurshin Turlet  [author] 29 Aug, 2020 @ 5:04pm 
Now includes Tam's chest.
Flurshin Turlet  [author] 27 Aug, 2020 @ 2:59pm 
Works on my end. Please let me know if it doesn't work for you.
Thanos 14 Aug, 2019 @ 1:49pm 
I am guessing this does not work any more?
ravni 1 Nov, 2018 @ 5:25pm 
Wow, that's a lot after I've gone through it all! Didn't have time to read before. I'm kinda interested in modding, i'll keep looking into it. Thanks!
Flurshin Turlet  [author] 1 Nov, 2018 @ 5:00pm 
[post 1 of 7. the start. comments have a 1000 character limit. posted in reverse order for ease of reading on Steam]
Sort of! It's XML https://en.wikipedia.org/wiki/XML which is a Markup Language like HTML is HyperText Markup Language, and is often used to store data objects that can have other data or tags attached to them. It's used both in and outside of web development.

For Caves of Qud, the game is mostly C# if I remember correctly, but loads certain data from external XML files you can find in /Steam/steamapps/common/Caves of Qud/CoQ_Data/StreamingAssets/Base/ and check out in any text editor.
That folder also has RPM files which if you open will find are also XML, and JSON https://en.wikipedia.org/wiki/JSON files which are derived from JavaScript and can be thought of as an alternative structure for containing similar data to XML files, those too are text and can be viewed with Notepad or Notepad++ or Sublime Text or Vim or whatever your text editor flavor is.
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:49pm 
[post 2 of 7]
While you can also open them with WordPad or Microsoft Word and similar word processor programs, editing and saving them with those programs isn't recommended as they can sometimes sneak extra unwanted style data into the file which can cause errors when other programs later try to read them.

Yes, this particular mod is simple and was essentially made by just deleting a little text tag which you can find roughly around line 18461 in ObjectBlueprints.xml which contains the data for most of the objects in the game, but the game allows mods to include an ObjectBlueprints.xml containing only the data of the object they want to modify or add and the game will automatically merge that data into the rest of its ObjectBlueprints.xml every time the game is loaded, that way my modded ObjectBlueprints.xml does not have to be updated every time a new object is added to the base game.
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:47pm 
[post 3 of 7]
When you subscribe to this mod, what Steam downloads is a 9 line ObjectBlueprints.xml, a preview.png file which is the screenshot you referred to, and a 1 line workshop.json file containing information about the mod such as its workshop ID, name, and description.
Those files end up somewhere in your /Steam/steamapps/workshop/content/ folder, you could probably search that folder for files named ObjectBlueprints.xml.

Qud checks for mods you have enabled, reads the XML file, then overwrites just the JoppaChest object with the one in the mod file, and does this in the games memory each time the mod is loaded so that the ObjectBlueprints.xml in the game folder is never modified by any mods.

That indeed is what modding the game looks like, though there is an important distinction to be aware of. Modifying the XML data files is only one way of modding Qud and can only change the data templates the game uses, such as objects, non-random areas, conversations, and so on.
ravni 1 Nov, 2018 @ 4:44pm 
Thanks, this should be helpful!
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:43pm 
[post 4 of 7]
It's not possible to modify game mechanics such as combat or create entirely new and unique skills with just XML files.
For that, the game allows mods to be written in the same language the game itself is written, C# (if I remember correctly), which can directly reference or intercept executable game code, allowing very powerful and extensive changes and additions.
Much more powerful, but with the downside of being more complicated and involved to program.

Another potential problem with C# mods is one that affects not only modders but anyone who subscribes to a C# mod, in that to allow C# mods to interface directly with game code and modify how the game functions they also have the ability to potentially add malicious code to the game, as the C# plugins are not yet safely sandboxed and restricted from accessing unsafe operations, essentially allowing the ability to sneak malware in.
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:42pm 
[post 5 of 7]
I believe the game disables C# mods by default and may warn you of the dangers, plus it's very unlikely anyone would target Caves of Qud with malware and then go through the effort of creating a desirable mod only to sneak malware in to it, thus people generally shouldn't worry about malicious mods because the small risk is the same as modding Minecraft or browsing the internet without an ad blocker.

Still, that's why my description of this mod states "no scripting used" even if there's no reason to trust my description as truth, mentioning it invites people to check for themselves if they have any concerns about the safety of the mod, you can easily open every part of this mod in either Notepad or Paint (for the screenshot png) and see everything it does.
I believe C# mods are distributed as uncompiled CS files so you can view those with Notepad too, but in my opinion it can be much harder to understand what C# is doing compared to XML, your experience may vary.
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:39pm 
[post 6 of 7]
Phew, I hope that's not overwhelming or bothersome to anyone that happens to read it.
Perhaps you already knew all of that and didn't need any explanation, but I figured I might as well go into as much detail as I can in the chance that someone will find it helpful.
Caves of Qud is constantly changing and improving, it has very active and open developers trying to balance new content with bug fixes and better mod support, there's no way a definitive and accurate explanation of Qud modding can exist at this stage of development so a lot of experimentation is required, but if you're interested in Qud modding I recommend checking out the sparse but official modding wiki at https://freehold.atlassian.net/wiki/spaces/CQP/overview to learn a little more than what I've covered here.
Flurshin Turlet  [author] 1 Nov, 2018 @ 4:37pm 
[post 7 of 7, comments have a 1000 character limit. posted in reverse order for ease of reading on Steam]
This link covers a little bit of modding objects with XML: https://freehold.atlassian.net/wiki/spaces/CQP/pages/23691295/Object+Modding
This link covers a little bit of C# modding: https://freehold.atlassian.net/wiki/spaces/CQP/pages/25690146/.cs+Scripting+Mods

I haven't touched Qud modding since around the time I made this mod, which is part of the reason this mod only makes Joppa chests legal to steal from and doesn't change any of the other starting town chests, so I wouldn't be any help giving further advice on how to make a mod.

If you end up making mods I wish you good luck and smooth sailing, if you were just curious about how modding works then hopefully this answered your question and a few others you may have had, either way I wish you the best and applaud your pursuit of knowledge.

Thanks for commenting! :D:
ravni 1 Nov, 2018 @ 2:27pm 
That screenshot is literally just html, or looks like it! Is that actually what modding the game looks like? And how exactly does that work?
pyatr 20 Jul, 2018 @ 12:48am 
@bearhiderug
I am roleplaying by not stealing unless I'm in dire need of a certain item (which is almost never).
efedrowisch 18 Jan, 2018 @ 10:43pm 
@Korbo. Just smash the torches and then wait for night to steal from both ARgyve and the mayor. Or use this mod, obviously.
highly_addictive 15 Jan, 2018 @ 1:03pm 
who needs joppa chests when everything you could ever need is in the six day stilt?
pyatr 15 Jan, 2018 @ 5:35am 
So what, do they just give away their already scarce valuables to a random adventurer?
Flurshin Turlet  [author] 13 Dec, 2017 @ 12:09am 
No, you're not the only one. I think actually that pretty much everyone already knows that.
This is more convenient.
Yuzuke 12 Dec, 2017 @ 11:47pm 
Am I the only one here knows that -
you could take those item without being caught SIMPLY BY CLOSE THE DOOR ?:steamfacepalm:
Flurshin Turlet  [author] 20 Oct, 2017 @ 4:30pm 
This mod makes it not stealing, so no moral issue to deal with!
Don't think too hard about the logic of Joppa, nothing there makes sense. :TheMask:
Anti 20 Oct, 2017 @ 7:40am 
Stealing is wrong. Shame on you.
mister six 6 Oct, 2017 @ 11:05pm 
joppa gets rich off thousands of dead adventurers ¯\_(ツ)_/¯
pyatr 2 Oct, 2017 @ 6:24pm 
Am I the only one who thinks you shouldn't steal from Joppa denizens because they're poor, harmless and give you shelter? Just once in ~550 hours I only peeked inside one chest.
Klinge 1 Oct, 2017 @ 11:17am 
Saved me the trouble of moving people out of their houses for 20 turns
Korbo 29 Sep, 2017 @ 5:05pm 
This is gonna save so much fucking time chiselling through Argyve's walls. Thank you.
Thunderdrake3 29 Sep, 2017 @ 10:12am 
Thanks!