MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / importVehicle1

Function importVehicle1

src/OpenLoco/src/S5/S5Entity.cpp:663–687  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

661 }
662
663 static void importVehicle1(OpenLoco::Vehicles::Vehicle1& dst, const S5::Vehicle1& src)
664 {
665 dst.head = static_cast<EntityId>(src.head);
666 dst.remainingDistance = src.remainingDistance;
667 dst.trackAndDirection.track._data = src.trackAndDirection;
668 dst.subPosition = src.subPosition;
669 dst.tileX = src.tileX;
670 dst.tileY = src.tileY;
671 dst.tileBaseZ = src.tileBaseZ;
672 dst.trackType = src.trackType;
673 dst.routingHandle._data = src.routingHandle;
674 dst.var_38 = static_cast<Vehicles::Flags38>(src.var_38);
675 dst.nextCarId = static_cast<EntityId>(src.nextCarId);
676 dst.var_3C = src.var_3C;
677 dst.mode = static_cast<TransportMode>(src.mode);
678 dst.targetSpeed = Speed16(src.targetSpeed);
679 dst.timeAtSignal = src.timeAtSignal;
680 dst.var_48 = static_cast<Vehicles::Flags48>(src.var_48);
681 dst.var_49 = src.var_49;
682 dst.dayCreated = src.dayCreated;
683 dst.var_4E = src.var_4E;
684 dst.var_50 = src.var_50;
685 dst.var_52 = src.var_52;
686 dst.lastIncome = importIncomeStats(src.lastIncome);
687 }
688
689 static void importVehicle2(OpenLoco::Vehicles::Vehicle2& dst, const S5::Vehicle2& src)
690 {

Callers 1

importVehicleEntityFunction · 0.85

Calls 1

importIncomeStatsFunction · 0.85

Tested by

no test coverage detected