How do I Teleport All players in the server to another game?

I didn’t think of that. Let me try that.

1 Like

I didn’t work but it might be because for some reason my alt can’t get into the van.

This won’t work in Studio, You gotta use it in Roblox Player ( Play game).

1 Like

I have been using Roblox Player.

This is puzzling. I mean, all players should be able to get into the van yes, but if the driver fires a server script to fire all clients, then those clients fire the server to be teleported, it should be working. I haven’t used OnClientEvent() much since I never had to update GUI for other players, but yeah I’m completely puzzled.

What does your console say, if anything?

1 Like

It doesn’t say anything at all. Neither in the client nor the server.

1 Like

Put print() statements everywhere. I know it may be overkill, but that’s all I can recommend at this point. I really thought I had it with the fire client solution but I guess not.

What I mean is, put print() at the start of if statements or the start of scripts just to see if they actually run. For example, put a print() statement where the TeleportService command is. That way, you can see if it’s actually being fired.

1 Like

I’ll try that. Thanks for all the help. And sorry for the trouble.

1 Like

Odd…None of the prints fired…But I know the code is working because it’s doing what it’s supposed to up until the teleport.

If prints don’t work, that’s an obvious issue. Some things fire, because conditions are met. I couldn’t help but notice one line…

if minutes == 0 and seconds == 0 then
-- insert your fire statement here
end

Numbers can weird sometimes, so wouldn’t be surprised if it skipped that if statement, but then again that would be weird because the screen does tween to black and says for playing.

All I can think of now is a bandage fix.

Make a GetPropertyChangedSignal() function that fires when the screen is tweened because you’re probably making a GUI visible, so when the enabled (or visible) property is set to true, this local script will fire to the server, once received, the teleport service will attempt to teleport the player, because you’re firing all clients to tween, so this method should work. I know it sucks, but all I can think of now.

I got really nothing else. It’s either a bug, or something in the script is getting ignored.

1 Like

I’ll do some research on GetPropertyChangedSignal() Because I’ve never used it before. I’ll try what you are suggesting soon but right now, I think I just need a break.
I’ll get back to you once I try that.
Thanks for all the help, and sorry for all the trouble.

1 Like

No worries.

GetPropertyChangedSignal() is simply a function that fires when a property changes. It’s basically like Changed() only for every property known on the platform.

Let’s say you change the text of a text label, and you make a GetPropertyChangedSignal() for it, it will fire because the text property was changed.

So for your case, when you enable the GUI, then make the animation tween to a black screen, if you make a GetPropertyChangedSignal() that watches when you enable the GUI, it will start to fire the player when the screen is tweening (which is quite quick as seen in your video) and teleport service has slight delays, so it should work nicely.

Anyways, I should let others peoples thoughts in. The forum clearly doesn’t like me talking a huge lot lol.

1 Like

Hello. Sorry I’ve been busy. So I tried your idea about the GetPropertyChangedSignal() and shocker. It didn’t work. I’m so sorry for all of this.
I don’t think the issue is getting the teleport script to run. I believe it is bc I’ve gotten errors from it before.
I think the real issue is that the Teleport function itself isn’t firing for some reason.
So sorry for all this.

Does it happen to be another place on another account? If so you might have to enable 3rd party teleports.

If not, then try making a new baseplate, and test your script out in the new baseplate and see if the same issue occurs.

Elsewise, I got no clue. Also don’t be sorry, it doesn’t bother me :slight_smile:

1 Like

You’re teleporting the players while they are still loading into the game (i think) try putting it in a problem call function

2 Likes

He’s trying to achieve an “at the end of the game” teleport. One person enters the van, and after a minute occurs everyone in the server gets teleported along with the person who started the teleport process (the driver).

he isn’t immediately teleporting people when they first join, so wrapping this in a pcall wouldn’t do anything as he said he isn’t getting errors when firing.

2 Likes

The game I’m trying to teleport to is a game made by my group. And I’ll try the baseplate thing.
Thanks.
Sorry.

1 Like