Skip to content

Commit

Permalink
Fix all same type aircraft sharing properties.
Browse files Browse the repository at this point in the history
Whatever properties were set last would apply to all aircraft of the
same type because this was copied by reference.
  • Loading branch information
DanAlbert committed Jul 21, 2023
1 parent 45ce9c5 commit fe54142
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dcs/flyingunit.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(
self.speed = 0
self.radio: Optional[AircraftRadioPresets] = None
self.hardpoint_racks = True
self.addpropaircraft = _type.property_defaults if _type.property_defaults else None
self.addpropaircraft = dict(_type.property_defaults) if _type.property_defaults else None

def load_from_dict(self, d):
super(FlyingUnit, self).load_from_dict(d)
Expand Down

0 comments on commit fe54142

Please sign in to comment.