syncing dont work!!
i set up syncing with cahrm-sync but when i change server atom nothing happens! sync:connect() dont fire and subscriptions to server atom too



Solution:Jump to solution
charm is immutable, u should clone the tables before writing data in your updater function
14 Replies
Unknown User•3mo ago
Message Not Public
Sign In & Join Server To View
where is your atom actually being changed
yes ofc
when other class is created my server atom changes, if i print it later anywhere atom's state is changed too, but subscriptions and then connection dont get called
show code
this func get called and here output in game,
it prints SYNCING... when syncer.connect on server gets called, so it gets called only once when hydrated and then nothing


here
state mutation
what?😃
ur mutating the state
that's the issue
ima go read charm docs then i dont understand what ur talking about
thanks!!
i cant change server atom's state anywhere except where it was created?
no
Solution
charm is immutable, u should clone the tables before writing data in your updater function
might as well use spreading syntax
oooooohh i see
tysmm
it worked!!