Disable Dev Console Commandbar for CreatePlaceInPlayerInventoryAsync()

Currently, if player A has a game that creates a game in player B’s inventory, some annoying facts happen:

  • Player B can edit the place, and see all the scripts (but not save, luckily)
  • Player B can use the Commandbar in the Dev Console to script online

While the first thing is more an advantage, the second isn’t.
That they can edit the place, is just an easy of letting them “export” their creations in such a place to their studio.
They can’t steal the scripts if you use require(assetid) to load all the code and all the stuff you need.
But, due the commandbar, they can totally ruin the game:

  • Delete all scripts and save the place
  • Add their own scripts and save the place
  • Do anything else they want to do

It would be nice if they don’t have access to the commandbar in places in an universe they don’t own.
(That the real owner of the universe has access to it or not, that’s another story that has nothing to do with this)

You’re not supposed to create a place in someone else’s inventory if you don’t want them to own the place…

If they break the game, then it’s their own fault. If they still want to play, make something like a ‘Regenerate Game’ button/similar in your main place which recreates the place. Don’t forget to warn them that everything they have will be lost.

But I don’t want them to even break the game, or worse, save it with all scripts in it.
(Localscripts that is, all serverside code is protected due the use of ModuleScripts)

Then you should use CreatePlace. CreatePlaceInPlayerInventory is for if you want the player to own a copy of the game. You’re doing something wrong here.

But if I use CreatePlaceInPlayerInventoryAsync, I have some advantages:

  • My inventory isn’t full of random places
  • They have the feeling they “own” it
  • They can “export” their stuff to studio using the Edit-button