Door & panel states (damage) not syncing for vehicles with custom model IDs
engineRequestModel("vehicle") gives you a new vehicle model ID. Logically this ID needs to be applied to an element using setElementModel. You may also want to use engineFreeModel when the element streams out to save memory at some point.
I've noticed an issue while testing my newmodels resource related to visible damage on the vehicle not staying.
Door & panel damage that you can obtain on a vehicle by damaging it yourself or using setVehicleDoorState & setVehiclePanelState resets after the vehicle's model is changed.
This is problematic and can strongly be considered a bug as it's some unintended behavior.
Serverside sync should fix this issue.
Version r21135
See how to reproduce: https://github.com/Fernando-A-Rocha/mta-add-models/commit/679fcc74932dc0d0ef53be2ed837d6c419801886#diff-42765a3fba5de103617ea4bbc5cf9c08274deed18913ce00514f6678cfdbded8R237
Other important related issue: #1861
@TheNormalnij Possible to fix this? Sorry for ping but this was created in march 2022 and more bugs related to allocated model IDs have been fixed recently, so this could be too?
This should be fixed in #2533