Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Latest commit

 

History

History
History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

README.md

Outline
layout title folder permalink categories tags
pattern
Bytecode
bytecode
/patterns/bytecode/
Behavioral
Game programming

Intent

Allows to encode behaviour as instructions for virtual machine.

Class diagram

alt text

Applicability

Use the Bytecode pattern when you have a lot of behavior you need to define and your game’s implementation language isn’t a good fit because:

  • it’s too low-level, making it tedious or error-prone to program in.
  • iterating on it takes too long due to slow compile times or other tooling issues.
  • it has too much trust. If you want to ensure the behavior being defined can’t break the game, you need to sandbox it from the rest of the codebase.

Credits

Morty Proxy This is a proxified and sanitized view of the page, visit original site.