Skip to content

audittype_placeholders

test edited this page Aug 14, 2024 · 6 revisions

This page contains a list of functions that can be used as PLACEHOLDERS and FILTERS

About Arguments

Some functions here may accept an argument. The brackets imply argument type, you do NOT include them when using the function.

  • <arg> - A required parameter
  • [arg] - An optional parameter
  • <arg1|arg2> - Multiple parameters options
  • <arg=value> - Default or suggested value
  • [-f flag] - A optional command argument flag

About Placeholders

Placeholders in a text, such as in a spreadsheet or message, are replaced with actual values.

Examples:

  • {myFunction}
  • {functionWithArgs(123)}
  • {withNamedArgs(myArg: 123 otherArg: 456)}
  • ({conditional}?{ifTrue}:{ifFalse})
  • 9-({numericalFunction}+5)*3

About filters

Filters are used to modify a selection. i.e. When you are choosing which things to act upon or display, you use filters to narrow down the selection to ones that meet a certain requirement. When the return type is a string, the filter can be compared using regex to the value. When the return type is boolean (true/false), it will be resolved to either 1 or 0

Examples:

  • #myBoolean,#myOtherTrueFalseFunction
  • (#myFunction=5||#myOtherFunction<10)
  • #textFunction=abc123,#regexFunction=efg.*
  • (#myFunction<(#myOtherFunction+5)

Operators

  • TERNARY: ?
  • GREATER_EQUAL: >=
  • GREATER: >
  • LESS_EQUAL: <=
  • LESS: <
  • NOT_EQUAL: !=
  • EQUAL: =
  • PLUS: +
  • MINUS: -
  • MULTIPLY: *
  • DIVIDE: /
  • POWER: ^

audittype Selectors

  • AUDITTYPE: One of the entity values Example: CHECK_RANK, INACTIVE, FINISH_OBJECTIVES, FIX_COLOR, CHANGE_CONTINENT, FIX_WAR_POLICY, RAID, UNUSED_MAP, BARRACKS, INCORRECT_MMR, BUY_SOLDIERS, BUY_HANGARS, BUY_PLANES, BUY_SHIPS, BEIGE_LOOT, RAID_TURN_CHANGE, BUY_SPIES, GATHER_INTEL, SPY_COMMAND, LOOT_COMMAND, DAILY_SPYOPS, DEPOSIT_RESOURCES, CHECK_DEPOSITS, WITHDRAW_DEPOSITS, OBTAIN_RESOURCES, SAFEKEEP, OBTAIN_WARCHEST, BUY_CITY, BUY_PROJECT, BUY_RESOURCE_PRODUCTION_CENTER, BUY_INFRA, BUY_LAND, UNPOWERED, OVERPOWERED, NOT_NUCLEAR, FREE_SLOTS, NEGATIVE_REVENUE, MISSING_PRODUCTION_BONUS, EXCESS_HOSPITAL, EXCESS_POLICE, EXCESS_RECYCLING, GENERATE_CITY_BUILDS, ROI, BLOCKADED

Sheet Columns

A google sheet url with one of the following columns is accepted: audit


Placeholders


#getEmoji - String

This command is public

Audit emoji

This command has no arguments


#getName - String

This command is public

Name of the audit

This command has no arguments


#getRequired - AuditType

This command is public

The required audit, or null

This command has no arguments


#getResource - double

This command is public

Gets a resource amount from a map of resources

Arguments:

<resources> - Map<ResourceType, Double> A comma separated list of resources and their amounts <resource> - ResourceType The name of a resource


#getResourceValue - double

This command is public

Gets the total resource value for a map of resources

Arguments:

<resources> - Map<ResourceType, Double> A comma separated list of resources and their amounts


#getSeverity - AuditSeverity

This command is public

Audit severity

This command has no arguments


Clone this wiki locally