Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
M MMOBars
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 7
    • Issues 7
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Create a new issue
  • Issue Boards
Collapse sidebar
  • Ethan
  • MMOBars
  • Wiki
  • Conditions

Last edited by Ethan Sep 15, 2021
Page history
This is an old version of this page. You can view the most recent version or browse the history.

Conditions

Conditions allow for bars or their modules to be hidden if they do not meet the criteria that is set. This feature was added in version 1.5.2. Previous versions had a system which used bar options to hide bars which is now removed. Old removed options will be automatically converted to the new conditions format.

Config Examples

In this example the entire bar will be hidden if the condition is not met. The condition will hide the bar if the player is in creative or spectator mode.

health:
  bar:
    width: 40
    function: 'health'
  conditions:
    - 'gamemode{gm=creative,spectator;m=false}'

In this example the number display will be hidden if the condition is not met. The condition will only hide the specific part if not met. In addition to the displays, individual modules may also have conditions.

health:
  bar:
    width: 40
    function: 'health'
  displays:
    icon:
      enabled: true
      type: 'prefix'
      offset: 0
      text: '\uF000'
    number-display:
      enabled: true
      type: 'bar'
      conditions:
        - 'bar-progress{v=1;oper=less;m=true}'
      alignment:
        type: 'center'
      offset: 2
      text: '<white>%value%<gray>/<white>%max%'
Clone repository

MMOBars

  • Home

Bars

  • Settings
  • Functions
  • Colors
  • Styles
  • Options