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

@arcade2d/world

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@arcade2d/world - npm Package Compare versions

Comparing version 0.3.1 to 0.3.2

2

lib/component.d.ts

@@ -23,2 +23,2 @@ import { Value as JSONValue } from 'json-typescript';

export declare type ComponentFactory<T> = (owner: T) => readonly Component<T>[];
export declare type ComponentConstructor<T = any> = new (owner: T, ...args: readonly unknown[]) => Component<T>;
export declare type ComponentConstructor<T = any> = new (owner: T, ...args: readonly any[]) => Component<T>;

@@ -10,3 +10,3 @@ import { Component, ComponentConstructor, ComponentFactory } from './component';

*/
getComponent<C extends Component<T>>(type: new (owner: T, ...args: readonly unknown[]) => C): C;
getComponent<C extends Component<T>>(type: new (owner: T, ...args: readonly any[]) => C | null): C;
/**

@@ -13,0 +13,0 @@ * Adds a new component to this object.

@@ -17,7 +17,4 @@ "use strict";

getComponent(type) {
const component = this.components.get(type);
if (!component) {
throw new Error(`Provider ${this} does not have a component of type ${type.name}.`);
}
return component;
var _a;
return (_a = this.components.get(type)) !== null && _a !== void 0 ? _a : null;
}

@@ -24,0 +21,0 @@ /**

{
"name": "@arcade2d/world",
"version": "0.3.1",
"version": "0.3.2",
"description": "Provides components for composing and running a game world.",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -5,3 +5,3 @@ # @arcade2d/world

[Repository](https://gitlab.com/arcade2d/world) &middot; [Website](https://arcade2d.com)
[Repository](https://gitlab.com/arcade2d/world) &middot; [Website](https://arcade2d.com) &middot; [Reference](https://arcade2d.gitlab.io/world/)

@@ -8,0 +8,0 @@ The aim of this library is to construct and simulate a game world in an abstract sense. It does not provide any functionality or features outside of this such as rendering capabilities (graphics), sound or other game related components. It purely focuses on a game world and how objects within that world can be interacted with and interact with each other.

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