The gamebox-ecs Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The gamebox-ecs Reference Manual

This is the gamebox-ecs Reference Manual, version 1.0.0, generated automatically by Declt version 2.3 "Robert April" on Wed Mar 14 03:55:17 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

gamebox-ecs

An implementation of the Entity-Component System (ECS) pattern, popular with game development.

Overview

This is an ECS implementation for game development that is designed to be simple and flexible.

Install

(ql:quickload :gamebox-ecs)

Usage

First, initialize the ECS system:

(init-ecs)

You can optionally specify a logging message level of :DEBUG to see more messages (the default is :INFO):

(init-ecs :log-level :debug)

Define some traits:

(deftrait test-trait-1 (x y z))
(deftrait test-trait-2 (x y z))

Define a behavior that is called for all GOBs that match.

:MODE is R, so it will be processed before any R/W behaviors, and R/W will be processed before any W behaviors.

:INTERVAL is 2, so it will be called every two game ticks.

:FILTERS specifies the constraints for a GOB to be considered to have this behavior.

:GROUPING a list of symbols specifying how many GOBs to include in parallel, and unique names for them to be accessed. Every combination of this many GOBs will be iterated over.

(defbehavior move ; the name of the behavior
    (:mode r ; R before R/W before W. This ensures proper order of mutable behaviors
     :interval 2 ; will be called only once every 2 game ticks
     :filters ((all groups test-group-1 test-group-2) ; must be a member of all of these groups
               (any traits test-trait-1 test-trait-2) ; must have at least one of these traits
               (none traits not-this-trait)) ; must not have this trait
     :grouping (e1 e2)) ; gobs will be combined in pairs so they can be compared in parallel
  (format t "~A~%" (list e1 e2))) ; the body goes here - we just print a list of each grouping.

Define some GOBs (Game Objects):

(make-gob player (test-group-1 test-group-2)
  (test-trait-1 :x 1 :y 2 :z 3))

(make-gob enemy (test-group-1 test-group-2)
  (test-trait-2 :x 1 :y 2 :z 3))

(make-gob not-in-system (test-group-1)
  (test-trait-1 :x 1 :y 2 :z 3))

Cycle the behaviors. This should be called in your main loop:

(cycle-behaviors) ; The above behavior is called once every 2 ticks, so this will have no effect.
(cycle-behaviors) ; This will affect some GOBs, since it is the second tick. It will print: (2 1)

License

Copyright © 2016-2018 Michael Fiano.

Licensed under the MIT License.


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 gamebox-ecs

Maintainer

Michael Fiano <mail@michaelfiano.com>

Author

Michael Fiano <mail@michaelfiano.com>

Home Page

https://www.michaelfiano.com/projects/gamebox-ecs

Source Control

(:git "git@github.com:mfiano/gamebox-ecs.git")

Bug Tracker

https://github.com/mfiano/gamebox-ecs/issues

License

MIT

Description

An implementation of the Entity-Component System (ECS) pattern, popular with game development.

Long Description

# gamebox-ecs

An implementation of the Entity-Component System (ECS) pattern, popular with game development.

## Overview

This is an ECS implementation for game development that is designed to be simple and flexible.

## Install

“‘ lisp
(ql:quickload :gamebox-ecs)
“‘

## Usage

First, initialize the ECS system:

“‘ lisp
(init-ecs)
“‘

You can optionally specify a logging message level of ‘:DEBUG‘ to see more messages (the default is ‘:INFO‘):

“‘ lisp
(init-ecs :log-level :debug)
“‘

Define some traits:

“‘ lisp
(deftrait test-trait-1 (x y z))
(deftrait test-trait-2 (x y z))
“‘

Define a behavior that is called for all GOBs that match.

‘:MODE‘ is ‘R‘, so it will be processed before any ‘R/W‘ behaviors, and ‘R/W‘ will be processed before any ‘W‘ behaviors.

‘:INTERVAL‘ is 2, so it will be called every two game ticks.

‘:FILTERS‘ specifies the constraints for a GOB to be considered to have this behavior.

‘:GROUPING‘ a list of symbols specifying how many GOBs to include in parallel, and unique names for them to be accessed. Every combination of this many GOBs will be iterated over.

“‘ lisp
(defbehavior move ; the name of the behavior
(:mode r ; R before R/W before W. This ensures proper order of mutable behaviors
:interval 2 ; will be called only once every 2 game ticks
:filters ((all groups test-group-1 test-group-2) ; must be a member of all of these groups (any traits test-trait-1 test-trait-2) ; must have at least one of these traits (none traits not-this-trait)) ; must not have this trait
:grouping (e1 e2)) ; gobs will be combined in pairs so they can be compared in parallel (format t "~A~%" (list e1 e2))) ; the body goes here - we just print a list of each grouping. “‘

Define some GOBs (Game Objects):

“‘ lisp
(make-gob player (test-group-1 test-group-2)
(test-trait-1 :x 1 :y 2 :z 3))

(make-gob enemy (test-group-1 test-group-2)
(test-trait-2 :x 1 :y 2 :z 3))

(make-gob not-in-system (test-group-1)
(test-trait-1 :x 1 :y 2 :z 3))
“‘

Cycle the behaviors. This should be called in your main loop:

“‘ lisp
(cycle-behaviors) ; The above behavior is called once every 2 ticks, so this will have no effect. (cycle-behaviors) ; This will affect some GOBs, since it is the second tick. It will print: (2 1) “‘

## License

Copyright © 2016-2018 [Michael Fiano](mailto:mail@michaelfiano.com).

Licensed under the MIT License.

Version

1.0.0

Dependencies
Source

gamebox-ecs.asd (file)

Components

Next: , Previous: , Up: Top   [Contents][Index]

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.1 gamebox-ecs.asd

Location

/home/quickbuilder/quicklisp/dists/quicklisp/software/gamebox-ecs-20180228-git/gamebox-ecs.asd

Systems

gamebox-ecs (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.2 gamebox-ecs/package.lisp

Parent

gamebox-ecs (system)

Location

package.lisp

Packages

box.ecs


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.3 gamebox-ecs/util.lisp

Dependency

package.lisp (file)

Parent

gamebox-ecs (system)

Location

util.lisp

Exported Definitions
Internal Definitions

filter (function)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.4 gamebox-ecs/ecs.lisp

Dependency

util.lisp (file)

Parent

gamebox-ecs (system)

Location

ecs.lisp

Exported Definitions

init-ecs (function)

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.5 gamebox-ecs/gob.lisp

Dependency

ecs.lisp (file)

Parent

gamebox-ecs (system)

Location

gob.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.6 gamebox-ecs/group.lisp

Dependency

gob.lisp (file)

Parent

gamebox-ecs (system)

Location

group.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.7 gamebox-ecs/tag.lisp

Dependency

group.lisp (file)

Parent

gamebox-ecs (system)

Location

tag.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.8 gamebox-ecs/attr.lisp

Dependency

tag.lisp (file)

Parent

gamebox-ecs (system)

Location

attr.lisp

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.9 gamebox-ecs/trait.lisp

Dependency

attr.lisp (file)

Parent

gamebox-ecs (system)

Location

trait.lisp

Exported Definitions
Internal Definitions

Previous: , Up: Lisp files   [Contents][Index]

3.1.10 gamebox-ecs/behavior.lisp

Dependency

trait.lisp (file)

Parent

gamebox-ecs (system)

Location

behavior.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

4 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

4.1 box.ecs

Source

package.lisp (file)

Use List

common-lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Exported definitions


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.1 Macros

Macro: defbehavior NAME (&key MODE INTERVAL FILTERS GROUPING) &body BODY

Define a new behavior.

Package

box.ecs

Source

behavior.lisp (file)

Macro: deftrait NAME &body ATTRS

Define a new trait.

Package

box.ecs

Source

trait.lisp (file)

Macro: make-gob TAG (&rest GROUPS) &body TRAITS

Make a new GOB.

Package

box.ecs

Source

gob.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.2 Functions

Function: all LIST1 LIST2

Check if all elements of LIST1 are in LIST2.

Package

box.ecs

Source

util.lisp (file)

Function: any LIST1 LIST2

Check if any element of LIST1 is in LIST2.

Package

box.ecs

Source

util.lisp (file)

Function: cycle-behaviors ()

Process all behaviors once.

Package

box.ecs

Source

behavior.lisp (file)

Function: get-tag GOB-ID

Get the tag of a GOB.

Package

box.ecs

Source

tag.lisp (file)

Function: gob ID

Get a GOB by its ID.

Package

box.ecs

Source

gob.lisp (file)

Writer

(setf gob) (function)

Function: (setf gob) GOB GOB-ID

Set the specified ID to a new GOB.

Package

box.ecs

Source

gob.lisp (file)

Reader

gob (function)

Function: gob-by-tag TAG

Get the owner with the specified tag.

Package

box.ecs

Source

tag.lisp (file)

Function: gobs-by-group GROUP

Get a list of GOBs in a group.

Package

box.ecs

Source

group.lisp (file)

Function: group-join GOB-ID GROUP

Add a GOB to a group. The ON-GROUP-JOIN event will be triggered in order to provide custom functionality depending on the group the was joined.

Package

box.ecs

Source

group.lisp (file)

Function: group-leave GOB-ID GROUP

Remove a GOB from a group. The ON-GROUP-LEAVE event will be triggered in order to provide custom functionality depending on the group that was left.

Package

box.ecs

Source

group.lisp (file)

Function: groups GOB-ID

Get a list of all groups a GOB is a member of.

Package

box.ecs

Source

group.lisp (file)

Function: has-trait-p GOB-ID TRAIT

Check if a GOB has a trait.

Package

box.ecs

Source

trait.lisp (file)

Function: init-ecs &key LOG-LEVEL

Initialize the Ecstasy system, optionally setting the logging level for printing messages.

Package

box.ecs

Source

ecs.lisp (file)

Function: none LIST1 LIST2

Check if no element of LIST1 is in LIST2.

Package

box.ecs

Source

util.lisp (file)

Function: process-behavior BEHAVIOR

Execute the specified behavior. The behavior definition’s grouping determines parallel processing of GOBs.

Package

box.ecs

Source

behavior.lisp (file)

Function: remove-gob GOB-ID

Remove a GOB.

Package

box.ecs

Source

gob.lisp (file)

Function: tag-add GOB-ID TAG

Add a tag to a GOB. If the specified GOB already has a different tag, it will be lost. If another GOB already has this tag, it will be lost. The ON-TAG-ADDED event will be triggered in order to provide custom functionality depending on the tag added.

Package

box.ecs

Source

tag.lisp (file)

Function: tag-remove GOB-ID

Remove a tag from a GOB. The ON-TAG-REMOVED event will be triggered in order to provide custom functionality depending on the tag removed.

Package

box.ecs

Source

tag.lisp (file)

Function: trait-add GOB-ID TRAIT-ID ATTRS

Add a new trait to a GOB.

Package

box.ecs

Source

trait.lisp (file)

Function: trait-remove GOB-ID TRAIT

Remove a trait from a GOB.

Package

box.ecs

Source

trait.lisp (file)

Function: traits GOB-ID

Get a list of all traits of a GOB.

Package

box.ecs

Source

trait.lisp (file)

Writer

(setf traits) (function)

Function: (setf traits) TRAITS GOB-ID

Assign a list of traits to a GOB.

Package

box.ecs

Source

trait.lisp (file)

Reader

traits (function)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

5.1.3 Generic functions

Generic Function: on-behavior-start BEHAVIOR GOBS

Event triggered when a behavior starts.

Package

box.ecs

Source

behavior.lisp (file)

Methods
Method: on-behavior-start BEHAVIOR GOBS
Method: on-behavior-start BEHAVIOR GOBS around
Generic Function: on-behavior-stop BEHAVIOR GOBS

Event triggered when a behavior stops.

Package

box.ecs

Source

behavior.lisp (file)

Methods
Method: on-behavior-stop BEHAVIOR GOBS
Method: on-behavior-stop BEHAVIOR GOBS around
Generic Function: on-gob-created GOB-ID

Event triggered when a GOB is created.

Package

box.ecs

Source

gob.lisp (file)

Methods
Method: on-gob-created GOB-ID
Method: on-gob-created GOB-ID around
Generic Function: on-gob-deleted GOB-ID

Event triggered when a GOB is deleted.

Package

box.ecs

Source

gob.lisp (file)

Methods
Method: on-gob-deleted GOB-ID
Method: on-gob-deleted GOB-ID around
Generic Function: on-group-join GOB-ID GROUP

Event triggered when a GOB joins a group.

Package

box.ecs

Source

group.lisp (file)

Methods
Method: on-group-join GOB-ID GROUP
Method: on-group-join GOB-ID GROUP around
Generic Function: on-group-leave GOB-ID GROUP

Event triggered when a GOB leaves a group.

Package

box.ecs

Source

group.lisp (file)

Methods
Method: on-group-leave GOB-ID GROUP
Method: on-group-leave GOB-ID GROUP around
Generic Function: on-tag-added GOB-ID TAG

Event called when a GOB is tagged.

Package

box.ecs

Source

tag.lisp (file)

Methods
Method: on-tag-added GOB-ID TAG
Method: on-tag-added GOB-ID TAG around
Generic Function: on-tag-removed GOB-ID TAG

Event called when a GOB is untagged.

Package

box.ecs

Source

tag.lisp (file)

Methods
Method: on-tag-removed GOB-ID TAG
Method: on-tag-removed GOB-ID TAG around
Generic Function: on-trait-added GOB-ID TRAIT

Event triggered when a trait is added to a GOB.

Package

box.ecs

Source

trait.lisp (file)

Methods
Method: on-trait-added GOB-ID TRAIT
Method: on-trait-added GOB-ID TRAIT around
Generic Function: on-trait-removed GOB-ID TRAIT

Event triggered when a trait is removed from a GOB.

Package

box.ecs

Source

trait.lisp (file)

Methods
Method: on-trait-removed GOB-ID TRAIT
Method: on-trait-removed GOB-ID TRAIT around

Previous: , Up: Exported definitions   [Contents][Index]

5.1.4 Classes

Class: gob ()

An object representing a game object/entity.

Package

box.ecs

Source

gob.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: %tag
Readers

%gob-tag (generic function)

Writers

(setf %gob-tag) (generic function)

Slot: %groups
Readers

%gob-groups (generic function)

Writers

(setf %gob-groups) (generic function)

Slot: %traits
Readers

%gob-traits (generic function)

Writers

(setf %gob-traits) (generic function)

Slot: %attrs
Readers

%gob-attrs (generic function)

Writers

(setf %gob-attrs) (generic function)


Previous: , Up: Definitions   [Contents][Index]

5.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.1 Special variables

Special Variable: *ecs*
Package

box.ecs

Source

ecs.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.2 Functions

Function: %group-members GROUP

Get a list of GOBs in a group.

Package

box.ecs

Source

group.lisp (file)

Writer

(setf %group-members) (function)

Function: (setf %group-members) MEMBERS GROUP

Assign a list of GOBS to a group.

Package

box.ecs

Source

group.lisp (file)

Reader

%group-members (function)

Function: %make-gob &key TAG GROUPS TRAITS

Create a new GOB, optionally assigning a unique tag or a list of groups.

Package

box.ecs

Source

gob.lisp (file)

Function: %tag-owner TAG

Get the GOB with the specified tag.

Package

box.ecs

Source

tag.lisp (file)

Writer

(setf %tag-owner) (function)

Function: (setf %tag-owner) GOB-ID TAG

Assign a tag to a GOB.

Package

box.ecs

Source

tag.lisp (file)

Reader

%tag-owner (function)

Function: %traits-reformat TRAITS

Helper function to reformat trait data given to %MAKE-GOB.

Package

box.ecs

Source

trait.lisp (file)

Function: attr GOB-ID ATTR

Get the value of one of a GOB’s attributes.

Package

box.ecs

Source

attr.lisp (file)

Writer

(setf attr) (function)

Function: (setf attr) VALUE GOB-ID ATTR

Set the value of one of a GOB’s attributes.

Package

box.ecs

Source

attr.lisp (file)

Reader

attr (function)

Function: attr-remove GOB-ID ATTR

Remove one of a GOB’s attributes.

Package

box.ecs

Source

attr.lisp (file)

Function: attrs GOB-ID

Get a list of all of a GOB’s attributes.

Package

box.ecs

Source

attr.lisp (file)

Writer

(setf attrs) (function)

Function: (setf attrs) ATTRS GOB-ID

Assign a list of attributes to a GOB.

Package

box.ecs

Source

attr.lisp (file)

Reader

attrs (function)

Function: behavior-by-name BEHAVIOR

Get a behavior by name.

Package

box.ecs

Source

behavior.lisp (file)

Function: behavior-list ()

Get a list of all defined behaviors.

Package

box.ecs

Source

behavior.lisp (file)

Function: cache-gobs ()

Update the the list of GOBs for all behaviors.

Package

box.ecs

Source

behavior.lisp (file)

Function: collect-gobs BEHAVIOR

Get a list of all GOBs that fall through the specified behavior’s filters.

Package

box.ecs

Source

behavior.lisp (file)

Function: filter GOB-ID FILTER-FN GOB-FN ITEMS

Filter a GOB.

Package

box.ecs

Source

util.lisp (file)

Function: gob-list ()

Get a list of all active GOBs.

Package

box.ecs

Source

gob.lisp (file)

Function: group-delete GROUP

Delete a group. Current members of the deleted group will continue to exist, but will lose their membership. The ON-GROUP-LEAVE event will be triggered for each group that was left.

Package

box.ecs

Source

group.lisp (file)

Function: group-leave-all GOB-ID

Remove a GOB from all groups. The ON-GROUP-LEAVE event will be triggered for each group that was left.

Package

box.ecs

Source

group.lisp (file)

Function: group-list ()

Get a list of all active groups. An active group has at least one member.

Package

box.ecs

Source

group.lisp (file)

Function: group-member-p GOB-ID GROUP

Check if a GOB is a member of a specific group.

Package

box.ecs

Source

group.lisp (file)

Function: grouped-p GOB-ID

Check if a GOB is a member of any group.

Package

box.ecs

Source

group.lisp (file)

Function: groupp GROUP

Check if a group is active.

Package

box.ecs

Source

group.lisp (file)

Function: has-tag-p GOB-ID TAG

Check if a GOB has a specific tag.

Package

box.ecs

Source

tag.lisp (file)

Function: make-gob-id ()

Make a new GOB ID. This will reclaim any IDs from any GOBs that were removed.

Package

box.ecs

Source

ecs.lisp (file)

Function: sort-behaviors ()

Sort all behaviors in the order they should be processed.

Package

box.ecs

Source

behavior.lisp (file)

Function: tag-delete TAG

Delete a tag. A GOB that has this tag assigned will continue to exist, but will lose its tag. The ON-TAG-REMOVED event will be triggered for the deleted tag.

Package

box.ecs

Source

tag.lisp (file)

Function: tag-list ()

Get a list of all active tags. An active tag is a tag currently assigned to a GOB.

Package

box.ecs

Source

tag.lisp (file)

Function: tagged-p GOB-ID

Check if a GOB has any tag.

Package

box.ecs

Source

tag.lisp (file)

Function: tagp TAG

Check if a tag is active.

Package

box.ecs

Source

tag.lisp (file)

Function: trait-attr-add TRAIT ATTR

Add a new attribute to a trait.

Package

box.ecs

Source

trait.lisp (file)

Function: trait-attrs TRAIT

Get a list of attributes for a trait.

Package

box.ecs

Source

trait.lisp (file)

Writer

(setf trait-attrs) (function)

Function: (setf trait-attrs) ATTRS TRAIT

Assign a list of attributes to a trait.

Package

box.ecs

Source

trait.lisp (file)

Reader

trait-attrs (function)

Function: trait-list ()

Get a list of all defined traits.

Package

box.ecs

Source

trait.lisp (file)

Function: traitp TRAIT

Check if a trait is defined.

Package

box.ecs

Source

trait.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.3 Generic functions

Generic Function: %defaults OBJECT
Package

box.ecs

Methods
Method: %defaults (TRAIT trait)

automatically generated reader method

Source

trait.lisp (file)

Generic Function: %gob-attrs OBJECT
Generic Function: (setf %gob-attrs) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %gob-attrs (GOB gob)

automatically generated reader method

Source

gob.lisp (file)

Method: (setf %gob-attrs) NEW-VALUE (GOB gob)

automatically generated writer method

Source

gob.lisp (file)

Generic Function: %gob-groups OBJECT
Generic Function: (setf %gob-groups) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %gob-groups (GOB gob)

automatically generated reader method

Source

gob.lisp (file)

Method: (setf %gob-groups) NEW-VALUE (GOB gob)

automatically generated writer method

Source

gob.lisp (file)

Generic Function: %gob-tag OBJECT
Generic Function: (setf %gob-tag) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %gob-tag (GOB gob)

automatically generated reader method

Source

gob.lisp (file)

Method: (setf %gob-tag) NEW-VALUE (GOB gob)

automatically generated writer method

Source

gob.lisp (file)

Generic Function: %gob-traits OBJECT
Generic Function: (setf %gob-traits) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %gob-traits (GOB gob)

automatically generated reader method

Source

gob.lisp (file)

Method: (setf %gob-traits) NEW-VALUE (GOB gob)

automatically generated writer method

Source

gob.lisp (file)

Generic Function: %groups OBJECT
Package

box.ecs

Methods
Method: %groups (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Generic Function: %process-gobs BEHAVIOR &rest GOBS
Package

box.ecs

Source

behavior.lisp (file)

Generic Function: %tags OBJECT
Package

box.ecs

Methods
Method: %tags (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Generic Function: %trait-attrs OBJECT
Generic Function: (setf %trait-attrs) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %trait-attrs (TRAIT trait)

automatically generated reader method

Source

trait.lisp (file)

Method: (setf %trait-attrs) NEW-VALUE (TRAIT trait)

automatically generated writer method

Source

trait.lisp (file)

Generic Function: %traits OBJECT
Generic Function: (setf %traits) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: %traits (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf %traits) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: behavior OBJECT
Generic Function: (setf behavior) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: behavior (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf behavior) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: behavior-order OBJECT
Generic Function: (setf behavior-order) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: behavior-order (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf behavior-order) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: current-id OBJECT
Generic Function: (setf current-id) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: current-id (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf current-id) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: filters OBJECT
Package

box.ecs

Methods
Method: filters (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Generic Function: gobs OBJECT
Generic Function: (setf gobs) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: gobs (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Method: (setf gobs) NEW-VALUE (BEHAVIOR behavior)

automatically generated writer method

Source

behavior.lisp (file)

Generic Function: gobs-active OBJECT
Generic Function: (setf gobs-active) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: gobs-active (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf gobs-active) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: gobs-inactive OBJECT
Generic Function: (setf gobs-inactive) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: gobs-inactive (ECS ecs)

automatically generated reader method

Source

ecs.lisp (file)

Method: (setf gobs-inactive) NEW-VALUE (ECS ecs)

automatically generated writer method

Source

ecs.lisp (file)

Generic Function: grouping OBJECT
Generic Function: (setf grouping) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: grouping (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Method: (setf grouping) NEW-VALUE (BEHAVIOR behavior)

automatically generated writer method

Source

behavior.lisp (file)

Generic Function: id OBJECT
Package

box.ecs

Methods
Method: id (TRAIT trait)

automatically generated reader method

Source

trait.lisp (file)

Generic Function: interval OBJECT
Package

box.ecs

Methods
Method: interval (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Generic Function: mode OBJECT
Package

box.ecs

Methods
Method: mode (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Generic Function: on-group-deleted GROUP

Event triggered when a group is deleted.

Package

box.ecs

Source

group.lisp (file)

Methods
Method: on-group-deleted GROUP
Method: on-group-deleted GROUP around
Generic Function: ticks OBJECT
Generic Function: (setf ticks) NEW-VALUE OBJECT
Package

box.ecs

Methods
Method: ticks (BEHAVIOR behavior)

automatically generated reader method

Source

behavior.lisp (file)

Method: (setf ticks) NEW-VALUE (BEHAVIOR behavior)

automatically generated writer method

Source

behavior.lisp (file)


Previous: , Up: Internal definitions   [Contents][Index]

5.2.4 Classes

Class: behavior ()
Package

box.ecs

Source

behavior.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: %mode
Initargs

:mode

Readers

mode (generic function)

Slot: %interval
Initargs

:interval

Readers

interval (generic function)

Slot: %ticks
Initform

0

Readers

ticks (generic function)

Writers

(setf ticks) (generic function)

Slot: %filters
Initargs

:filters

Readers

filters (generic function)

Slot: %grouping
Initargs

:grouping

Readers

grouping (generic function)

Writers

(setf grouping) (generic function)

Slot: %gobs
Readers

gobs (generic function)

Writers

(setf gobs) (generic function)

Class: ecs ()
Package

box.ecs

Source

ecs.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: %current-id
Initform

0

Readers

current-id (generic function)

Writers

(setf current-id) (generic function)

Slot: %gobs-active
Initform

(make-hash-table)

Readers

gobs-active (generic function)

Writers

(setf gobs-active) (generic function)

Slot: %gobs-inactive
Readers

gobs-inactive (generic function)

Writers

(setf gobs-inactive) (generic function)

Slot: %tags
Initform

(make-hash-table)

Readers

%tags (generic function)

Slot: %groups
Initform

(make-hash-table)

Readers

%groups (generic function)

Slot: %traits
Initform

(make-hash-table)

Readers

%traits (generic function)

Writers

(setf %traits) (generic function)

Slot: %behavior
Initform

(make-hash-table)

Readers

behavior (generic function)

Writers

(setf behavior) (generic function)

Slot: 5behavior-order
Readers

behavior-order (generic function)

Writers

(setf behavior-order) (generic function)

Class: trait ()
Package

box.ecs

Source

trait.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: id
Initargs

:id

Readers

id (generic function)

Slot: attrs
Initargs

:attrs

Readers

%trait-attrs (generic function)

Writers

(setf %trait-attrs) (generic function)

Slot: defaults
Initform

(make-hash-table)

Readers

%defaults (generic function)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   F   G   L  
Index Entry  Section

F
File, Lisp, gamebox-ecs.asd: The gamebox-ecs<dot>asd file
File, Lisp, gamebox-ecs/attr.lisp: The gamebox-ecs/attr<dot>lisp file
File, Lisp, gamebox-ecs/behavior.lisp: The gamebox-ecs/behavior<dot>lisp file
File, Lisp, gamebox-ecs/ecs.lisp: The gamebox-ecs/ecs<dot>lisp file
File, Lisp, gamebox-ecs/gob.lisp: The gamebox-ecs/gob<dot>lisp file
File, Lisp, gamebox-ecs/group.lisp: The gamebox-ecs/group<dot>lisp file
File, Lisp, gamebox-ecs/package.lisp: The gamebox-ecs/package<dot>lisp file
File, Lisp, gamebox-ecs/tag.lisp: The gamebox-ecs/tag<dot>lisp file
File, Lisp, gamebox-ecs/trait.lisp: The gamebox-ecs/trait<dot>lisp file
File, Lisp, gamebox-ecs/util.lisp: The gamebox-ecs/util<dot>lisp file

G
gamebox-ecs.asd: The gamebox-ecs<dot>asd file
gamebox-ecs/attr.lisp: The gamebox-ecs/attr<dot>lisp file
gamebox-ecs/behavior.lisp: The gamebox-ecs/behavior<dot>lisp file
gamebox-ecs/ecs.lisp: The gamebox-ecs/ecs<dot>lisp file
gamebox-ecs/gob.lisp: The gamebox-ecs/gob<dot>lisp file
gamebox-ecs/group.lisp: The gamebox-ecs/group<dot>lisp file
gamebox-ecs/package.lisp: The gamebox-ecs/package<dot>lisp file
gamebox-ecs/tag.lisp: The gamebox-ecs/tag<dot>lisp file
gamebox-ecs/trait.lisp: The gamebox-ecs/trait<dot>lisp file
gamebox-ecs/util.lisp: The gamebox-ecs/util<dot>lisp file

L
Lisp File, gamebox-ecs.asd: The gamebox-ecs<dot>asd file
Lisp File, gamebox-ecs/attr.lisp: The gamebox-ecs/attr<dot>lisp file
Lisp File, gamebox-ecs/behavior.lisp: The gamebox-ecs/behavior<dot>lisp file
Lisp File, gamebox-ecs/ecs.lisp: The gamebox-ecs/ecs<dot>lisp file
Lisp File, gamebox-ecs/gob.lisp: The gamebox-ecs/gob<dot>lisp file
Lisp File, gamebox-ecs/group.lisp: The gamebox-ecs/group<dot>lisp file
Lisp File, gamebox-ecs/package.lisp: The gamebox-ecs/package<dot>lisp file
Lisp File, gamebox-ecs/tag.lisp: The gamebox-ecs/tag<dot>lisp file
Lisp File, gamebox-ecs/trait.lisp: The gamebox-ecs/trait<dot>lisp file
Lisp File, gamebox-ecs/util.lisp: The gamebox-ecs/util<dot>lisp file

Jump to:   F   G   L  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   %   (  
A   B   C   D   F   G   H   I   M   N   O   P   R   S   T  
Index Entry  Section

%
%defaults: Internal generic functions
%defaults: Internal generic functions
%gob-attrs: Internal generic functions
%gob-attrs: Internal generic functions
%gob-groups: Internal generic functions
%gob-groups: Internal generic functions
%gob-tag: Internal generic functions
%gob-tag: Internal generic functions
%gob-traits: Internal generic functions
%gob-traits: Internal generic functions
%group-members: Internal functions
%groups: Internal generic functions
%groups: Internal generic functions
%make-gob: Internal functions
%process-gobs: Internal generic functions
%tag-owner: Internal functions
%tags: Internal generic functions
%tags: Internal generic functions
%trait-attrs: Internal generic functions
%trait-attrs: Internal generic functions
%traits: Internal generic functions
%traits: Internal generic functions
%traits-reformat: Internal functions

(
(setf %gob-attrs): Internal generic functions
(setf %gob-attrs): Internal generic functions
(setf %gob-groups): Internal generic functions
(setf %gob-groups): Internal generic functions
(setf %gob-tag): Internal generic functions
(setf %gob-tag): Internal generic functions
(setf %gob-traits): Internal generic functions
(setf %gob-traits): Internal generic functions
(setf %group-members): Internal functions
(setf %tag-owner): Internal functions
(setf %trait-attrs): Internal generic functions
(setf %trait-attrs): Internal generic functions
(setf %traits): Internal generic functions
(setf %traits): Internal generic functions
(setf attr): Internal functions
(setf attrs): Internal functions
(setf behavior): Internal generic functions
(setf behavior): Internal generic functions
(setf behavior-order): Internal generic functions
(setf behavior-order): Internal generic functions
(setf current-id): Internal generic functions
(setf current-id): Internal generic functions
(setf gob): Exported functions
(setf gobs): Internal generic functions
(setf gobs): Internal generic functions
(setf gobs-active): Internal generic functions
(setf gobs-active): Internal generic functions
(setf gobs-inactive): Internal generic functions
(setf gobs-inactive): Internal generic functions
(setf grouping): Internal generic functions
(setf grouping): Internal generic functions
(setf ticks): Internal generic functions
(setf ticks): Internal generic functions
(setf trait-attrs): Internal functions
(setf traits): Exported functions

A
all: Exported functions
any: Exported functions
attr: Internal functions
attr-remove: Internal functions
attrs: Internal functions

B
behavior: Internal generic functions
behavior: Internal generic functions
behavior-by-name: Internal functions
behavior-list: Internal functions
behavior-order: Internal generic functions
behavior-order: Internal generic functions

C
cache-gobs: Internal functions
collect-gobs: Internal functions
current-id: Internal generic functions
current-id: Internal generic functions
cycle-behaviors: Exported functions

D
defbehavior: Exported macros
deftrait: Exported macros

F
filter: Internal functions
filters: Internal generic functions
filters: Internal generic functions
Function, %group-members: Internal functions
Function, %make-gob: Internal functions
Function, %tag-owner: Internal functions
Function, %traits-reformat: Internal functions
Function, (setf %group-members): Internal functions
Function, (setf %tag-owner): Internal functions
Function, (setf attr): Internal functions
Function, (setf attrs): Internal functions
Function, (setf gob): Exported functions
Function, (setf trait-attrs): Internal functions
Function, (setf traits): Exported functions
Function, all: Exported functions
Function, any: Exported functions
Function, attr: Internal functions
Function, attr-remove: Internal functions
Function, attrs: Internal functions
Function, behavior-by-name: Internal functions
Function, behavior-list: Internal functions
Function, cache-gobs: Internal functions
Function, collect-gobs: Internal functions
Function, cycle-behaviors: Exported functions
Function, filter: Internal functions
Function, get-tag: Exported functions
Function, gob: Exported functions
Function, gob-by-tag: Exported functions
Function, gob-list: Internal functions
Function, gobs-by-group: Exported functions
Function, group-delete: Internal functions
Function, group-join: Exported functions
Function, group-leave: Exported functions
Function, group-leave-all: Internal functions
Function, group-list: Internal functions
Function, group-member-p: Internal functions
Function, grouped-p: Internal functions
Function, groupp: Internal functions
Function, groups: Exported functions
Function, has-tag-p: Internal functions
Function, has-trait-p: Exported functions
Function, init-ecs: Exported functions
Function, make-gob-id: Internal functions
Function, none: Exported functions
Function, process-behavior: Exported functions
Function, remove-gob: Exported functions
Function, sort-behaviors: Internal functions
Function, tag-add: Exported functions
Function, tag-delete: Internal functions
Function, tag-list: Internal functions
Function, tag-remove: Exported functions
Function, tagged-p: Internal functions
Function, tagp: Internal functions
Function, trait-add: Exported functions
Function, trait-attr-add: Internal functions
Function, trait-attrs: Internal functions
Function, trait-list: Internal functions
Function, trait-remove: Exported functions
Function, traitp: Internal functions
Function, traits: Exported functions

G
Generic Function, %defaults: Internal generic functions
Generic Function, %gob-attrs: Internal generic functions
Generic Function, %gob-groups: Internal generic functions
Generic Function, %gob-tag: Internal generic functions
Generic Function, %gob-traits: Internal generic functions
Generic Function, %groups: Internal generic functions
Generic Function, %process-gobs: Internal generic functions
Generic Function, %tags: Internal generic functions
Generic Function, %trait-attrs: Internal generic functions
Generic Function, %traits: Internal generic functions
Generic Function, (setf %gob-attrs): Internal generic functions
Generic Function, (setf %gob-groups): Internal generic functions
Generic Function, (setf %gob-tag): Internal generic functions
Generic Function, (setf %gob-traits): Internal generic functions
Generic Function, (setf %trait-attrs): Internal generic functions
Generic Function, (setf %traits): Internal generic functions
Generic Function, (setf behavior): Internal generic functions
Generic Function, (setf behavior-order): Internal generic functions
Generic Function, (setf current-id): Internal generic functions
Generic Function, (setf gobs): Internal generic functions
Generic Function, (setf gobs-active): Internal generic functions
Generic Function, (setf gobs-inactive): Internal generic functions
Generic Function, (setf grouping): Internal generic functions
Generic Function, (setf ticks): Internal generic functions
Generic Function, behavior: Internal generic functions
Generic Function, behavior-order: Internal generic functions
Generic Function, current-id: Internal generic functions
Generic Function, filters: Internal generic functions
Generic Function, gobs: Internal generic functions
Generic Function, gobs-active: Internal generic functions
Generic Function, gobs-inactive: Internal generic functions
Generic Function, grouping: Internal generic functions
Generic Function, id: Internal generic functions
Generic Function, interval: Internal generic functions
Generic Function, mode: Internal generic functions
Generic Function, on-behavior-start: Exported generic functions
Generic Function, on-behavior-stop: Exported generic functions
Generic Function, on-gob-created: Exported generic functions
Generic Function, on-gob-deleted: Exported generic functions
Generic Function, on-group-deleted: Internal generic functions
Generic Function, on-group-join: Exported generic functions
Generic Function, on-group-leave: Exported generic functions
Generic Function, on-tag-added: Exported generic functions
Generic Function, on-tag-removed: Exported generic functions
Generic Function, on-trait-added: Exported generic functions
Generic Function, on-trait-removed: Exported generic functions
Generic Function, ticks: Internal generic functions
get-tag: Exported functions
gob: Exported functions
gob-by-tag: Exported functions
gob-list: Internal functions
gobs: Internal generic functions
gobs: Internal generic functions
gobs-active: Internal generic functions
gobs-active: Internal generic functions
gobs-by-group: Exported functions
gobs-inactive: Internal generic functions
gobs-inactive: Internal generic functions
group-delete: Internal functions
group-join: Exported functions
group-leave: Exported functions
group-leave-all: Internal functions
group-list: Internal functions
group-member-p: Internal functions
grouped-p: Internal functions
grouping: Internal generic functions
grouping: Internal generic functions
groupp: Internal functions
groups: Exported functions

H
has-tag-p: Internal functions
has-trait-p: Exported functions

I
id: Internal generic functions
id: Internal generic functions
init-ecs: Exported functions
interval: Internal generic functions
interval: Internal generic functions

M
Macro, defbehavior: Exported macros
Macro, deftrait: Exported macros
Macro, make-gob: Exported macros
make-gob: Exported macros
make-gob-id: Internal functions
Method, %defaults: Internal generic functions
Method, %gob-attrs: Internal generic functions
Method, %gob-groups: Internal generic functions
Method, %gob-tag: Internal generic functions
Method, %gob-traits: Internal generic functions
Method, %groups: Internal generic functions
Method, %tags: Internal generic functions
Method, %trait-attrs: Internal generic functions
Method, %traits: Internal generic functions
Method, (setf %gob-attrs): Internal generic functions
Method, (setf %gob-groups): Internal generic functions
Method, (setf %gob-tag): Internal generic functions
Method, (setf %gob-traits): Internal generic functions
Method, (setf %trait-attrs): Internal generic functions
Method, (setf %traits): Internal generic functions
Method, (setf behavior): Internal generic functions
Method, (setf behavior-order): Internal generic functions
Method, (setf current-id): Internal generic functions
Method, (setf gobs): Internal generic functions
Method, (setf gobs-active): Internal generic functions
Method, (setf gobs-inactive): Internal generic functions
Method, (setf grouping): Internal generic functions
Method, (setf ticks): Internal generic functions
Method, behavior: Internal generic functions
Method, behavior-order: Internal generic functions
Method, current-id: Internal generic functions
Method, filters: Internal generic functions
Method, gobs: Internal generic functions
Method, gobs-active: Internal generic functions
Method, gobs-inactive: Internal generic functions
Method, grouping: Internal generic functions
Method, id: Internal generic functions
Method, interval: Internal generic functions
Method, mode: Internal generic functions
Method, on-behavior-start: Exported generic functions
Method, on-behavior-start: Exported generic functions
Method, on-behavior-stop: Exported generic functions
Method, on-behavior-stop: Exported generic functions
Method, on-gob-created: Exported generic functions
Method, on-gob-created: Exported generic functions
Method, on-gob-deleted: Exported generic functions
Method, on-gob-deleted: Exported generic functions
Method, on-group-deleted: Internal generic functions
Method, on-group-deleted: Internal generic functions
Method, on-group-join: Exported generic functions
Method, on-group-join: Exported generic functions
Method, on-group-leave: Exported generic functions
Method, on-group-leave: Exported generic functions
Method, on-tag-added: Exported generic functions
Method, on-tag-added: Exported generic functions
Method, on-tag-removed: Exported generic functions
Method, on-tag-removed: Exported generic functions
Method, on-trait-added: Exported generic functions
Method, on-trait-added: Exported generic functions
Method, on-trait-removed: Exported generic functions
Method, on-trait-removed: Exported generic functions
Method, ticks: Internal generic functions
mode: Internal generic functions
mode: Internal generic functions

N
none: Exported functions

O
on-behavior-start: Exported generic functions
on-behavior-start: Exported generic functions
on-behavior-start: Exported generic functions
on-behavior-stop: Exported generic functions
on-behavior-stop: Exported generic functions
on-behavior-stop: Exported generic functions
on-gob-created: Exported generic functions
on-gob-created: Exported generic functions
on-gob-created: Exported generic functions
on-gob-deleted: Exported generic functions
on-gob-deleted: Exported generic functions
on-gob-deleted: Exported generic functions
on-group-deleted: Internal generic functions
on-group-deleted: Internal generic functions
on-group-deleted: Internal generic functions
on-group-join: Exported generic functions
on-group-join: Exported generic functions
on-group-join: Exported generic functions
on-group-leave: Exported generic functions
on-group-leave: Exported generic functions
on-group-leave: Exported generic functions
on-tag-added: Exported generic functions
on-tag-added: Exported generic functions
on-tag-added: Exported generic functions
on-tag-removed: Exported generic functions
on-tag-removed: Exported generic functions
on-tag-removed: Exported generic functions
on-trait-added: Exported generic functions
on-trait-added: Exported generic functions
on-trait-added: Exported generic functions
on-trait-removed: Exported generic functions
on-trait-removed: Exported generic functions
on-trait-removed: Exported generic functions

P
process-behavior: Exported functions

R
remove-gob: Exported functions

S
sort-behaviors: Internal functions

T
tag-add: Exported functions
tag-delete: Internal functions
tag-list: Internal functions
tag-remove: Exported functions
tagged-p: Internal functions
tagp: Internal functions
ticks: Internal generic functions
ticks: Internal generic functions
trait-add: Exported functions
trait-attr-add: Internal functions
trait-attrs: Internal functions
trait-list: Internal functions
trait-remove: Exported functions
traitp: Internal functions
traits: Exported functions

Jump to:   %   (  
A   B   C   D   F   G   H   I   M   N   O   P   R   S   T  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   %   *   5  
A   D   I   S  
Index Entry  Section

%
%attrs: Exported classes
%behavior: Internal classes
%current-id: Internal classes
%filters: Internal classes
%gobs: Internal classes
%gobs-active: Internal classes
%gobs-inactive: Internal classes
%grouping: Internal classes
%groups: Exported classes
%groups: Internal classes
%interval: Internal classes
%mode: Internal classes
%tag: Exported classes
%tags: Internal classes
%ticks: Internal classes
%traits: Exported classes
%traits: Internal classes

*
*ecs*: Internal special variables

5
5behavior-order: Internal classes

A
attrs: Internal classes

D
defaults: Internal classes

I
id: Internal classes

S
Slot, %attrs: Exported classes
Slot, %behavior: Internal classes
Slot, %current-id: Internal classes
Slot, %filters: Internal classes
Slot, %gobs: Internal classes
Slot, %gobs-active: Internal classes
Slot, %gobs-inactive: Internal classes
Slot, %grouping: Internal classes
Slot, %groups: Exported classes
Slot, %groups: Internal classes
Slot, %interval: Internal classes
Slot, %mode: Internal classes
Slot, %tag: Exported classes
Slot, %tags: Internal classes
Slot, %ticks: Internal classes
Slot, %traits: Exported classes
Slot, %traits: Internal classes
Slot, 5behavior-order: Internal classes
Slot, attrs: Internal classes
Slot, defaults: Internal classes
Slot, id: Internal classes
Special Variable, *ecs*: Internal special variables

Jump to:   %   *   5  
A   D   I   S  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   B   C   E   G   P   S   T  
Index Entry  Section

B
behavior: Internal classes
box.ecs: The box<dot>ecs package

C
Class, behavior: Internal classes
Class, ecs: Internal classes
Class, gob: Exported classes
Class, trait: Internal classes

E
ecs: Internal classes

G
gamebox-ecs: The gamebox-ecs system
gob: Exported classes

P
Package, box.ecs: The box<dot>ecs package

S
System, gamebox-ecs: The gamebox-ecs system

T
trait: Internal classes

Jump to:   B   C   E   G   P   S   T