Hi! I am currently in the process of making a Tower Defense Game. In the future, we will have multiple maps so that a player can experience each and every one!
– Problem
The problem? I have to copy and paste all the game scripts from one map to another. Now, this only one part of the problem. The second part is that if I want to update the scripts, I’ll have to go through all the maps and update them. What I want to do is update the game scripts inside the lobby game and when a player gets teleported to a map, the game sends all the scripts along with them and puts themselves into the appropriate places (ServerScriptStorage, ReplicatedStorage, etc). I could get the arriving teleporting data but this can only be used in a LocalScript. If I move the scripts using a LocalScript, it wouldn’t happen for everyone else and LocalScripts can’t even access ServerScriptStorage/ServerStorage.
– Any Solutions?
Is there a way to send objects/data between each game that doesn’t use the Teleport Service? (if you can only do so using Teleport Service, is there a way to make it so that the data doesn’t arrive in a LocalScript?) I have tried looking up a specific type of code for this. However, I was unsuccessful.
You can require the asset id of an object? I never knew you could do this. This could actually be the solution. Is there a link you can send so I can further look into to this. Or just explain it to me?
Sounds like you could use packages. I use them for all my games that have multiple places. Although they don’t publish the places automatically when changes are made, they make keeping data consistent throughout different places much easier.
I’ll look into this as well. I think I’ll have to select 1 player to get the data from since I don’t want to get the game scripts from every single player.
Even though “Player:GetJoinData” is a great way to send data between servers, I think I like the idea of “Packages” better. Thank you everyone for helping me! Have a great day.