semeion/lib.rs
1//! A 2D environment simulator, that let's you define the behavior and the shape
2//! of your entities, while taking care of dispatching events generation after
3//! generation.
4//!
5//! # Overview
6//! `semeion` is a library that was born out of the curiosity to see
7//! how to abstract those few concepts that are, most of the times, shared
8//! between very simple 2D games mostly focused on simulations, such as cellular
9//! automata or zero-player games.
10//!
11//! When writing such games, it's usually standard practice to rely on already
12//! existing game engines, which do a great job in abstracting the complexity of
13//! the event loop, graphic rendering system, or assets management.
14//! They all come in different flavors, but they mostly share the same concepts
15//! when it comes to event handling: the *update* callback allows you to define
16//! where the logic of your game will take place, and the *draw* callback allows
17//! you to define where to render your entities; finally the third main component
18//! takes care of the player's inputs.
19//!
20//! But besides the events handling, the graphics rendering system, or the assets
21//! management, writing small games, especially when focusing on simulations
22//! and similar, most often involves another type of abstraction: the entities
23//! management system and related components.
24//!
25//! This is where `semeion` takes place: it's a basic framework that acts
26//! orthogonally and independently from your game engine, and allows you to focus
27//! on the behavior of your entities, while it takes care of managing them and
28//! dispatching their events.
29//!
30//! With `semeion`, you can implement the generic [Entity](crate::Entity)
31//! trait and define the behavior of your entities for each kind, and how they
32//! will interact with each other according to their scope of influence,
33//! location in the [Environment](crate::Environment), and lifetime.
34
35pub use entity::*;
36pub use env::*;
37pub use error::*;
38pub use math::*;
39pub use space::*;
40
41pub mod entity;
42pub mod env;
43pub mod error;
44pub mod math;
45pub mod space;