How can i shoot the ball to the other side of the court when hit?

  1. What do you want to achieve? Keep it simple and clear!
    i want to shoot the ball to the other side of the court when the player swings the racket
  2. What is the issue? Include screenshots / videos if possible!
    I cant figure out how
  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I’ve looked at tutorials, searched through the forum and i couldnt find anything and didnt

i would highly appreciate any help!

1 Like

and it uses a tool, Q means more to the right and E more to the left.

1 Like

The comment I just wrote out doesn’t describe it well enough, I will just show you a script and explain it form there, sorry.

oh and i also forgot to mention that i want it to be able to work with .Touched

1 Like

Do you mean .Touched for hitting the ball back? If so I doubt that would be very accurate and I believe its a better idea to just use magnitude.

1 Like

Thats the showcase of it. Here are some notes.
You could do this in a server script alone, but I assumed you would want to use userinputservice it be able to press a key and hit it back. Also sorry it took so long, the video did not want to work.

1 Like

got an error: attempt to index nil with ‘WaitForChild’ in the LocalScript Line 4

nvm i got it to work

filler text

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.