Visual node-based crafting system, inputs and outputs implementation
Hello everyone,
I'm designing a game where the player can creatively combine elements to manipulate the effects produced by his/her gear (namely , weapon, shield, and a drone). The basic idea is : everything starts with an amount of energy "poured" into the system, and getting through nodes you can associate to obtain effects.
For example, in a weapon, the raw energy coming to the weapon could then go through different parts like in the examples of the image below:
So the idea is to implement a system where nodes use various inputs to output their desired effect. Each node could also present opportunities for "modding" (the little Mod circles), but I guess that's a secondary issue to deal with after I'm able to nail the basic implementation structure.
The player will have to craft those "nodes" (using parts found during gameplay and following recipes), and then open the circuits of his/her gear to arrange them into a desired output.
I started out with enums for each different type of input/output (raw energy, damage, regen, etc.), then thought of developing a separate class for each node to handle the combinations on a per-case basis, but my programming skills are not good enough for me to approach the problem with a clear implementation.
I guess my question is, how would you approach the implementation of such a system?