KerbalEngineer icon indicating copy to clipboard operation
KerbalEngineer copied to clipboard

API for other mods

Open SirMortimer opened this issue 6 years ago • 0 comments

May I propose something along these lines:

KER.API.AddSection(string sectionName, List<string> variableNames, MyValueCallback);

public string MyValueCallback(Vessel vessel, string sectionName, string variableName) {
  return "hello!";
}

That way users would be able to add values of other mods to the KER HUD, including all the bells and whistles that KER already provides. We'd use this for telemetry values like CO2 levels, as well as for science related values (sun-body-angle)

https://github.com/steamp0rt/Kerbalism/issues/380

(PS: posted this in https://github.com/CYBUTEK/KerbalEngineer/issues/154 before. I love orphaned projects)

SirMortimer avatar Jun 28 '19 17:06 SirMortimer