public static unsafe void MessageReceived(SystemMessage *msg) { switch (msg->Target) { case SysCallTarget.TmpDebug: if (msg->Arg1 == 1) { var procID = SysCalls.GetProcessByName(GetProcessByNameBuffer, "App.Shell"); if (procID == -1) { procID = SysCalls.GetProcessByName(GetProcessByNameBuffer, "memory"); // temp name } Console.WriteLine("Current ProcID: "); Console.WriteLine(procID.ToString()); if (procID > 0) { SysCalls.KillProcess(procID); } Console.WriteLine("try load proc"); HostCommunicator.StartProcess("os/App.Shell.bin"); Console.WriteLine("Process Started"); MessageManager.Send(new SystemMessage(SysCallTarget.ServiceReturn)); } break; } }