#char position being different client side and server side

1 messages · Page 1 of 1 (latest)

plush pelican
#

so im making some sort of dash system using cframes, but for some reason the position of the character is off between the client and server side (and also the direction seems to be off sometimes) despite the cframe only being changed in the server script

plush pelican
# plush pelican

i made the position to be sent from the localscript to try and make it seem less janky cuz of lag

#

(like the direction being a few moments delayed)

#

i would also like to keep the dash mechanic to be teleport rather than linear velocity

hard zodiac
#

it’s not really something you can fix

plush pelican
#

the position isnt delayed

#

its just entirely different

hard zodiac
#

it your trying to do it on both ends it would

unique tulip
#

why dont u jus do all the calculations from the server

#

and dont use cframe directly

#

pivotto or moveto

#

or use linearvelocity or somethn

#

ur jus going about this all wrong, this looks like a chatgpt script to me

plush pelican
#

because im trying to go for a teleport effect

unique tulip
#

you need to

#

cos ur always gonna get rollback for one

#

especially when ur sending freely available information the server could more accurately pinpoint

#

stop using chatgpt

#

and actually look at roblox documentation

plush pelican
#

so the server is seeing a few moments late than the client's

unique tulip
#

also

#

use lookvector if anything

#

if you want a directional axis

#

idk why ur using toworldspace and directly modifying the humanoidrootpart

#

this whole script makes no sense

#

to avoid delays use pivot or use lv

#

it is literally designed for this kind of thing, you're just being unnecessarily lazy

plush pelican
#

dude

#

i literally have a lv module script

unique tulip
#

a lv module script?

plush pelican
#

honestly if you dont know how to help me then dont help at all

unique tulip
#

lv is literally one line of code

#

😭

plush pelican
#

linear velocity module script

unique tulip
#

i do know how to help you

#

rewrite your code

#

cos that aint it

plush pelican
unique tulip
#

you're not looking for look vector

#

and also

#

the hrp has a root attachment

#

so you're just creating unnecessary attachments

plush pelican
#

so? it gets deleted after abit anyways

unique tulip
#

if you're making a fighting game with 50 players