To add your own app:

  1. Make sure that its in 1s1s1c mode(one sprite,one script consisting of a init and a loop and does not use sprite properties to store data,one costume).Most of my game projects obey this rule.(the moon landing and the gravity sim projects)
  2. Import the script into the os project.
  3. Manually replace some functions that need the os archtechure to work to their os counterparts(you now have file blocks,task list manipulation,etc)
  4. Put it into the stuff to compile block.
  5. Hit the script in the compiler sprite.(make sure that there is no "compiled script" block or its space would be occupied)
  6. Edit the custom block "compiled script" so that:
  • delete the "let block=this script"
  • put all the script variable definitions before the report(i.e all the "script variables" blocks should go to a place where their scope is the block "compiled script")
  • rename the block
  1. Try to let something invoke it.(either by putting the block "add (your script) to (tasks)" into another thread,or by putting it into the list of tasks in the sprite sprite and ignore(call((item (something) of tasks) with inputs start)) (no replacing it with run))

I haven't added the kernel script yet,so you will have to do the script invoking manually.
I have put my moon landing game into the project,for a demo of how you should add apps.

Side note:The compiler does not support focus detecting.If you want to detect if the user is opening this window,add the script variable focus beside pen trails,and add the script set focus to true to the if render branch,and set focus to false to the end of the loop branch just behind the report.

The default moon landing game isn't modified like this,so it is not thread safe.(fixed)

Fun fact: The file blocks are from Jounce OS,and I forgot to clean the insides of the files list.
Will clean it.

Side note:Because of the extra layer of abstraction,the rate of calls to the main loop of apps would be slower than when it was its own project.I learned this the hard way when trying to play moon landing game.

Made a file explorer
You should not delete executables because you cannot make them outside the snap editor.You can delete or move them inside the snap editor.
You cannot cut and paste files.You must copy and paste their contents.

do multiple programs run at the same time or no? how do i close a program?

the project looks interesting and it looks like it's progressing well

Yes,but I made the two default programs thread safe so you cannot crash the lander while browsing folders

Programs that don't want to close them selves are malware.
In windows,most programs listen to the red X button event and close
If you are asking for doing it programmatically,stop(all) in the script before compiling,more specifically if the compiled program reports anything not False it will be closed

Press ctrl-shift-Shift(dk why snap does that,its just lctrl+lshift) to switch windows(and malware cannot stop you from that hooray)

you mean that it doesn't run unless it's focused? that's good but that's not what "thread safe" means

are you considering adding an antivirus at some point? it sounds like a lot of programs are malware.
dealing with closing can't be done though (at least not without some kind of force close), that would require solving the halting problem.

maybe i'll make antiviruses for various oses that can load programs at some point. i've lost track of which ones can load programs though.

it means that programs do not mangle other programs memory

for the moon lander yes
for the explorer it runs in background and always runs and never closes(quite reasonable for a system software,dont call it malware) it just stops reacting to mouse input

that would require solving the finite bounded halting problem

report length of keep items<i=report> of split(block)
it wont work for trolls that stuff 1000000 stop falses in their programs tho

it has to do with a lot more than memory, and
considering snap isn't actually using multiple threads, and doesn't really have anything like it, i feel like "thread safe" is just a confusing term to use and that something else should be used. maybe "safe multitasking"?

not malware, but it doesn't do anything if it's not focused, right? it seems like a small performance issue, you should probably disable it for that. it could be part of what's slowing down the moon landing game.

still extremely impractical (unless you can find a smart way to do it) :)

yeah its exponential time

i cant disable its loop being launched,and just stopping the code from working wont do anything