You've been logged out of GDC Vault since the maximum users allowed for this account has been reached. To access Members Only content on GDC Vault, please log out of GDC Vault from the computer which last accessed this account.

Click here to find out about GDC Vault Membership options for more users.

close

Session Name:

Multitasking with Coroutines

Overview:

Tasklets, as a form of cooperative multitasking, are used in EVE Online to drastically simplify program flow in scripts that need to run over multiple frames. Multithreaded programming works well for many things, but sometimes, especially in scripting, cooperative multitasking still has its place. This presentation describes how tasklets are used in EVE, both in the client as well as on the server, showing examples of what tasklets are used for, with Python code samples. The program flow using tasklets is compared to some alternatives, such as using state machines or multiple OS threads. The implementation of tasklets in Stackless Python as used in EVE Online is discussed, as well as some alternatives, such as using regular CPython with greenlets, or Lua using coroutines.

Did you know free users get access to 30% of content from the last 2 years?


Get your team full access to the most up to date GDC content

  • GDC 2014
  • Snorri Sturluson
  • CCP Games
  • free content
  • Programming
  • Programming