Hello!
I am searching for a keyword so I can search for this topic I want to learn, but not sure how to phrase it.
Usually now, I do everything through casting. Which is bad for modularity.
I have been messing a lot with Interfaces, but it’s still not there, the proper modularity.
Let’s say I have a ship. This ship has “modules”, that player can install. The ship is the brains of everything.
I’ll just throw in an example:
Now I install a gun, it takes ammo, and electricity. I install generator, it takes fuel, but adds electricity, which the gun can use. The ship is running out of fuel, so I add new upgraded fuel tanks. Engine needs upgrade, because when it broke, it stopped taking fuel from the fuel tanks, the generator stopped, and guns stopped working. After I upgrade the engine, it takes more fuel… Etc.
All of these “modules” need to communicate between one another, they shoudl be hot swappable, etc, request if other module has certain amount of resources, turn off other modules, but they can’t be directly “connected”.
How would you go about this? If you guys know what I mean? Is there some keyword in programming lingo that I can research? Modular blueprint scripting doesn’t return me much.
Thank you