Skip to content

A library for creating entities that build up potential energy.

Notifications You must be signed in to change notification settings

Terasology/PotentialEnergyDevices

Repository files navigation

#Potential Energy Devices This module provides a common set of components that can store energy in an entity.

##Storing Energy ###Basic usage on a prefab

{
  "PotentialEnergyDevice": {
    "maximumStoredEnergy": 50
  }
}

###Defaults

{
  "PotentialEnergyDevice": {
    "currentStoredEnergy": 0
    "maximumStoredEnergy": 0
  }
}

##Energy Regeneration or Decay Adding the PotentialEnergyRegenComponent to an entity that has a PotentialEnergyDeviceComponent on it will continuously add energy to the current stored energy.

###Basic usage on a prefab

{
  "PotentialEnergyRegen": {
    "energyPerSecond": -5
  }
}

###Defaults

{
  "PotentialEnergyRegen": {
    "energyPerSecond": 0
  }
}