-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Thang Component System
CodeCombat uses something like an Entity-Component-System architecture (read more), which is different from an old-school object-oriented game engine. The gist is that Entities are just pointers, and you compose them out of a bunch of Components which encapsulate data, and those are organized by Systems which add behavior and make the world tick.
But instead of "Entities", we call them "Thangs", since ain't no one got time for such a long, boring, irregularly pluralizable words as "Entitity". I mean, "Entity." (See?) So it's a Thang-Component-System architecture instead.
Thangs live inside Levels, where they are configured with Components, and the levels are similarly configured with Systems. In addition to Components, Thangs point to ThangTypes, which hold all the art and sound information needed to display them--but ThangTypes have no impact on the Level's World simulation itself. You can make all the Ogres look like trees and they'll still crush the human soldiers--it'll just look hilarious when you go to play the level. For details, check the full article on Thangs.
The other big difference is that our Components include behavior. Lots of behavior. In fact, most of them are mostly behavior. Components copy their properties to their Thangs when attached, and some of these properties are methods. The Components all live in the database, so you can code them right from within the Level Editor--how cool is that? For details, check the full article on Components.
Systems are unto Levels as Components are unto Thangs--also containing configuration data and methods, also live-editable from within the Level Editor. See the full article on Systems.
CodeCombat | Home | Blog | Forum | Teachers | Legal | Contribute
- Home
- Archmage Home
- Artisan Home
- Diplomat Home
- Archmage General
- Mission statement
- Coco Models
- Coding Guidelines
- Cookbook
- File system
- JSON Schema
- Technical overview
- Testing
- Third party software and services
- Artisan General
- Building A Level
- Coding Guidelines for Artisans
- Editing Thang Components
- Important Artisan Concepts
- Keyboard Shortcuts
- Debugging
- Artisan How-To Index
- Diplomat General
- i18n
- i18n Glossary nb
- i18n Glossary ru
- i18n Glossary es-419
- Dev Setup
- Dev Setup: Linux
- Dev Setup: Windows
- Dev Setup: Mac
- Dev Setup: Vagrant
- Dev Setup: Issues
- Game Engine
- Component
- Multiplayer
- Surface
- System
- Thang
- Thang Component System
- Tome
- World
- Artisan Tabs
- Components And Systems
- Scripts
- Settings
- Thangs
- Other
- Aether
- Client models
- Developer organization
- Educational Standards
- Events, subscriptions, shortcuts
- Chat Room
- Chat Room Rules
- Permissions
- Project Ideas List
- Treema
- Versioning
- Views