#How do i script a fireball attack

28 messages · Page 1 of 1 (latest)

latent aurora
#

Idk

blazing barn
#

Well,

#

Detect user left click.

#

Send to server via a remote event.

#

Spawn fireball.

#

You'll soon learn about the difficulties of client-server interactions. 😦

green mauve
blazing barn
#

Pointless. A script is good and enough, unless you want to make a full weapons system, then use a module, sure.

#

In any case, the real problem with fireballs and any type of weapon/vehicle is the server latency.

#

You can cure a bit the lag on 1 client, all the others will still suffer.

#

Gotta compensate the lag with some prediction.

#

Only problem is that predictions are inaccuraet.

hollow marten
#

learn something called "fastcast"

#

lots of tutorials

ebon hawk
ebon hawk
ebon hawk
green mauve
blazing barn
blazing barn
#

You won't get away simply with a "deltaTime" (whatever you mean by that).

#

Player inputs are not linear and prevedible.

blazing barn
#

You can't predict what the users are going to do.

#

During the passage client-server-client you're gonna lose accuracy in any case.

#

You can do whatever you want to reduce it as much as possible, but nothing will be THAT great.