I'm not familiar with how Pico-8 or Tic-80 work in relation to scripting, but basically if all of the code is stored within a single script file then its viable.
For Unity there are basically two ways you could approach the design. One way would be to create a script that you attach to a range of game objects, with the script having a range of variables that can be toggled on an instance by instance basis. The second way would be to design your script so that it is attached to one game object only, but controls every single functional aspect of the game.