config

promotions:
  default:
    name: default
    commands:
    - say Please edit Promotion because $0$ wants to promote!
    condition:
      type: de.st_ddt.crazyutil.conditions.Condition_AND
      conditions:
        FALSE0:
          type: de.st_ddt.crazyutil.conditions.Condition_FALSE
        PermissionsGroup1:
          type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
          group: default
        OtherCondtions...:
          type: de.st_ddt.crazyutil.conditions.player.Condition.......
  checked:
    name: checked
    commands:
    - say $0$ checked whether he can promote
    - permissions player addgroup $0$ promotedguest
    - permissions player removegroup $0$ guest
    condition:
      type: de.st_ddt.crazyutil.conditions.Condition_TRUE

------
FALSE0 is just a name the computer uses to avoid overriding some conditions
$0$ in command section is replaced by playername
------

Condition usage:

Condition_TRUE:
  type: de.st_ddt.crazyutil.conditions.Condition_TRUE

Condition_FALSE:
  type: de.st_ddt.crazyutil.conditions.Condition_FALSE

Condition_NOT:
  type: de.st_ddt.crazyutil.conditions.Condition_NOT
  condition:
     AnotherCondition

Condition_AND:
  type: de.st_ddt.crazyutil.conditions.Condition_AND
  conditions:
    Condition1
    Condition...
    ConditionN

Condition_OR:
  type: de.st_ddt.crazyutil.conditions.Condition_OR
  conditions:
    Condition1
    Condition...
    ConditionN

ConditionDate:
  type: de.st_ddt.crazyutil.conditions.ConditionDate
  date: YYYY.MM.DD hh:mm:ss
  before: true/false 
#if (before==true) it returns true until date is past, if (before==false) it returns true since date is past

ConditionPlayerName:
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerName
  name: PlayerName (regex support)

ConditionPlayerPermission:
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermission
  permission: PermissionString

ConditionPlayerPermissionGroup:
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
  group: GroupName

ConditionPlayerOnlineTime: (requires CrazyOnline)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerOnlineTime
  time: Total_Time_in_Minutes

ConditionPlayerTimeSinceFirstJoin: (requires CrazyOnline)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerTimeSinceFirstJoin
  time: Time_Since_First_Join_in_Milliseconds
  above: true/false
#if (above==true) it return true if more time has passed; if (above==false) it return true if less time has passed

ConditionPlayerTimeSinceLastJoin: (requires CrazyOnline)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerTimeSinceLastJoin
  time: Time_Since_Last_Join_in_Milliseconds
  above: true/false
#if (above==true) it return true if more time has passed; if (above==false) it return true if less time has passed

ConditionPlayerTimeSinceLastLogout: (requires CrazyOnline)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerTimeSinceFirstJoin
  time: Time_Since_Last_Logout_in_Milliseconds
  above: true/false
#if (above==true) it return true if more time has passed; if (above==false) it return true if less time has passed

ConditionPlayerLoginHasAccount: (requires CrazyLogin)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerLoginHasAccount

ConditionPlayerLoginIsLoggedIn: (requires CrazyLogin)
  type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerLoginIsLoggedIn

Example:

promotions:
  Member:
    name: Member
    commands:
    - permissions player addgroup &1 member
    - permissions player removegroup &1 default
    condition:
      type: de.st_ddt.crazyutil.conditions.Condition_AND
      conditions:
        ConditionPlayerOnlineTime:
          type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerOnlineTime
          time: 600
        PermissionsGroup1:
          type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
          group: default
        Not2:
          type: de.st_ddt.crazyutil.conditions.Condition_NOT
          condition:
            type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
            group: member
  Veteran:
    name: Veteran
    commands:
    - permissions player addgroup &1 Veteran
    - permissions player removegroup &1 member
    condition:
      type: de.st_ddt.crazyutil.conditions.Condition_AND
      conditions:
        ConditionPlayerOnlineTime:
          type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerOnlineTime
          time: 4800
        PermissionsGroup1:
          type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
          group: member
        Not2:
          type: de.st_ddt.crazyutil.conditions.Condition_NOT
          condition:
            type: de.st_ddt.crazyutil.conditions.player.ConditionPlayerPermissionGroup
            group: veteran


The Condition_NOT is required sometimes to block downgrading a player.
(Depends on PermissionPlugin / PermissionConfig)