Closed McAwesum00 closed 1 year ago
I took a look at the world but it seems quite broken to me (at least in Foundry v10). Since Sandbox is ony officially supported for Foundry v9, i assume thats the version you use? In this case there could be a core compatibility issue since Lock & Key is only supported for v10 updwards. I will still take a look at it and see if i can do something about but i can not guarantee for anything.
Oh, you might need the updated version~ This is the version of Sandbox I am using. I am on Foundry v10 Stable - Patch 7 (Build 303). sandbox_0.14.0.dev_RC7_20230205024717.zip
I just released an update (v1.8.2) which should fix the compatibility issues. Theres were some problems going on with the way inventories are handled in sandbox. Thanks for including the save and the system files in the issue, helped a lot with fixing the problem.
Nice! I'll check it out ASAP! Thank you!
Hi, again. I still can't seem to get the module to work. I still don't even see the popup messages for the locks. Do you think it's another module interfering perhaps? or is it because I am not putting the correct format in the "Type of key items" box? do I just put citem? or "citem" or 'citem'? is it case sensetive? like cItem or cITEM? sorry for all the questions and trouble.
"cItem" should be the correct one. Just to make sure, when shift+right clicking a door no item generated in the item tab, right? In this case, doe any error messages pop up in the console (F12), when doing that? It could in theory be a problem with other modules interfering, could you send me list of the modules installed?
Here are all the modules I am using in this game. I'll try and get you some console messages.
Here is the console commands. It seems like it is creating keys. But I am still not seeing pop-ups. Not sure if the keys are functioning as they are supposed to. but Shift+right click is making keys and new matching IDs.
Oh okay. It seems like creating keys with shift+key does create functioning keys for the doors. But I tried copying the key ID data onto an item I had made previously and using that, and the item wouldn't work. Still not seeing the custom popups when the player tries to open the doors though.
I think i found the problem, i will probably release an update, that hopefully fixes the compatibility issues, tomorrow
Great! Looking forward to it! Truly appreciate you responding and working on that so quickly! You are awesome!
Shoot! Didn't mean to close the issue! Wrong button. haha
I just released v1.9.0 which should (hopefully) fix the compatibility issues, let me know if it worked
Okay~ After having one of my players help me test. Popup messages worked for lockpicking (shift+rightclick), and door breaking(alt+rightclicking), but not for locked doors (right+clicking). Also, I couldn't get the system to recognize lockpick cItems. When my player tries to open the door it says he's missing the item, even thought I set it in the module settings.
Also, as a request, can there be popup messages if the player attempts to but fails on lockpicking/breaking?
I looked into it and solved the issue with the lockpick items (hopefully, again). Regarding the Popups messages for the locked doors, is there no message when a player successfully lockl/unlocks a door or if a player tries to unlock a door they do not have a matching key for?
Regarding the popup messages, there should already be Popup messages (Failed to break/pick lock), i would guess that that has something to do with the key popup issue
(in 1.9.0) Messages were popping up when the door was unlocked and locked with the appropriate keys. But the custom popup was not appearing when the door was attempted to be unlocked without the key.
I guess it makes sense that there would be popups for breaking/picking, but I didn't see them. I'll test the new version later tonight with my friend and see. Thanks again for your vigilance, patience, and hard work!
I just released v1.9.1 which should fix the problem with the lockpick items. There is not yet a custom popup for not having a matching key, there was not even a standard popup (until now). I will add an option for custom popups in the next update.
Okay after having my player test stuff with me today.
It is recognizing that lockpick cItems are needed. So that is fixed.
Confirmed door says "no matching key" when trying to unlock a door that has no key. No response when a door with an assigned key is attempted to unlock. (Would love to see a custom popup letting players know that door needs a key when they do normal left click.)
Not recognizing references to sandbox character sheets in lockpicking and breaking formulas. (tried with both @{reference} and @reference formulas) when I try those it either does nothing or just outputs a 0.
When I put in a simple 1d20 formula for lockpicking or breaking, it attempts the rolls twice for some reason. I also see it mention the GM(me) for each roll. Not sure why this is. I had assigned myself as the character for a little while to try to test things by myself, maybe that caused this issue. I had my player screenshot their console for me.
(first two screenshots are mine. third is from my player)
Regarding your points:
Sandbox is a little weird, it's a system designed to help the GM build their own system and character sheets; so there isn't a universal way to reference skill values. I do know that the main thing that the system does reference a KEY on a Property. Most of Sandox works by making new "items" in the Items tab. There several types of items that Sandbox recognizes: properties, panels, multipanels, sheettabs, groups, and citems. Properties are the main thing to look at when dealing with Sandbox; a property is the basic form of data that the system looks at on a character sheet. If you want to reference a property on a character sheet you usually use @{key field data}; so for instance if I made a handun skill and named the Key "handgun" and I wanted to make a roll formula including it, it would probably be 1d20 +@{handgun} Each property must have a chosen data type that it contains and that usually determines how Sandbox deals with it. Tables are the other way to reference items on a character sheet. Tables deal with "groups" which usually references other properties or cItems. When referencing items in a table the formula changes a little bit. Table properties are referenced by a # instead of an @ symbol. So if I made a handgun cItem and put it in a table I would reference it as #{handgun} instead of @{handgun}
As an example. This is the character sheet I made for the game world I sent you that I am currently trying to set up. It is a ttrpg conversion of the Resident Evil Remake video game, but using a rule system that I created, and am using Sandbox to create my character sheets. As you can see there are several properties that can affect my player's rolls.
So here is the SkillTableRoll property which contains the formula for die rolls. You can see the references to property keys on the character sheet and skill table.
I hope this makes sense and helps. Apologies if it was too longwinded. if you want to learn more about Sandbox; these tutorials were made by the creator and explain how to use it and how it works https://youtube.com/playlist?list=PLMAQsyqo9jDFpHYy4WZv0eF_SgqotcUKs&si=ll2hIdu_f-J3Rq77
Oh, also as a note a property Key can be made by whomever is making the character sheets or can be autogenerated by Sandbox. There is no universal key for skills or bonuses. It's made by whatever you fill the Key box with. Not sure if I explained that part clearly, but wanted to make sure.
I think i figured out how to theoretically access the values, here written in console code (ignore the yellow warnings): As expected the system rolls a d20 and adds the value of Skill1ModL, which can be seen here: This should correspond to the "Handgun" attribut of the character "Seth Ward" (see Skill1NameL above). Now, the problem is, that according to these values "Handgun" should be at a value of 5, which is (strangely) not the case: Same happens with the api, so it seems to be the right place: As far as i can see there is also no api function for accessing attributes via their name. If the above formula were to work lock break roles could for example be done like this: I am currently a bit stuck but i will investigate further.
Ok, figured it out, the roll formula to reference the first skill would look like this: @actor.system.attributes.TBL_SKILLSTABLE.tableitems.0.attributes.skillmod.value Replace the 0 with the position in the Skill table (starting at 0) to reference the different attributes of a character. I don't think i can build a system to reference values easier (or by name) due to the modularity of Sanbox, so this way of referencing will probably have to suffice
yeah, I understand that the modularity makes it a lot trickier to deal with, so I wasn't expecting a super perfect solution. Just was hoping to see if we could get some base functionality of it recognizing properties or something~ Excited to try out the next build!
I just released v1.9.2, which should fix two bugs:
Since i cannot reproduce the double rolling bug, i will probably need your world file to figure out what exactly is happening
Here is my world if you need it still: ForgeVTT-export-test-2023-08-23_9_47_10.zip
Regarding 3.: The problem is the modular nature of the module. I would have to write additional code to even reach these formulas (that could break for different worlds/character sheets) and then write an interpreter for the rolls themself (as far as i can see Synbox provides no api for that). Both of these (and especially the last) are bit out of scope for this mdoule. So i will probably not be able to include a feature for that, sorry. Regarding 4.: Should be fixed with v1.9.5
Okay! Just checked with my players and it seems like the popup messages are working correctly now! Thank you for everything!
Good to hear that everything works now, should any more problems arise, feel free to add to this issee or open a new one. I will close this issue for now.
Hi there. Been trying to use the Lock and Key module with the Sandbox system and I can't seem to get any of the functions to work. I applied the "sword;" key to the "Sword Key" compendium item and also on one of the locked doors, but nothing happens and no pop-ups also occur. I am adding my world from foundry/forge-vtt to test. ForgeVTT-export-test-2023-08-14_21_24_13.zip