Closed xxshady closed 1 year ago
If you send baseobject (vehicle, player, etc.) via network it can be received as another baseobject, which is ABA problem.
JS code:
server
alt.onClient('test', (player, obj) => { alt.log('test:', obj, obj?.id) alt.log( 'is bmx:', obj.model === alt.hash('bmx'), 'is sultan:', obj.model === alt.hash('sultan') ) }) let veh alt.onClient('destroy', (player) => { veh.destroy() veh = new alt.Vehicle('bmx', 0, 0, 0, 0, 0, 0) alt.log('recreated veh id:', veh.id) }) veh = new alt.Vehicle('sultan', 0, 0, 0, 0, 0, 0) alt.log('created veh id:', veh.id) player.emit('test', veh)
client
alt.onServer('test', (obj) => { alt.log('on server test') alt.emitServer('destroy') alt.emitServer('test', obj) })
Somehow prevent it in the distant future, since as Heron said, there is no way to fix it now.
No response
Windows 11
15.0-dev404
It's core issue, and Heron said it wont be fixed
Description of the problem
If you send baseobject (vehicle, player, etc.) via network it can be received as another baseobject, which is ABA problem.
Reproduction steps
JS code:
server
client
Expected behaviour
Somehow prevent it in the distant future, since as Heron said, there is no way to fix it now.
Additional context
No response
Operating system
Windows 11
Version
15.0-dev404
Crashdump ID
No response
Reproduction tested