Coder Social home page Coder Social logo

powersink's Introduction

PowerSink

Sponge API 7.3.x Plugin that allows players to pay for energy, or earn money selling energy.

This plugin is in a rough proof of concept state.

Currently supported energy backends:

  • Forge
  • Mekanism

Current implementation borrows from PowerMoney's MoneyCalculator.

Definitions

  • Sink: block to which energy is added
  • Source: block from which energy is removed
  • Node: block that is either a Sink or Source

Usage

To register a Sink, punch an energy storage block with a piece of glowstone dust.

To register a Source, punch an energy storage block with a piece of redstone.

To remove a Node, punch it with a block of bedrock.

Those items are configurable in config/powersink/powersink.conf:

activationItems {
    remove="minecraft:bedrock"
    sink="minecraft:glowstone_dust"
    source="minecraft:redstone"
}

Commands

  • /powersink or /ps: lists sub commands
  • /ps list <player>: lists energy nodes for <player> or self
    • if used with minecraft.commands.tp, a TextAction will be generated to allow teleportation to nodes
    • if used with powersink.remove.[self|other], a TextAction will be generated to allow removal of nodes from PowerSink

General configuration values

powersink {
    currency=dollar #change this to match your economy's currency 
    tickInterval=2 #how often should PowerSink interact with Nodes?
}

Permissions

  • powersink.setup register Sinks and Sources
  • powersink.setup.sink register Sinks
  • powersink.setup.source register Sources
  • powersink.list list Nodes for self or others
  • powersink.list.self list Nodes for self
  • powersink.list.other list Nodes for others
  • powersink.remove remove Nodes for self or others
  • powersink.remove.self remove Nodes for self
  • powersink.remove.other remove Nodes for others

powersink.limit.[admin|player|vip|*] is special

In config/powersink/powersink.conf, there is a block that looks like this:

  # Group limits on sources and sinks.
  limits=[
      {
          group=admin
          sink=1000
          source=1000
      },
      {
          group=player
          sink=4
          source=4
      }
  ]

You can define limit groups here, and assign that group to players. Suppose you create a group named vip, to give that limit to players, assign the powersink.limit.vip permission. Limit groups are evaluated in the order they are defined within the limit list in the config. Be conscious of this when assigning multiple limit groups to players.

powersink's People

Contributors

voidstarr avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

indiiix

powersink's Issues

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.