Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 25 Oct 2016 11:14 AM |
I need someone to basically write a full text of using:
http://wiki.roblox.com/index.php?title=API:Class/TeleportService/ReserveServer
To make players teleport with teleportData (Experts only, low information on the internet) to a new spawnpoint named "StartingInPlace"
How am I going to use teleportData to send information to the reservedserver so it could change its spawnpoint without requiring any localdata information from any player?
Sorry Soybeen, but this task is just too hard for me, I learn by reading other scripts, but there's no script telling me that or any information online that could train me to do it by myself... |
|
|
| Report Abuse |
|
|
|
| 25 Oct 2016 11:15 AM |
Omg you were actually serious
*Sigh*
THE EVENT RECEIVES THE TELEPORT DATA YOU SENT
in caps so u can read english easier |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 25 Oct 2016 11:54 AM |
| WHAT VALUES DOES TELEPORT DATA OUTPUT, I DONT WANT ANY GIBBERISH FROM YOU IF YOU'RE GOING TO KEEP HARRASING MY SMALL LACK OF KNOWLEDGE!!! |
|
|
| Report Abuse |
|
|
|
| 25 Oct 2016 12:22 PM |
Heya, I'm sorry that you feel you've been harassed, I have never scripted this personally but I need to work on it so I'll give it a shot and see if I can help you out!
"Everybody has a chapter they don't read aloud." |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|
|
| 25 Oct 2016 01:23 PM |
| teleport data is what ever you send as teleport data in the teleport method you noob |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 25 Oct 2016 02:11 PM |
| Boosted Animal what could I send with it, dataValues? And now what? I know right now that I can send stuff with the teleportData, but what can i send, tell me in general? Can i send like "_G.Tacos = true" or what? That'd be useful, or can I send game.Workspace.Spawn_Point_B.Enabled = true? |
|
|
| Report Abuse |
|
|
Xonae
|
  |
| Joined: 04 Dec 2013 |
| Total Posts: 336 |
|
|
| 25 Oct 2016 02:18 PM |
teleportData can be booleans, tables, etc. but not code.
"Motivation is something to be found, but not searched for." |
|
|
| Report Abuse |
|
|
|
| 25 Oct 2016 02:31 PM |
| Send the code as a string and then just do pcall(loadstring(string_passed)) |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 25 Oct 2016 02:38 PM |
| So am I able to replace teleportData with :TeleportToPrivateServer(placeid, etc, etc, etc, _G.Tacos = true) |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 26 Oct 2016 09:46 AM |
@OP
Wiki clearly gives you a perfect example:
http://wiki.roblox.com/index.php?title=API:Class/TeleportService/ReserveServer
|
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 26 Oct 2016 02:32 PM |
| Of using ReservedServer yes, but not for teleporting players to a new spawn, I alredy sent a ticket to roblox support cause I don't find the answer I were looking for, Soybeen were the only one who got me almost at right track, creds goes to him ;) |
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 26 Oct 2016 03:04 PM |
'but not for teleporting players to a new spawn'
I showed you like 100 times how to teleport to a different spawn.
http://wiki.roblox.com/index.php?title=API:Class/TeleportService/TeleportToSpawnByName
|
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 26 Oct 2016 03:44 PM |
| TeleportToSpawnByName doesn't go together with TeleportToPrivateServer, I cannot forward the code to the other server. |
|
|
| Report Abuse |
|
|
TimeTicks
|
  |
| Joined: 27 Apr 2011 |
| Total Posts: 27115 |
|
|
| 26 Oct 2016 04:04 PM |
ffs
http://wiki.roblox.com/index.php?title=API:Class/TeleportService/TeleportToPrivateServer
string spawnName
string spawnName
string spawnName
string spawnName
string spawnName
string spawnName
|
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 27 Oct 2016 12:35 PM |
HAIL LORD TICKEMAN YOU SAVE MY DORITOS! WAOOOOW
*Gofven.exe stopped working* |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 27 Oct 2016 12:37 PM |
| Also the issue was that you were needed to have the spawnpoint enabled, but then there'll be 50/50 players spawn in that place, so I made it a little diffrent and changed the spawnpoints team-color, now it works perfectly :D |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 27 Oct 2016 12:51 PM |
Nevermind it was pure luck that it did go that great... Here's the code again ;-;
while wait(1) do if _G.Tc1StartedGame == true then local TS = game:GetService("TeleportService") local Players = game:GetService("Players") local spawnName = "StartingInPlace"
local code = TS:ReserveServer(game.PlaceId) -- Returns a code local players = Players:GetPlayers() -- Get a list of all players
TS:TeleportToPrivateServer(game.PlaceId,code,players,spawnName) -- Actually teleport the players
end end |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|
Cheater
|
  |
| Joined: 29 Jun 2007 |
| Total Posts: 5258 |
|
|
| 28 Oct 2016 01:48 AM |
So... I have to admit I have not yet worked with this feature yet but I looked into it a little bit. Now to me this script seems all fine but where's the receiver script? I looked around and thought you'd be using this as a receiver:
http://wiki.roblox.com/index.php?title=API:Class/TeleportService/LocalPlayerArrivedFromTeleport
Is that correct and if so, can we see the script there? Because that's pretty much where you want to set how and where the player spawns, depending on the attributes you sent right?
That "teleportData" is basically what you sent with your spawn thingy, so you can build in the spawning there if I'm not mistaken. |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
|
| 28 Oct 2016 07:18 AM |
Apparently it doesn't work... I am actually not 100% sure what I should do in this script to make it work, I know it could be the solution but I am not sure how i'm supposed to use the teleportdata, it's in my hand but I dont know how get the spawnName out of it.
game:GetService('TeleportService').LocalPlayerArrivedFromTeleport:connect(function(customLoadingScreen, teleportData) for key, value in pairs(teleportData) do print(key.. " = " ..value) end game.Workspace.TcCoreSpawn.Enabled = false game.Workspace.StartingInPlace.Enabled = true end) |
|
|
| Report Abuse |
|
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|
Gofven
|
  |
| Joined: 18 Jun 2015 |
| Total Posts: 767 |
|
| |
|