Regular_Expression (Wikipedia)
it can be use to :-
1. generate a huge list of mapflags
2. fix outdated format on the script commands
3. apply a quick fix on CVS style database
4. convert client side item list into array
Example 1. Generate a huge list of mapflags
1. goto db/map_index.txt, copy over the map list
2. there are some lines commented, so find the line with // and remove them by doing this
Find with regular expression Replace with empty string, this effectively leave the line blank
3. Edit -> Line Operations -> Remove Empty lines
4. Find with regular expression Replace with
Example 2. Fix outdated format on the script commands
Find with regular expression Replace with
Example 3. Apply a quick fix on CVS style database
rathena only, Hercules has switched to libconfig formatgoto db/re/item_db.txt
Find with regular expression Replace with Find with regular expression Replace with Find with regular expression Replace with
Example 4: Convert client side item list into array
goto kro/data/cardprefixnametable.txtFind with regular expression Replace with
External Links:
Disable dead branch (Example 1)Convert pow(a,b) into a**b (Example 2)
Swap item type IT_ARMOR and IT_WEAPON (Example 3)
getitemname2 function (Example 4)
No comments:
Post a Comment