Forrest Posted January 19, 2014 Posted January 19, 2014 Is there any difference between the lag caused by either using server-sided createObject or client-sided createObject/.map file? Thanks.
Moderators IIYAMA Posted January 19, 2014 Moderators Posted January 19, 2014 AFAIK, functions from serverside have less lagg impact, because they are using just 1 function. https://wiki.multitheftauto.com/wiki/LoadMapData And when you are loading them on clientside, you need a lot of functions per object to set their properties. Do you want to improve your Lua programming skills and make less mistakes? Start with Lua Language Server! Useful functions 3x Spoiler checkPassiveTimer getScreenStartPositionFromBox getPedGender Tutorials 4x Spoiler Scaling DX Events Attach an addEventHandler on a group of elements Debugging
Gallardo9944 Posted January 19, 2014 Posted January 19, 2014 in fact, if you're creating something clientside, the actual objects are stored and created clientside, thus resulting into a client lag (depending on the map size). If you perform the same thing serverside, the client will have less impact, but the server might slow down for 1-3 seconds (depending on the map size agaib), but the objects removal might also be very slow (destroyElement on about 8000 objects might take 5 seconds of frozen server) Code Debugger - Minimalistic MTA debug line replacement
Forrest Posted January 19, 2014 Author Posted January 19, 2014 I'm only needing to create around 450 objects, won't be destroyed. All should be well server-side in that case, thanks.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now