1
0
Fork 0

Look for protocols in aircraft paths

Modified from patch by Slawek Mikula
This commit is contained in:
James Turner 2019-12-17 22:34:19 +00:00
parent fad9f7068f
commit c48c1a06e8

View file

@ -753,12 +753,13 @@ bool FGGeneric::close() {
void
FGGeneric::reinit()
{
SGPath path( globals->get_fg_root() );
path.append("Protocol");
path.append(file_name.c_str());
SGPath path = globals->resolve_maybe_aircraft_path("Protocol/" + file_name);
if (!path.exists()) {
SG_LOG(SG_NETWORK, SG_WARN, "Couldn't find protocol file for '" << file_name << "'");
return;
}
SG_LOG(SG_NETWORK, SG_INFO, "Reading communication protocol from "
<< path);
SG_LOG(SG_NETWORK, SG_INFO, "Reading communication protocol from " << path);
SGPropertyNode root;
try {