diff --git a/LICENSE b/LICENSE new file mode 100644 index 00000000..e1cc3e48 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022-present + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/media/dojo-init.mov b/media/dojo-init.mov new file mode 100644 index 00000000..eb042bdb Binary files /dev/null and b/media/dojo-init.mov differ diff --git a/media/screen-grab.png b/media/screen-grab.png new file mode 100644 index 00000000..57987d91 Binary files /dev/null and b/media/screen-grab.png differ diff --git a/packages/core/src/constants/abi.json b/packages/core/src/constants/abi.json deleted file mode 100644 index 7d13862f..00000000 --- a/packages/core/src/constants/abi.json +++ /dev/null @@ -1,335 +0,0 @@ -[ - { - "type": "function", - "name": "component", - "inputs": [ - { - "name": "name", - "type": "core::felt252" - } - ], - "outputs": [ - { - "type": "core::starknet::class_hash::ClassHash" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "register_component", - "inputs": [ - { - "name": "class_hash", - "type": "core::starknet::class_hash::ClassHash" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "system", - "inputs": [ - { - "name": "name", - "type": "core::felt252" - } - ], - "outputs": [ - { - "type": "core::starknet::class_hash::ClassHash" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "register_system", - "inputs": [ - { - "name": "class_hash", - "type": "core::starknet::class_hash::ClassHash" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "uuid", - "inputs": [], - "outputs": [ - { - "type": "core::integer::u32" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "emit", - "inputs": [ - { - "name": "keys", - "type": "core::array::Span::" - }, - { - "name": "values", - "type": "core::array::Span::" - } - ], - "outputs": [], - "state_mutability": "view" - }, - { - "type": "function", - "name": "execute", - "inputs": [ - { - "name": "system", - "type": "core::felt252" - }, - { - "name": "calldata", - "type": "core::array::Array::" - } - ], - "outputs": [ - { - "type": "core::array::Array::" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "entity", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "query", - "type": "dojo::database::query::Query" - }, - { - "name": "offset", - "type": "core::integer::u8" - }, - { - "name": "length", - "type": "core::integer::u32" - } - ], - "outputs": [ - { - "type": "core::array::Span::" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "set_entity", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "query", - "type": "dojo::database::query::Query" - }, - { - "name": "offset", - "type": "core::integer::u8" - }, - { - "name": "value", - "type": "core::array::Span::" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "entities", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "partition", - "type": "core::felt252" - }, - { - "name": "length", - "type": "core::integer::u32" - } - ], - "outputs": [ - { - "type": "(core::array::Span::, core::array::Span::>)" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "set_executor", - "inputs": [ - { - "name": "contract_address", - "type": "core::starknet::contract_address::ContractAddress" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "executor", - "inputs": [], - "outputs": [ - { - "type": "core::starknet::contract_address::ContractAddress" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "delete_entity", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "query", - "type": "dojo::database::query::Query" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "origin", - "inputs": [], - "outputs": [ - { - "type": "core::starknet::contract_address::ContractAddress" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "is_owner", - "inputs": [ - { - "name": "account", - "type": "core::starknet::contract_address::ContractAddress" - }, - { - "name": "target", - "type": "core::felt252" - } - ], - "outputs": [ - { - "type": "core::bool" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "grant_owner", - "inputs": [ - { - "name": "account", - "type": "core::starknet::contract_address::ContractAddress" - }, - { - "name": "target", - "type": "core::felt252" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "revoke_owner", - "inputs": [ - { - "name": "account", - "type": "core::starknet::contract_address::ContractAddress" - }, - { - "name": "target", - "type": "core::felt252" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "is_writer", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "system", - "type": "core::felt252" - } - ], - "outputs": [ - { - "type": "core::bool" - } - ], - "state_mutability": "view" - }, - { - "type": "function", - "name": "grant_writer", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "system", - "type": "core::felt252" - } - ], - "outputs": [], - "state_mutability": "external" - }, - { - "type": "function", - "name": "revoke_writer", - "inputs": [ - { - "name": "component", - "type": "core::felt252" - }, - { - "name": "system", - "type": "core::felt252" - } - ], - "outputs": [], - "state_mutability": "external" - } -] diff --git a/readme.md b/readme.md index 56a6164f..5046298f 100644 --- a/readme.md +++ b/readme.md @@ -26,36 +26,25 @@ **Dojo is a community driven open-source, Provable Game Engine, providing a comprehensive toolkit for building verifiable games and autonomous worlds.** ---- - -## Dojo Engine Packages Monorepo +You can get started by simply bootstrapping dojo world like so. You will need [dojo](https://github.com/dojoengine/dojo) installed. -This is a monorepo for the [dojo engine](https://www.dojoengine.org/en/) npm packages. +```console +npx @dojoengine/create-dojo +``` -### Available Packages: +[![dojo init](./media/screen-grab.png)](./media/dojo-init.mov) -- [**Core**](./packages/core) -- [**Burner**](./packages/create-burner) -- [**Utils**](./packages/utils) -- [**React**](./packages/react) -- [**Torii Client**](./packages/torii-client) -- [**Torii Wasm**](./packages/torii-wasm) +### Contributing to dojo.js ---- +Dojo.js is MIT licensed and welcomes contributors. Setting up your environment is simple. -### Environment Setup +#### Prerequisites 1. **Bun Installation**: We use [bun](https://bun.sh/) in this repository. To install it, run: ```console curl -fsSL https://bun.sh/install | bash ``` ---- - -### Development - -#### Package Dependencies Installation: - From the repository root, run the following to install all the necessary package dependencies: ```console @@ -104,12 +93,6 @@ git submodule update --init --recursive ### Examples -To scaffold a new project from an example: - -```console -npx @dojoengine/create-dojo -``` - If you have issues on WSL, install package first then run command : ```console