Refactored the launch code + other things, thought about scripting support.