User Details
- User Since
- Jun 22 2019, 2:24 AM (283 w, 6 d)
Jun 5 2021
Фидбэк, который мы заслужили
May 18 2021
It's just reproduce example on the video, of course I've stuck with this while was writing code by classic methods like - _unitLoadout = getUnitLoadout _unit; _unit2 setUnitLoadout _unitLoadout and etc...
If needed I can post a function. Unfortunately it doesn't matter which way u choose to write code with this command, because only setUnitLoadout command brokes it (I've tried all possible ways to write this code to avoid bug)
May 17 2021
Video
P.S. Command brokes replication if loadout array has uniform
It has strange behavior. When I use this command in vanilla (from dedic on not local unit) it has chance to fail about 30% fail and 70% success. But right now I am writing script on moded server (armstalker mod) and it has 100% chance to broke replication. I've notice strange dependency - if my loadout array has uniform it will cause replication fail and sync will stop (only reconnect helps)
My steps is
- Apply setUnitLoadout command from dedic server to not local unit (uniform must be in loadout array)
- Ask that unit to drop any item (unit must ba player)
- Scan unit loadout by getUnitLoadout command from dedic
After that U can see, loadout array hasn't been changed
I can share video if needed
It's broken again, after using this command (I tried use it from dedic) inventory replication becomes broken and stops. Only reconnect helps. Weird thing is that, command will crash replication only if array with loadout has uniform.
SetUnitLoadout is broken again