mirror of
https://github.com/dcs-retribution/dcs-retribution.git
synced 2025-11-10 15:41:24 +00:00
Force re-scanning of loadouts after the injection: inject_mod_payloads(Path(THIS_DIR.parent / "resources/mod_payloads/f16i_idf"))
This should fix a KeyError on a loadout path with the loadout files in resources/mod_payloads/
This commit is contained in:
parent
ae7a3ffa70
commit
ad09548c69
@ -6,6 +6,7 @@ from typing import Dict, List, Any
|
||||
from PySide2.QtGui import QPixmap
|
||||
from dcs import task
|
||||
from dcs.planes import F_16C_50, PlaneType
|
||||
from dcs.unittype import FlyingType
|
||||
from dcs.weapons_data import Weapons
|
||||
|
||||
from game.modsupport import planemod
|
||||
@ -313,6 +314,9 @@ def inject_F16I() -> None:
|
||||
F_16C_50.Pylon16 = Pylon16
|
||||
|
||||
inject_mod_payloads(Path(THIS_DIR.parent / "resources/mod_payloads/f16i_idf"))
|
||||
# Force re-scanning of loadouts after the injection above
|
||||
FlyingType._payload_cache = {}
|
||||
FlyingType.scan_payload_dir()
|
||||
|
||||
|
||||
@planemod
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user