Why does my tweening door do this?

  1. What do you want to achieve? Keep it simple and clear!
    I want to fix my tweening door. So basically the door is originally in replicatedstorage at a random position and when the door is put in workspace and i use the proximity prompt which triggers the door tweening the door teleports to where the position was when it was in replicated storage and comes back to its position in workspace. After that it works as normal again Heres’ a video of it happening:

  1. What is the issue? Include screenshots / videos if possible!
    I don’t know why its doing that.

  2. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I have tried YT and Devforum.

Here’s my tweening code :

I’m a bit confused, but I’m pretty sure that you want to set the door cframe and not tween it when you spawn it in.

Yea, if you’re spawning it in, you don’t want to tween it. Tweening will animate it like that. When moving it into replicated storage to the workspace you just want to set the Cframe at the same time.

As an aside, I hear you ought to limit the amount of stuff you stick in replicated storage to stuff both the client and server will need, bc iirc things in replicated storage use clientside memory. Depending on what you’re doing, in a full game consider using server storage instead.

Please post the scipt you use to spawn the door in. I doubt the ProximetyPrompt tweening script is your issue.

they did, it’s in the screenshot.
at least from what i can tell, a starting position after getting the door out of replicated storage is never set, so it seems to be tweening from the cframe it had in replicated storage once it’s in the workspace as opposed to tweening from where it’s actually supposed to be starting from.

Why are you tweening a value as the Instance? Can’t it just be the center (if its the PrimaryPart)
You should probably use CFrame, if you use a target, or Orientation to make it more simpler, not Value
Don’t create the tween and instantly play it, it causes problems sometimes
Make a variable for the TweenInfo

Try welding the door to a part set up next to the door frame permanently. Then tween that part to move the door. Maybe that’s a WeldConstraint … I forget.

like this … Working Roblox toolbox door. #1 stop for questions.

Actually no they didn’t.
It’s just the ProximityPrompt Tween script. There’s nothing in there about how the door is spawned in from ReplicatedStorage.

2 Likes

To spawn it in, i just moved it from replicated storage to workspace

Can it just be because the door in ReplicatedStorage is like somewhere else? Not in the same spot as the door you can see in the video?

1 Like

Yea, thats the problem that i stated

I don’t think you understand me, the door in ReplicatedStorage might be in a wrong spot, can you drag it to the workspace and see where its Position is?

Its at the position where i moved it to…

Its ok, I’ll figure it out myself, I think I know what to do

If you do have a solution please post it here and mark it with the Solution button so other people don’t try to keep solving it.
And if anyone searches for the same issue then your post can help them.

I suggest you create tween outside of the function and then just play it, because creating it inside proximity could probably mess with a CFrame