Matter Client Structure
so i am working on a tower defense game, and the enemies entities movement is fully handled on the server and the client just gets the result every 6 frames (aka 10 times a second) but i am not sure how to structure that, currently in my world starting client script i just listen to the remote event that has the enemies new positions that are sent from the server i then add it to the client enemy entities through a component and there is a system that just moves enemies to that target position, my issue is that i would like to have a system that handles that instead of having to use a script to get the new positions then a system to move them
12 Replies
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
sorry i was sleeping
this is the replication system from the server
this is the client script which starts the world, but it also has two functions which connect to the remote events of adding new enemy, and replicating enemies' new data
and this is the system on the client which handles moving the enemeis (still unfinished)
.
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
what's wrong ? is it that bad ?
anyone can help me with this please ?
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
what about the event of that system ? what should i set it as ?
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
but wouldn't that make the system run each frame ? I'm not quite sure i get what you mean
Unknown User•6mo ago
Message Not Public
Sign In & Join Server To View
alright i will try that
thanks for the help <3
but i don't think it works with flamework networking remote events ? since i remember matter system event required
Connect, Once, ConnectParallel, Wait
Methods, but the library doesn't have them