Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,2 @@
.DS_Store
.vscode/settings.json
.vscode/settings.json
smart-storage-unit/mprocs.log
smart-turret/mprocs.log
smart-gate/mprocs.log
smart-turret/packages/contracts/.env
.vscode/settings.json
12 changes: 0 additions & 12 deletions GPC.txt

This file was deleted.

11 changes: 6 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@
</div>

## Welcome to EVE Frontier Building!
Welcome, this repository contains guides and examples to get started building on [EVE Frontier](https://evefrontier.com/en). For more information, you can visit https://docs.evefrontier.com/.
Welcome, this repository contains guides and examples to get started building on [EVE Frontier](https://evefrontier.com/en). For more information, you can visit [docs.evefrontier.com](https://docs.evefrontier.com/).

To start building, follow the steps below to setup your local development tools and environment. If you already have the tools, make sure they are the correct version as otherwise you may have difficulties running the examples and building.

## Table of Contents

1. [Installing general tools](#step-1-installing-general-tools)
- [Installing Git](#installing-git)
- [Installing Node Version Manager](#installing-node-version-manager)
- [Installing NVM (Node Version Manager)](#installing-node-version-manager)
- [Installing Node.JS](#installing-node)
- [Installing PNPM](#installing-pnpm)
- [Installing Foundry + Forge](#installing-foundry--forge)
2. [Setting up your environment](#step-2-setting-up-your-environment)
Expand All @@ -30,7 +31,7 @@ To start building, follow the steps below to setup your local development tools
---

### Step 1: Installing general tools
Before you get started you need to either install, or make sure you have the required tools. Install these tools for Linux, if you use a different OS then visit [Tools Setup](https://docs.evefrontier.com/Tools) and follow the guide for your operating system.
Before you get started you need to either install, or make sure you have the required tools. This guide is for Linux / WSL, if you use a different OS then visit [Tools Setup](https://docs.evefrontier.com/Tools) and follow the guide for your operating system.

#### Installing Git
Install Git through [Installing Git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git).
Expand All @@ -40,7 +41,7 @@ To confirm Git has been installed run:
git --version
```

#### Installing Node Version Manager
#### Installing NVM (Node Version Manager)
Install NVM using this command:
```bash
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash && source ~/.bashrc
Expand All @@ -58,7 +59,7 @@ Install PNPM, which is used as a more efficient version of NPM with:
npm install -g pnpm
```

### Installing Foundry + Forge
#### Installing Foundry + Forge
Install foundry and restart the shell with:
```bash
curl -L https://foundry.paradigm.xyz | bash && source ~/.bashrc
Expand Down
1 change: 1 addition & 0 deletions pods/readme.md
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
# PODs
For a guide on PODs and how to use these tools please visit https://docs.evefrontier.com/pods
Binary file modified readme-imgs/deploy.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified readme-imgs/evefrontier.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified readme-imgs/tests-ssu.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed readme-imgs/world-address.png
Binary file not shown.
25 changes: 0 additions & 25 deletions sanitizeEnv.sh

This file was deleted.

6 changes: 0 additions & 6 deletions smart-assembly-scaffold/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,4 @@ node_modules
packages/contracts/worlds.json
packages/contracts/src/codegen

# foundry artefacts
mock-data/cache/
mock-data/out/
mock-data/broadcast/
mock-data/cache/

mprocs.log
6 changes: 0 additions & 6 deletions smart-gate/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,4 @@ node_modules
packages/contracts/worlds.json
packages/contracts/src/codegen

# foundry artefacts
mock-data/cache/
mock-data/out/
mock-data/broadcast/
mock-data/cache/

mprocs.log
5 changes: 2 additions & 3 deletions smart-gate/packages/contracts/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ node_modules/
bindings/
artifacts/
broadcast/
.env

# Ignore MUD deploy artifacts
deploys/**/*.json

.env
deploys/**/*.json
8 changes: 3 additions & 5 deletions smart-gate/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ pnpm test
```

This will run a series of pre-defined tests, and should display the results like:
![../readme-imgs/tests-gate.png]
![Smart Gate Unit Tests](../readme-imgs/tests-gate.png)

## Deployment To The Game (Stillness)
To deploy the example to the game server which is named Stillness, follow the below steps.
Expand Down Expand Up @@ -217,9 +217,7 @@ pnpm run deploy:pyrope

Once the deployment is successful, you'll see a screen similar to the one below.

<div align="center">
<img src="../readme-imgs/deploy.png" alt="Deploy" width="600">
</div>
![Deployment Success Message Image](../readme-imgs/deploy.png)

## Configuring and Testing the Game Contracts (Stillness)

Expand Down Expand Up @@ -252,7 +250,7 @@ For Stillness, the Smart Gate ID is available once you have deployed an Smart Ga

Now set the ALLOWED_TRIBE_ID variable.

1. Retrieve your character address from searching your username here: [Smart Characters World API](https://world-api-stillness.live.tech.evefrontier.com/smartcharacters)
1. Retrieve your character address from searching your username here: [Smart Characters World API](https://world-api-stillness.live.tech.evefrontier.com/v2/smartcharacters)

2. Use this link: https://world-api-stillness.live.tech.evefrontier.com/v2/smartcharacters/ADDRESS and replace **"ADDRESS"** with the address from the previous step.

Expand Down
6 changes: 1 addition & 5 deletions smart-storage-unit/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,4 @@ node_modules
packages/contracts/worlds.json
packages/contracts/src/codegen

# foundry artefacts
mock-data/cache/
mock-data/out/
mock-data/broadcast/
mock-data/cache/
mprocs.log
4 changes: 1 addition & 3 deletions smart-storage-unit/packages/contracts/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,4 @@ broadcast/
.env

# Ignore MUD deploy artifacts
deploys/**/*.json

packages/contracts/.env
deploys/**/*.json
2 changes: 2 additions & 0 deletions smart-storage-unit/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 19 additions & 14 deletions smart-storage-unit/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,22 +98,29 @@ pnpm mock-data
> This will create the on-chain SSU, fuel it and bring it online.

### Step 4: Configure SSU
To configure which items should be traded and the ratio's to trade for run:
To configure which items should be traded and the ratios to trade for run:

```bash
pnpm configure
```

> [!NOTE]
> You can adjust the values for the SSU_ID, in and out item ID's and the ratios in the .env file as needed, though they are optional to change for local development.
> You can adjust the values for the SSU_ID, in and out item IDs and the ratios in the .env file as needed, though they are optional to change for local development.

### Step 5: Test The SSU (Optional)
To test the SSU, execute the following command which will run a series of pre-defined tests to ensure the contracts are working:

To test the behavior of the SSU contracts, you can use this command to execute a trade:
```bash
pnpm execute
```

You can also test the Smart Storage Unit using the unit tests with:
```bash
pnpm test
```

This will run a series of pre-defined tests, and should display the results like:
![Smart Storage Unit Tests](../readme-imgs/tests-ssu.png)

## Deployment to The Game (Stillness)
To deploy the example to the game server which is named Stillness, follow the below steps.

Expand Down Expand Up @@ -164,7 +171,7 @@ A namespace is a unique identifier for deploying your smart contracts. Once you
Change the namespace from test to your own custom namespace.

> [!TIP]
> Consider using your username or corporation name as your namespace.
> Consider using your username or Tribe name as your namespace.

First, edit **packages/contracts/mud.config.ts** to include your new namespace:

Expand Down Expand Up @@ -221,9 +228,7 @@ pnpm run deploy:pyrope

Once the deployment is successful, you'll see a screen similar to the one below.

<div align="center">
<img src="../readme-imgs/deploy.png" alt="Deploy" width="600">
</div>
![Deployment Success Message Image](../readme-imgs/deploy.png)

## Configuring and Testing the Game Contracts (Stillness)

Expand All @@ -239,7 +244,7 @@ TEST_PLAYER_PRIVATE_KEY=0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d
```

> [!NOTE]
> This is only for testing, and an example not requiring this is on it's way.
> This is only for testing, and an example not requiring this is on its way.

#### Step 1.2: Smart Storage Unit ID (SSU ID)

Expand All @@ -259,9 +264,9 @@ For Stillness, the Smart Storage Unit ID (SSU ID) is available once you have dep
SSU_ID=34818344039668088032259299209624217066809194721387714788472158182502870248994
```

#### Step 1.3: Item ID's
#### Step 1.3: Item IDs

To retrieve the Item ID's you can use https://world-api-stillness.live.tech.evefrontier.com/v2/types and then search for the item name.
To retrieve the Item IDs you can use https://world-api-stillness.live.tech.evefrontier.com/v2/types and then search for the item name.

You can use the "smartItemId" as the Item ID.

Expand All @@ -275,7 +280,7 @@ You can use the "smartItemId" as the Item ID.
```


Configure the Item ID's in the .env file.
Configure the Item IDs in the .env file.

```bash
#Item Bought
Expand Down Expand Up @@ -307,14 +312,14 @@ pnpm set-config
```

### Step 2: Configure SSU
To configure which items should be traded and the ratio's to trade for run:
To configure which items should be traded and the ratios to trade for run:

```bash
pnpm configure
```

> [!NOTE]
> You can adjust the values for the SSU_ID, in and out item ID's and the ratios in the .env file as needed.
> You can adjust the values for the SSU_ID, in and out item IDs and the ratios in the .env file as needed.

> [!IMPORTANT]
> Trades are not automatic, which means that you need to run the `pnpm execute` command or call the execute smart contract function on the SSU to trade items.
Expand Down
8 changes: 1 addition & 7 deletions smart-turret/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,4 @@ node_modules
packages/contracts/worlds.json
packages/contracts/src/codegen

# foundry artefacts
mock-data/cache/
mock-data/out/
mock-data/broadcast/
mock-data/cache/

packages/contracts/.env
mprocs.log
1 change: 1 addition & 0 deletions smart-turret/packages/contracts/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ node_modules/
bindings/
artifacts/
broadcast/
.env

# Ignore MUD deploy artifacts
deploys/**/*.json
Expand Down
24 changes: 11 additions & 13 deletions smart-turret/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,7 @@ Then, run the following commands:

Once the contracts have been deployed you should see the below message. When changing the contracts it will automatically re-deploy them.

<div align="center">
<img src="../readme-imgs/deploy.png" alt="Deploy" width="600">
</div>
![Deployment Success Message Image](../readme-imgs/deploy.png)

### Step 1: Mock data for the existing world **(Local Development Only)**

Expand Down Expand Up @@ -104,7 +102,7 @@ pnpm configure
> You can adjust the values of the Smart Turret ID and allowed tribe ID in the .env file as needed, though they are optional.

### Step 3: Test The Smart Turret (Optional)
To test the custom Smart Turret functionality you can use the follow command:
To test the custom Smart Turret functionality you can use:

```bash
pnpm execute
Expand All @@ -116,9 +114,9 @@ pnpm test
```

This will run a series of pre-defined tests, and should display the results like:
![../readme-imgs/tests-turret.png]
![Smart Turret Unit Tests](../readme-imgs/tests-turret.png)

## Deployment To The Game (Stillness)</a>
## Deployment To The Game (Stillness)
To deploy the example to the game server which is named Stillness, follow the below steps.

### Step 1: Setup your Environment
Expand All @@ -133,7 +131,7 @@ Then install the Solidity dependencies for the contracts:
pnpm install
```

Then, if you haven't already copy the .envsample file to a .env file with:
Then, if you haven't already, copy the .envsample file to a .env file with:
```bash
cp .envsample .env
```
Expand Down Expand Up @@ -225,9 +223,9 @@ pnpm run deploy:pyrope

Once the deployment is successful, you'll see a screen similar to the one below.

<div align="center">
<img src="../readme-imgs/deploy.png" alt="Deploy" width="600">
</div>
<center>
![Deployment Success Message Image](../readme-imgs/deploy.png)
</center>

## Configuring and Testing the Game Contracts (Stillness)

Expand All @@ -236,7 +234,7 @@ Next, replace the following values in the [.env](./packages/contracts/.env) file

#### Step 1.1: Smart Turret ID (Turret ID)

For Stillness, the Smart Turret ID is available once you have deployed an Smart Turret in the game.
For Stillness, the Smart Turret ID is available once you have deployed a Smart Turret in the game.

1. Right click your Smart Turret and press Interact

Expand All @@ -256,9 +254,9 @@ For Stillness, the Smart Turret ID is available once you have deployed an Smart

Now set the `ALLOWED_TRIBE_ID` variable.

1. Retrieve your character address from searching your username here: [Smart Characters World API](https://world-api-stillness.live.tech.evefrontier.com/smartcharacters)
1. Retrieve your character address from searching your username here: [Smart Characters World API](https://world-api-stillness.live.tech.evefrontier.com/v2/smartcharacters)

2. Use this link: https://world-api-stillness.live.tech.evefrontier.com/smartcharacters/ADDRESS and replace **"ADDRESS"** with the address from the previous step.
2. Use this link: https://world-api-stillness.live.tech.evefrontier.com/v2/smartcharacters/ADDRESS and replace **"ADDRESS"** with the address from the previous step.

3. Use the **"tribeId"** value which should be in:

Expand Down