Replies: 1 comment 1 reply
-
tl;dr: welcome aboard! I myself became a regular contributor because I had a project idea ( Anything that runs in the background at high frequency is usually implemented as a C++ plugin for performance reasons, but functionality-wise, anything you can do in C++ you can also do in Lua. Our C++ API is directly exposed to Lua. If you look in existing scripts, calls to Also, C++ plugins have Lua extensions that are considered part of the plugin. The C++ and Lua code call each other freely. What you are describing could be written in Lua alone (most anything can, really). However, I'd expect it to eventually be integrated with So this is what I'd suggest:
The prototype will likely follow the pattern of emigration, which uses You'll also eventually want a GUI so the player can inspect and modify labor assignments manually. We have something like this planned anyway for manipulator, and that can integrate with what you're writing (and with |
Beta Was this translation helpful? Give feedback.
-
Hello. I have a few questions, and I'm hoping this is an OK spot to ask. I am interested in contributing to the project. Are contributors welcome? I have a lot of experience with a handful of scripting languages, including lua. But I'm guessing I would need to learn some c++ to be able to help with plugins, which is what I'm particularly interested in. I have no experience with lower level/compiled languages, but I would like to, at some point, attempt a labor related plugin that mimics the optimization plan functionality of dwarf therapist, except automated like autolabor. I want to accomplish the same goal as vanilla work details, inside DFHack (not necessarily using the work detail system btw), so players can automate choosing skilled dwarves for jobs - something I find very cumbersome in vanilla when my fort gets to 100-200+ dwarves, and I start not bothering to check immigrants for better workers. Or even just repeated new games or random dwarf injury/moods, and not wanting to assign labor.
Would such a project be welcome? And if yes.. do you have any advice on where I should start? I assume there isn't enough exposed to lua to be able to make such a plugin in lua alone? If there was, I'd definitely go that route (and would love to hear about it!). Assuming not, would I need to learn c++ before considering anything else? Despite not having used c++ previously, I can pretty much read and understand most of https://github.com/DFHack/dfhack/blob/develop/plugins/autolabor/autolabor.cpp and some other plugins, so I'm not a completely lost. But that's where my starting point would be.
Thanks for any advice/answers you can give me.
Beta Was this translation helpful? Give feedback.
All reactions