GithubHelp home page GithubHelp logo

geeny616 / ds-hammer-factory Goto Github PK

View Code? Open in Web Editor NEW

This project forked from playmint/ds-hammer-factory

2.0 0.0 2.0 352 KB

Crafting example that creates the finest hammers in the land

Shell 9.67% JavaScript 13.58% Dockerfile 2.55% Solidity 74.20%

ds-hammer-factory's Introduction

A Factory That Makes Hammers (in Dawnseekers)

Getting started

This is a forge project, (install foundry)

Once you have foundry, you should be able to run the tests:

forge test

inside the src dir you will find two files:

  • HammerFactory.sol - this is a BuildingKind Extension, Players can call your use function by visiting instances of the BuildingKind on the map
  • HammerFactory.js - this is a client plugin that will be loaded when Players visit instance of the BuildingKind, use it to show UI for calling the use function

How to deploy

Find the address of the game contract....

Visit http://localhost:8080/ and execute this query:

query {
  game(id: "DAWNSEEKERS") {
    id
  }
}

The returned id is the game address.

Deploy the BuildingKind extension and plugin, substituting the correct game id you found above:

GAME_ADDRESS=0x1D8e3A7Dc250633C192AC1bC9D141E1f95C419AB forge script script/Deploy.sol --broadcast --verify --rpc-url "http://localhost:8545"

ds-hammer-factory's People

Contributors

hypnoshock avatar chrisfarms avatar chris-baker avatar ldunnplaymint avatar

Stargazers

Timuçin OSANMAZ avatar Timuçin YILMAZ avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.