Crate ABC_Game_Engine

Source

Modules§

audio_stream
delta_time
input
physics
prelude
ui

Structs§

AudioBus
AudioFile
A struct that holds an audio file
AudioHandle
The resource that is used to play audio files
Axis
A 1D axis is a series of positive and negative keys that can be pressed to move the axis in either the positive or negative direction.
AxisEvent
An axis event is an event that is triggered when an axis passes a certain threshold.
Button
A button is a combination of keys that can be pressed to activate it or deactivate it. This is essential for custom keybindings or for games that want to support multiple control schemes.
DeltaTime
EntitiesAndComponents
This struct holds all the entities and components in the game engine It is the main way to interact with the game engine, it is seperate from systems for safety reasons
EntitiesAndComponentsThreadSafe
This struct is a thread safe version of the EntitiesAndComponents struct It is used to allow systems to access the entities and components in parallel It will not allow any non send sync components to be accessed or added
Entity
An entity is a unique identifier for an object in the game engine The entity itself does not hold any data, it is a key to access data from the EntitiesAndComponents struct
GamepadAxis
A gamepad axis specifies a specific axis on a specific gamepad. if the gamepad is not specified, the last gamepad is used.
Input
The input resource. This is the resource that is used to get input from the user.
Scene
Scene is responsible for holding all objects and the background color
SingleMutEntity
This struct is very similar to the EntitiesAndComponents struct but it only allows access to components on a single entity for safety reasons
Transform
Transform is a struct that holds the position, rotation, and scale of an object
World
This struct is the main struct for the game engine

Enums§

AxisDirection
The direction of an axis. X is left and right, Y is up and down.
AxisEventDirection
GamepadButton
The buttons on a gamepad. (note: if there is something wrong with this list or if something is missing, please let me know.)
Key
For either a key or a mouse button. (note: This naming seems a bit off, if you have a better name, please suggest it.)
KeyCode
Key codes for keyboard keys.
KeyState
The state of a key relative to the previous frame.
MouseButton
The mouse buttons. Other can be any other mouse button that isn’t left, right or middle.

Traits§

Component
Components are the data that is stored on entities no need to implement this trait, it is implemented for all ’static types
Resource
Resources are objects that are not components and do not have any relation to entities They are a sort of blend between an entity and a system, they have their own update method that is called every frame like a system But unlike a system, they can be accessed by systems
System
Systems access and change components on objects Be careful to implement get_allow_entity_based_multithreading as true if you want to use the single_entity_step function If you don’t it will still work but, it will be slower (in most cases)

Functions§

add_all_systems
get_transform
gets the transform of an entity, this will return the total transform of the entity, including the transform(s) of the parent(s)
remove_all_non_internal_systems