User:TheFrz/Item filter: Difference between revisions

From Path of Exile Wiki
Jump to navigation Jump to search
>TheFrz
>TheFrz

Revision as of 01:31, 20 July 2015

This article is a stub. Please help improve the article by expanding it.

Item filter is an optional feature for players to customize item apperance of the ground by filtering items into groups and setting new styles to them. Item filter script language provides a wide and deep item searching (conditions) and styling (colors, sizes, sounds, etc.).

There is no in-game system for item filters, they have to be written by end user in a text file and then enabled in-game.

Setup

Step 1
Go to  %USERPROFILE%\My Documents\My Games\Path of Exile  like at the screenshot:


Step 2
Put a text file with  .filter  extension there:
If you cannot see your file extension, Show/Hide File extensions in Windows


Step 3
Go to the in-game Options menu and click on the UI tab. You should see this new option, located at the very bottom of the list:
If your filter file has not a  .filter  extension, or it is not located in the same folder as your  production_Config.ini  file, you won't see this option.


Step 4
Clicking 'Reload' will display this message if the filter is working correctly:
Unless there will be an error messege with line number and error text itself.

Syntax

The syntax of item filters is a simple set of rules that define a correctly structured and valid script. The item filter don't load if it has invalid syntax.

Structure

The basic structure of a script is a collection of  Show  and  Hide  blocks that each specify certain options. Anything matched by a  Show  block will be shown and anything matched by a  Hide  block will be hidden. If there are multiple conditions in a block then all of them must be matched for the block to match an item.

In the example above you can see a basic example of a script that displays Empower gem with a green border, all gems with 15% quality or higher have bigger text size and all other gems become hidden.

The blocks are matched in the order they come in the file which means items can be matched only once. In this example an Empower gem with 15% quality has a border but hasn't increased text size. This happens because Empower matches conditions in the first block and search for another matching stops. This behaviour makes block ordering very important.

An empty block matches all items, which means that the  Hide  at the end of the file effectively hides everything that wasn't specifically shown.

Comments

Only inline comments are supported. They begin with  #  symbol and use newline character to indicate the end of the comment. Comments can be placed everywhere except the end of conditions. The example below shows valid and invalid positions for comments:

# valid
Show # valid
    Class "Gem" # invalid, unable to pass parameter
    BaseType "Empower" # invalid, unable to pass parameter
    # valid
    SetBorderColor 27 162 155 # valid

Case sensivity

Item filter is case sensitive. For example using  show  instead of  Show  leads to invalid code.

Whitespace

Spaces, tabs and newlines used outside of string constants are called whitespace. Item filter is whitespace insensitive.

Show Class "Gem" BaseType "Empower" SetBorderColor 27 162 155 Hide Class "Gem" # this works

Although it is possible to write down the whole script in 1 line this makes your code absolutelly unreadable.

Conditions

Conditions are options that describe what items will be matched with a block they are inside of. Some conditions allow to use comparision operators such as  > ,  >= ,  <  or  <= .

Option Valid values Description
ItemLevel [operator] level 0..100
DropLevel [operator] level 0..100
Quality [operator] quality 0..20
Rarity [operator] rarity Normal, Magic, Rare or Unique
Class classes string of full or partial class names
BaseType basetypes <string of full or partial base types
Sockets [operator] sockets 0..6
LinkedSockets [operator] links 0..6
SocketGroup group string of socket combination
Height [operator] height 0..5
Width [operator] width 0..3

Styling

Certain items have their own look (i.e. gems have green text color, maps have borders etc.). Item filter system allow users to override default values with another.

Option Valid values Description
SetBackgroundColor red green blue [alpha] <0..255 0..255 0..255> [0..255] Background color of item box
SetBorderColor red green blue [alpha] <0..255 0..255 0..255> [0..255] Border color of item box
SetTextColor red green blue [alpha] <0..255 0..255 0..255> [0..255] Text color
SetFontSize size <18..45> Size of the text (default: 32)
PlayAlertSound sound [volume] <1..9> [0..100] Sound on item drop

Guidelines

Development tools

Troubleshooting

Version history

Version Changes
2.0.0
  • Introduced to the game.