Back to "organize" tags

Magic spell book categorizer & organizer by cramphy1

1# Organize magic spell books by importance
2# UO Outlands - https://outlands.uorazorscripts.com/mage-bot
3#
4# Version: v1.0.0
5#
6# by Cramphy
7# 10 Feb 2024
8#
9// Have four different bags/containers for each category
10// Get the IDs using >info command in the game then set the IDs
11// I keep same three bags in the secure container at home and never remove them
12// You must open the secure container that contains this bags before running this script
13// Otherwise it cannot find them 
14@setvar! onlyManaMagicBooks '0x45B22972'
15@setvar! onlyDamageMagicBooks '0x45C0C4C1'
16@setvar! manaAndDamageMagicBooks '0x45C32422'
17@setvar! slayerMagicBooks '0x45CEED03'
18
19// Magic Item Recycler Id -> 11762
20// I store unidentified items in the magic item recycler
21// Then I use container identification wand on it to identify all at once
22// Then run this script to organize 
23@clearignore 
24if findtype 11762 ground -1 -1 2 as magicItemRecycler
25    while findtype 3834 magicItemRecycler as item
26        // reset variables
27        @setvar! manaBonus 0
28        @setvar! damageBonus 0
29        @setvar! slayerBonus 0
30        @setvar! durabilityBonus 0
31        
32        getlabel item description
33        
34        if "potent" in description
35            @setvar! manaBonus 1
36        endif
37
38        if "ruin" in description or "might" in description or "force" in description or "power" in description or "vanquishing" in description
39            @setvar! damageBonus 1
40        endif
41        
42        if "slaying" in description
43            @setvar! slayerBonus 1
44        endif
45        
46        // Y location of the item is set by the durability or 
47        // I am using a backpack to store the items
48        // Backpack's first starting row number is 65
49        // You may want to adjust accordingly for different kind of container
50        setvar dropY 65
51        if "durable" in description
52            setvar dropY 80
53        elseif "substantial" in description
54            setvar dropY 95
55        elseif "massive" in description
56            setvar dropY 110
57        elseif "fortified" in description
58            setvar dropY 125
59        elseif "indestructible" in description
60            setvar dropY 140
61        endif
62
63        // X position is set by the level of the item
64       // Starting position is also can be changed accordingly
65        setvar dropX 40
66        if "surpassingly" in description or "might" in description
67            setvar dropX 55
68        elseif "eminently" in description or "force" in description
69            setvar dropX 70
70        elseif "exceedingly" in description or "power" in description
71            setvar dropX 85
72        elseif "supremely" in description or "vanquishing" in description
73            setvar dropX 100
74        endif
75        
76        // Has only mana bonus
77        if manaBonus = 1 and damageBonus = 0 and slayerBonus = 0
78            @setvar! targetContainer onlyManaMagicBooks
79        endif
80
81        // Has only damage bonus
82        if damageBonus = 1 and manaBonus = 0 and slayerBonus = 0
83            @setvar! targetContainer onlyDamageMagicBooks
84        endif
85        
86        // Has mana and damage bonus but not slayer bonus
87        if manaBonus = 1 and damageBonus = 1 and slayerBonus = 0
88            @setvar! targetContainer manaAndDamageMagicBooks
89        endif        
90        
91        // Slayer bonus
92        if slayerBonus = 1
93            @setvar! targetContainer slayerMagicBooks
94        endif
95        
96        lift item
97        drop targetContainer dropX dropY -1
98        ignore item
99        wait 650
100    endwhile
101endif