Closed bleehu closed 6 years ago
Yes.
Some additional field possibilities include Quantity, MS Penalty, Attached to, etc. I would include cost since it's valuable for validity checks if a character goes unplayed for awhile. Ideally we would have the cost field autofiled from another table that includes all items in the game and their costs, but I don't know how easy it would be to keep such a thing updated.
MS penalty? I'd like to track attachments along with weapons.
Is that smooth if we have attachments that aren't currently on a weapon, such as if someone wants to swap off between the underbarrel shotgun and grenade launcher?
MS Penalty as a stat if and only if we want to have very large items incur an encumbrance-like penalty.
My assumption is that while it wouldn't be smooth, the value of having your character sheet in the cloud is enough to keep a user wanting to continue to use our tool, even if the act of pulling a scope off of a weapon and throwing it in their backpack is a two-step process of changing what attachment is on the weapon, and then adding an inventory item separately. There are around three other assumptions that led me to that strategy. If any of them are wrong, then I'm going about this the wrong way. The biggest of these is that while we can't trust a user from a software security perspective, we can trust a user from a player/GM perspective. While we should make affordances for users so that its easy to learn and follow the rules, as the rules are still oft-changing and as long as a GM can make exceptions as they see fit, the tool will be much easier to use if we allow players to author their character as they see fit. Up to and including deleting scopes or just giving themselves new items.
This is sane. If not trust players, not play in the first place.
Compromise? When listing attachments on a weapon, would it be reasonable to instead list a duple of (String:Attachment, Boolean:In Use) ?
Would it be easier to track weapons, armor and attachments separately, and append them in the view to the end of the inventory?
If attachments are in their own table, I would imagine one of their boxes is an Attached to and is either the id of a weapon the character has or null is unattached. That seems fairly smooth, but would it increase the complexity of mathing out the resulting stat increases when looking at the weapon itself?
It is done!
@Turtlelord26, are you able to ssh to prod and add some tables for character inventory items? I'm thinking
pk_id created_timestamp name deleted_at timestamp fk_character_owner
Haven't decided if we should handle item cost or not.