Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bitecs

Package Overview
Dependencies
Maintainers
1
Versions
133
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bitecs - npm Package Compare versions

Comparing version 0.2.25 to 0.2.26

113

dist/index.d.ts

@@ -1,66 +0,67 @@

export type Type =
'bool' |
'i8' |
'ui8' |
'ui8c' |
'i16' |
'ui16' |
'i32' |
'ui32' |
'f32' |
'f64'
declare module 'bitecs' {
export type Type =
'bool' |
'i8' |
'ui8' |
'ui8c' |
'i16' |
'ui16' |
'i32' |
'ui32' |
'f32' |
'f64'
export type TypedArray =
Uint8Array |
Int8Array |
Uint8Array |
Uint8ClampedArray |
Int16Array |
Uint16Array |
Int32Array |
Uint32Array |
Float32Array |
Float64Array
export type TypedArray =
Uint8Array |
Int8Array |
Uint8Array |
Uint8ClampedArray |
Int16Array |
Uint16Array |
Int32Array |
Uint32Array |
Float32Array |
Float64Array
interface IWorld {
[key: string]: any
}
interface IWorld {
[key: string]: any
}
interface ISchema {
[key: string]: Type | ISchema
}
interface ISchema {
[key: string]: Type | ISchema
}
interface IComponentProp {
[key: string]: TypedArray
}
interface IComponentProp {
[key: string]: TypedArray
}
interface IComponent {
[key: string]: TypedArray | IComponentProp
}
interface IComponent {
[key: string]: TypedArray | IComponentProp
}
type QueryModifier = (c: (IComponent | IComponentProp)[]) => (world: IWorld) => IComponent | IComponentProp
type QueryModifier = (c: (IComponent | IComponentProp)[]) => (world: IWorld) => IComponent | IComponentProp
type Query = (world: IWorld) => number[]
type Query = (world: IWorld) => number[]
type System = (world: IWorld) => void
type System = (world: IWorld) => void
export interface IBitECS {
createWorld: (size?: number) => IWorld
addEntity: (world: IWorld) => number
removeEntity: (world: IWorld, eid: number) => void
registerComponent: (world: IWorld, component: IComponent) => void
registerComponents: (world: IWorld, components: IComponent[]) => void
defineComponent: (schema: ISchema) => IComponent
addComponent: (world: IWorld, component: IComponent, eid: number) => void
removeComponent: (world: IWorld, component: IComponent, eid: number) => void
hasComponent: (world: IWorld, component: IComponent, eid: number) => boolean
defineQuery: (components: (IComponent | QueryModifier)[]) => Query
Changed: (c: (IComponent | IComponentProp)[]) => (world: IWorld) => IComponent | IComponentProp
Not: (c: (IComponent | IComponentProp)[]) => (world: IWorld) => IComponent | IComponentProp
enterQuery: (world: IWorld, query: Query, fn: (eid: number) => void) => void
exitQuery: (world: IWorld, query: Query, fn: (eid: number) => void) => void
commitRemovals: (world: IWorld) => void
defineSystem: (update: (world: IWorld) => void) => System
defineSerializer: (target: IWorld | IComponent | IComponentProp | QueryModifier, maxBytes?: number) => (target: IWorld | number[]) => ArrayBuffer
defineDeserializer: (target: IWorld | IComponent | IComponentProp | QueryModifier) => (world: IWorld, packet: ArrayBuffer) => void
export function createWorld (size?: number): IWorld
export function addEntity (world: IWorld): number
export function removeEntity (world: IWorld, eid: number): void
export function registerComponent (world: IWorld, component: IComponent): void
export function registerComponents (world: IWorld, components: IComponent[]): void
export function defineComponent (schema: ISchema): IComponent
export function addComponent (world: IWorld, component: IComponent, eid: number): void
export function removeComponent (world: IWorld, component: IComponent, eid: number): void
export function hasComponent (world: IWorld, component: IComponent, eid: number): boolean
export function defineQuery (components: (IComponent | QueryModifier)[]): Query
export function Changed (c: (IComponent | IComponentProp)[]): (world: IWorld) => IComponent | IComponentProp
export function Not (c: (IComponent | IComponentProp)[]): (world: IWorld) => IComponent | IComponentProp
export function enterQuery (world: IWorld, query: Query, fn: (eid: number) => void): void
export function exitQuery (world: IWorld, query: Query, fn: (eid: number) => void): void
export function commitRemovals (world: IWorld): void
export function defineSystem (update: (world: IWorld) => void): System
export function defineSerializer (target: IWorld | IComponent | IComponentProp | QueryModifier, maxBytes?: number): (target: IWorld | number[]) => ArrayBuffer
export function defineDeserializer (target: IWorld | IComponent | IComponentProp | QueryModifier): (world: IWorld, packet: ArrayBuffer) => void
}
{
"name": "bitecs",
"version": "0.2.25",
"version": "0.2.26",
"description": "Tiny, data-driven, high performance ECS library written in Javascript",

@@ -9,3 +9,3 @@ "license": "MPL-2.0",

"module": "./dist/index.es.js",
"types": "./index.d.ts",
"types": "./dist/index.d.ts",
"exports": {

@@ -12,0 +12,0 @@ "import": "./dist/index.es.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc