Skip to content

Commit

Permalink
Update ecs.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
gastonmorixe authored Oct 24, 2024
1 parent 2f8f27f commit 7df312c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/ecs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,10 @@ export abstract class Component {
}

export abstract class System {
// Optional method. Prepare is called only once before the render loop
prepare?(entities: Entity[]): unknown;

// Render loop. Called om every frame.
// Abstract method, must be implemented by subclasses
abstract update(entities: Entity[]): unknown;
}

0 comments on commit 7df312c

Please sign in to comment.