Thank you for your aswer.
Anyway I had more problems using the turret behavior.
It should work if every player joins before the game starts. But if a player joins after others players it's a little more complicated. Because I send all existing turrets from the server to the new player so the client can create those. But I have to send the all turrets in the same order those were created. Because (I think) if there are two targets at the same distance, the turret acquire the first created one. And if I do not send turrets in the same order those were created, in a client the target can be different from anothe client.
Also my clients create objects at runtime that are not created on others clients. So uid and targetuid can differ from client to client (i.e. because while a new client creates turrets that it receives from the server it can create another object on the fly addng +1 to the next turret uid).
All those poblems surely have solutions. Anyway it's little too bit complicated.
I have found a workaround in this topic:
It's not using the turret behavior but storing custom turret IDs and target IDs client and server side makes clients be synced.