Is your feature request related to a problem? Please describe.
As I begin working on NPC behaviour around the refugee center, one thing I'm going to start running into as a problem is the lack of NPC reaction when the player messes with stuff in the center. I don't need these done tomorrow or anything, but over the next couple weeks as I continue expanding the center.
Describe the solution you'd like
I see three potentially separate types of ownership to be considered. I'll list them in order of how easy I think they would be to code.
a mapgen tile with faction ownership should have furniture and terrain (not items etc) reset to their base state every few days to represent the faction keeping it up, fixing broken windows, moving furniture back, etc.
Vehicles: I'd like to be able to give the free merchants some turrets and things similar to what the player has, but I don't want to allow the player to steal them.
faction vehicles should also either automatically fully repair after a while (maybe slower than furniture and terrain) or (better) should slowly auto-heal to represent their attendants keeping them fixed.
Items: I feel like this would be the toughest but maybe not. Faction items would be defined in mapgen as well like vehicles, under the item placement entries.
Describe alternatives you've considered
Terrain and furniture ownership is the least necessary of these, but I like the idea of linking it to base repairs.
Item ownership could be made much simpler but also crappier, by making all items on an owned map tile become owned by the faction, and just making guards get mad at you for taking them, but then items dropped by the player would become faction property. This would be a good stopgap though.
Vehicle ownership isn't immediately needed, but if implemented then I'll use it right away to make manned turrets in the center, and maybe put a car in the garage.
Looks pretty reasonable.
Couple of thoughts:
The faction possession tag could also be used for the PC faction to implement PC owernship of stuff and get NPCs to stop stealing stuff.
Players and NPCs shouldn't be prevented from stealing stuff or siphoning fuel from vehicles or whatever. They should get a pop-up that stealing may turn people hostile and choose not to steal, but you should be able to steal from hostiles without them preventing it other than by shooting you. And of course, you can steal from nominal friendlies as long as they can't see you doing it.
Kevin will have to okay it, but I think it's a good solution.
See also #19439 for more on ownership and theft prevention in CDDA.
I agree with most of the outline, entities get labelled as faction owned (a tag on an item or vehicle, a zone for furniture works for this), and then it can trigger repercussions if the player interacts with owned entities while in sight of a faction NPC.
The tricky part IMO is managing feedback in a reasonable way. Making item ownership visible to the player is questionable due to leaking information, but it's also potentially frustrating to be told after the fact that things are faction-owned.
In common areas, in particular outside the structure, warnings that interrupt the action are appropriate. Either, "this may upset
I think turrets in particular are simpler than you think, turrets would just not be programmed to allow the player to approach, the turret itself would aim at the player if they approached within some distance (triggering a warning), and start firing if the player got within some closer distance. This would be rendered "safe" by e.g. interposing walls to break turret LOS to certain areas.
If police robots get ownership for everything that doesn't have any other owner, they'll naturally go around arresting/shooting people for stealing stuff.
I do like the idea of the "guard" interaction being a pop up dialogue with Y/N. This could apply to everything from dismantling/smashing furniture to stealing stuff, and so could use pretty much the same function call for everything. If the function call could recognize the type of crime so that the NPCs use the right dialogue snippets and maybe add the right crime-punishment effect, so much the better. It's probably simpler than what I've got listed as well, because it doesn't require warnings and timers... As a popup it can be one and done, there's no excuse for missing it.
I love the idea of turrets beeping warnings, but the NPC interaction still needs to exist. For example if I add a vehicle and attendant to the garage of the refugee center, the attendant should be able to stop you from messing with it.
Of course, with crime comes the ability for an NPC to subdue the player, or for the player to surrender and have the faction take compensation (steal items equivalent to bounty?) or I suppose, deal with crime however a given faction would with their individual politics.
tying up/cuffing NPCs and the player when they are at a knocked out state or have high enough pain that they don't have the strength and/or dex to resist is an idea.
A consciousness system would greatly benefit the game in some other situations, ie: if the player is attacked by a moose and is knocked unconscious, the moose will not likely continue attacking, but a predator will, a zombie will, but anything that does not want to eat you will not, perhaps fungus will simply ensure the player has been injected with spores and is subdued, then leave them for dead unless they are close to a base?
I don't think this issue is actually done, Dpwb's PR only addressed the item ownership issue. Furniture/terrain ownership still stands.
I don't think this issue is actually done, Dpwb's PR only addressed the item ownership issue. Furniture/terrain ownership still stands.
I agree. Furniture could be as valuable as items (so as walls).
Personally I'd also like to see furniture and terrain auto-repairing over time as part of it, but that does depend on how far we are from mlangsdorf getting NPCs to perform maintenance. I think that's much closer than we thought.
Most helpful comment
If police robots get ownership for everything that doesn't have any other owner, they'll naturally go around arresting/shooting people for stealing stuff.