Module synced_components

Source
Expand description

Contains an “x macro” for all synced components as well as NetSync implementations for those components.

An x macro accepts another macro as input and calls it with a list of inputs. This allows adding components to the list in the x macro declaration and then writing macros that will accept this list and generate code that handles every synced component without further repitition of the component set.

This module also re-exports all the component types that are synced.

A glob import from this can be used so that the component types are in scope when using the x macro defined here which requires this.

Modules§

inner 🔒

Macros§

reexport_comps 🔒

Structs§

ActiveAbilities
Admin
Auras
Component holding all auras emitted by an entity.
Beam
Buffs
Component holding all de/buffs that gets resolved each tick. On each tick, remaining time of buffs get lowered and buff effect of each buff is applied or not, depending on the BuffEffect (specs system will decide based on BuffEffect, to simplify implementation). TODO: Something like once flag for Buff to remove the dependence on BuffEffect enum?
CanBuild
CharacterActivity
Contains information about the visual activity of a character.
Combo
Density
The average density (specific mass) of an entity. Units used for reference is kg/m³
Energy
Energy is represented by u32s within the module, but treated as a float by the rest of the game.
Group
Hardcore
Heads
Health
Health is represented by u32s within the module, but treated as a float by the rest of the game.
Immovable
Interactors
Inventory
NOTE: Do not add a PartialEq instance for Inventory; that’s broken!
LightEmitter
LootOwner
Mass
PickupItem
Poise
Poise is represented by u32s within the module, but treated as a float by the rest of the game.
Scale
Shockwave
SkillSet
Contains all of a player’s skill groups and skills. Provides methods for manipulating assigned skills and skill groups including unlocking skills, refunding skills etc.
Stats
Sticky
VolumeRiders

Enums§

Alignment
Body
CharacterState
Collider
Object
Stance

Type Aliases§

IsFollower
IsInteractor
IsLeader
IsMount
IsRider
IsVolumeRider