Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jsonize autodoc couch #36200

Merged
merged 11 commits into from
Jan 2, 2020
Merged

Jsonize autodoc couch #36200

merged 11 commits into from
Jan 2, 2020

Conversation

Fris0uman
Copy link
Contributor

@Fris0uman Fris0uman commented Dec 17, 2019

Summary

SUMMARY: Infrastructure "Jsonize autodoc couch"

Purpose of change

Code was checking for the furniture id to find the couch, now it checks for a flag

Describe the solution

Check for AUTODOC_COUCH flag instead of f_autodoc_couch furniture id
Check for AUTODOC flag instead of f_autodoc furniture id

Describe alternatives you've considered

Testing

Give autodoc iexamine to armchair
Give AUTODOC to armchair
Give AUTODOC_COUCH to domestic plant
Stand on plant
Examine armchair
Start installing CBMs

Additional context

This would make moding autodocs easier

@Night-Pryanik
Copy link
Contributor

I'm not against jsonizing, of course, but autodoc couch isn't any couch or sofa you find in nearest house, it has several specific features (like hand wraps or integrated machinery or complex electronics connected to the autodoc) in it. I'm not sure if it would be possible to mod some other furniture to simulate it being the proper autodoc couch.

@SirPendrak
Copy link
Contributor

SirPendrak commented Dec 18, 2019

Does it mean we can hope for mobile vechicle versions of autodoc in the future?
(Made from parts of original Autodoc and its couch, not some survivor-made one)

@Fris0uman
Copy link
Contributor Author

No, vehicle part are something else, and would require a whole bunch of new code. But you can make a craftable item that deploys into an autodoc if you want. It might work with just one furniture that has both the flag and the examine action, and if it doesn't you would need two furniture: a console and a couch.

src/iexamine.cpp Outdated Show resolved Hide resolved
@BevapDin
Copy link
Contributor

f_autodoc_couch is used at other places:

"activity_handlers.cpp"
"monattach.cpp"
"monmove.cpp" (twice).

Also consider removing the global variable f_autodoc_couch (declared in "mapdata.h").

@I-am-Erk I-am-Erk added [C++] Changes (can be) made in C++. Previously named `Code` [JSON] Changes (can be) made in JSON Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. labels Dec 18, 2019
@Fris0uman Fris0uman changed the title Jsonize autodoc couch [WIP] Jsonize autodoc couch Dec 18, 2019
@Fris0uman Fris0uman changed the title [WIP] Jsonize autodoc couch Jsonize autodoc couch Dec 18, 2019
src/map.h Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. [JSON] Changes (can be) made in JSON
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants