Reldens - Documentation
Go to websiteCheck our demo!Source GitHub
  • Documentation
  • What is Reldens?
  • Admin Panel
  • System Configuration
  • Contents creation
  • Customize your game
  • Demo server setup - Amazon Linux (2024)
  • Generators and import
  • Installation
  • Known issues
  • How to create a new Room/Scene?
  • Maps Wizard
  • System requirements
  • assets
    • object-sprite
    • player-sprite
    • skill-sprite
  • entities
    • Class Path
    • Item
    • Level Modifiers
    • Level
    • Levels Set
    • Objects
    • Respawn Areas
    • Rooms
    • Skill Types
    • Skill
    • Stats
    • Target Options
  • general
    • Actions
    • Create and configure a player spritesheet
    • Events Manager
    • Operations
    • Plugins
    • Project structure
  • generators
    • Attributes per level generator
    • Enemies experience rewards per level
    • map-composite-file
    • maps-elements
    • Generate multiple maps by loader generator
    • Generate multiple maps with associations by loader generator
    • Generate a single map by elements composite loader
    • Generate a single map by elements object loader
    • Players experience per level generator
  • importers
    • Objects Importer
    • Skills Importer
  • packages
    • tile-map-generator
      • The "composite" approach
      • Tile Map Generator
      • The "objects" approach
Powered by GitBook
On this page
  1. entities

Level Modifiers

PreviousItemNextLevel

Last updated 3 months ago

A "level modifier" in Reldens is a way to establish the player "stats" increments by level.

For example:

  • In level 1 the player will have 20 "HP".

  • In level 2 that will be incremented 10 (30 HP in total).

To make that happen we need to create a "level modifier" for the "level 2" (related by level ID) that will have a "value" of 10 for the player "HP" property.

Though we will always have a "single" set of "stats", the entities (like players or NPCs), will have two sets of the same "stats":

  • The "stats" itself that will contain the current value of the stat.

  • The "statsBase" that will contain the "maximum" value for the stat.

An easy example of this is the common "HP" or "MP" that will be normally increase/decrease with damage or magic, and where you still need to keep the original maximum value like:

  • HP 20 / 100

  • MP 83 / 100

  • [property] [stat-current-value] / [stat-base-value]

These two keys ("stats" and "statsBase") are "hardcoded" in the entities and all over the game logic.

In order to create a modifier we need to specify:

  • "level owner": relation by level ID.

  • "key": a string to identify the modifier.

  • "property key": the path to the property including the initial "set", like "stats/hp" or "statsBase/hp".

  • "operation": normally will be "increment", but you can set any of the available

  • "value": the value that will be applied according the selected "operation".

Note, operations can be used to reduce a "stat" if let's say you want your player change their "path" goal. For example: learning magic will increase the "MP" but at the same time could reduce a player "strength".

operations