Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How Do I Make An Animation Play Only For The Local Player?

Asked by 1 year ago

Hello. So I want to create a script / local script that when there is a person who joins my game, then there is a model of a bus that plays a little animation. I have already made the animation that I wanted to put on the bus, the bus is called "SchoolBusAmim" and it is placed in the workspace. I want it to be the local player who joins the game who can see the animation, I don't want other people to be able to see it. Thank you very much in advance, I hope to have an answer. (The bus is not a rig but a Model and I placed the AnimationController and the Animation objects in the bus model.)

1 answer

Log in to vote
0
Answered by 1 year ago

If the bus is the one playing an animation, then all you have to do is use AnimationController:LoadAnimation() and AnimationTrack:Play() from a localscript given to the specific player who sees the bus animation.

Since the bus isn't a player's character, the animation played won't replicate to other players. Only the player with the localscript will see the animation play.

Ad

Answer this question