Editing the Typescript explorer


Is there a way to edit this code? There is a “locked” icon on the side of it. I am fine with using Typescript, but how can I unlock it?

Also, where is the “ask string” code? I can’t find it.

You dit it here:

image

The files that have a locked icon are not editable in the project. This will show up in several difference circumstances - in this case, the file is one of our builtin files, so there’s no way to edit it in the browser – it’s part of the code we change when we update the editor.

In the link you sent, I didn’t edit any of the library code – there was already an exposed hook I added a while back to allow for the sound to be changed. In that case, the winSound was configurable with a function game.setGameOverSound(false, music.powerDown) that would modify the variable – this is similar to how you register an event with sprites.onOverlap to add behavior for when two sprites are on top of eachother.

What about this?

Oh, it’s under prompt.ts in the game package