Go to file
ademant d752d27df0 prepared for translations 2019-02-14 13:58:13 +01:00
locale prepared for translations 2019-02-14 13:58:13 +01:00
textures some textures; errors 2018-12-10 17:20:02 +01:00
README.md add repository 2019-02-13 05:05:14 +01:00
api.lua Documentation 2019-02-13 14:47:53 +01:00
chat_commands.lua code cleaning 2018-12-23 08:46:57 +01:00
cmi.lua change readme 2019-02-12 07:31:08 +01:00
config.lua add new element playtime 2019-01-15 04:32:15 +01:00
depends.txt compat for mt 0.4.17 2019-01-09 18:38:40 +01:00
init.lua prepared for translations 2019-02-14 13:58:13 +01:00
intllib.lua prepared for translations 2019-02-14 13:58:13 +01:00
license.txt update readme 2019-01-03 15:51:53 +01:00
mod.conf try to hook on death of player/mod 2019-02-07 11:40:01 +01:00
register.lua Documentation 2019-02-13 14:47:53 +01:00
settingtypes.txt adjust light mean level 2019-02-04 14:45:29 +01:00

README.md

License: MIT

Minetest Game mod: XPFW

See license.txt for license information.

Main repository:

https://notabug.org/ademant/minetest_xpfw.git

Mirrors:

https://gitlab.com/ademant/minetest_xpfw.git

https://github.com/ademant/minetest_xpfw.git

Short description

XPFW provide an API for storing values relevant for experience mechanism into player metadata (Identified with prefix "XPFW_"). It also stores several statistic values during playtime:

  • Walked distances calculated out of velocity (important: teleporting does not influence this value)
  • accumulated distance out of comparing with last known position (important: teleporting is included in this value)
  • whole playtime on the server
  • amount of dug nodes
  • amount of build nodes
  • amount of crafted items
  • amount of occured deahts
  • amount of text messages
  • amount of logins

For several amounts also a kind of speed is calculated, like walking speed or crafting speed.

Chat Commands

Following chat commands are available:

/xpfw prints stored values of XPFW in the chat window

/xphud toggle the visible statistics in players hud on/off

/xpreset set all values to default

/xpset need xpfwset privilege Set variable of user to new value

Usage

Usage (roughly), for Details see api.lua:

  • xpfw.register_attribute(name,data) to register new attribute
  • xpfw.player_get_attribute(player,name) Get stored value of attribute for ObjectRef player
  • xpfw.player_set_attribute(player,name, value) Set attribute for ObjectRef player to
  • xpfw.player_ping_attribute(player,name) "Ping" attribute: Get max value which is defined for attribute and add to attribute. For an attribute, which is defined as moving average attribute this pinging increase the value. High frequency of pinging lead to faster increase, e.g. by pinging a digging attribute you get kind of digging speed, which can be used for an exhaustion mechanism.
  • xpfw.player_add/sub_attribute(player,name,diff) Adds or substract to attribute of for ObjectRef player

Authors of source code

ademant (MIT)

Authors of media (textures)

Created by ademant (CC BY 3.0):