mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Fix handling of destroyed buildings.
This commit is contained in:
parent
7ae934e940
commit
2d9e5fe984
@ -112,7 +112,9 @@ class UnitMap:
|
|||||||
group: Group) -> None:
|
group: Group) -> None:
|
||||||
# The actual name is a String (the pydcs translatable string), which
|
# The actual name is a String (the pydcs translatable string), which
|
||||||
# doesn't define __eq__.
|
# doesn't define __eq__.
|
||||||
name = str(group.name)
|
# The name of the initiator in the DCS dead event will have " object"
|
||||||
|
# appended for statics.
|
||||||
|
name = f"{group.name} object"
|
||||||
if name in self.buildings:
|
if name in self.buildings:
|
||||||
raise RuntimeError(f"Duplicate TGO unit: {name}")
|
raise RuntimeError(f"Duplicate TGO unit: {name}")
|
||||||
self.buildings[name] = Building(ground_object)
|
self.buildings[name] = Building(ground_object)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user