forked from Sehrentos/rAthena-syntax-highlight
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathfunctionList.xml
73 lines (68 loc) · 2.68 KB
/
functionList.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<?xml version="1.0" encoding="UTF-8" ?>
<!--
For learning making your language parser, please check the following link:
http://notepad-plus-plus.org/features/function-list.html
-->
<NotepadPlus>
<functionList>
<associationMap>
<!--
DO NOT OVERWRITE YOUR LOCAL FILE WITH THIS FILE
Just copy necessary lines below for rAthena UDL and rathena_script_doc lang definitions
-->
<!-- Function List for "rathena" UDL -->
<association userDefinedLangName="rathena" id="rathena_function"/>
<!-- Copy/Save as rathena UDL with name rathena_script_doc, set your script_commands.txt's language to rathena_script_doc -->
<association userDefinedLangName="rathena_script_doc" id="rathena_script_doc"/>
<!-- copy above until here -->
</associationMap>
<parsers>
<!--
DO NOT OVERWRITE YOUR LOCAL FILE WITH THIS FILE
Just copy necessary lines below for rAthena UDL and rathena_script_doc lang definitions
-->
<parser id="rathena_function" displayName="NPC Script" commentExpr="(/\*.*\*/)">
<!-- NPC Scripts -->
<classRange
mainExpr="^([\w_-]+[^\t]*)\tscript\t([^\t]*)\t[^\{]*\{"
openSymbole = "\{"
closeSymbole = "\}"
displayMode="node">
<className>
<nameExpr expr="script\t([^\t]+)"/>
<nameExpr expr="\t([^\t]+)"/>
</className>
<function
mainExpr="(^[\s]*((On\w+:)|(function[\s\t][^\s\t]+[\s\t]\{))[\r\n])|(script\t[^\t]+\t)">
<functionName>
<funcNameExpr expr="(On\w+:)|function[\s\t](\w+)|(script\t[^\t]+\t)"/>
<funcNameExpr expr="(On\w+)|function[\s\t](\w+)|\t([^\t]+)\t"/>
</functionName>
</function>
</classRange>
<!-- NPC Duplication, warps, shops, permanent monster spawns, mapflags -->
<function
mainExpr="(^[\w_-]+[^\t]*\t(mapflag)\t[\w_-]+)|((^[\w_-]+)[^\t]*\t(duplicate\([^\)]+\)|monster|(point|market|cash|item)?shop|warp2?)\t[^\t]+\t[^\r\n]+)"
displayMode="$functionName">
<functionName>
<nameExpr expr="(mapflag\t[\w_-]+)|((duplicate\([^\)]+\)|monster|shop|script|warp2?)\t[^\t\r\n]+)"/>
<nameExpr expr="(\t[^\t\r\n]+)"/>
</functionName>
<className>
<nameExpr expr="(^[\w_-]+[^\t]*\t(mapflag))|((duplicate\([^\)]+\)|monster|(point|market|cash|item)?shop|warp2?))"/>
</className>
</function>
</parser>
<parser id="rathena_script_doc" displayName="Script Commands" commentExpr="(//[^\r\n]+|^\*Name)">
<function
mainExpr="^\*([a-z])([\w\-]+)([^ \(;])([\w\-\{\}]*)([^\r\n]+)$"
displayMode="$functionName">
<functionName>
<nameExpr expr="\w([\w\-]+)([^ \(;])([\w\-\{\}]*)([^\r\n]+)$"/>
</functionName>
</function>
</parser>
<!-- copy above until here -->
</parsers>
</functionList>
</NotepadPlus>