Research Progression (No Skip)

Hey all. 

I'm really into running my own PVE server for myself and some friends. 

Finding certain items in crates or drops and being able to research them without the prior unlocks seems... great if you wanna be done with the game in 3 days. 

Would it be possible to make a plugin that would require you to research things in order, but ALSO require that you research at least one before being able to craft them? 

If I just cared about the order, I could disable the research table. But I want us still have to find one first rather than just farm scrap to speed through unlocks. 

The overall experience is certainly possible from a technical standpoint, but there are some constraints to be aware of. For example, plugins cannot modify the tech tree UI, nor can they detect the player opening the tech tree. However, a plugin can detect the player attempting to unlock a blueprint via the tech tree in order to show a temporary UI message.

Here's how I would probably implement this. When the player attempts to unlock a blueprint in the tech tree, if they had already studied the blueprint, the unlock would be allowed. If the player had not previously studied the blueprint, the unlock would be disallowed, and a short duration popup UI would be displayed informing the player that they must first study the physical blueprint for that item. When the player does study a physical blueprint for the item, the plugin would internally save that the player had done so, but that action would not actually unlock the blueprint. A message could also be printed in chat to the player letting them know that they can now unlock the item via the tech tree. The plugin would need to record which players studied which blueprints into a data file to ensure consistency across plugin reloads and server reboots. That data file could optionally be cleared on map wipe, depending on whether you want to persist blueprints across wipes like many servers do.

The experience could potentially be expanded a bit to allow players to perform the blueprint studying and the tech tree unlock in either order, but that would significantly increase complexity and complicate the player experience, so I would suggest the above approach where the physical blueprint must be studied first.

One question, does this mean the player should have to pay double to unlock each item? They would need to pay the same amount to create the physical blueprint as to unlock the tech tree node. Plugins are capable of making the actual tech tree cost 0, but the UI for that cannot be altered, so players might mistakenly think they need scrap in the tech tree, when they actually don't.