-
Notifications
You must be signed in to change notification settings - Fork 1
/
bot_mag.mac
183 lines (133 loc) · 4.55 KB
/
bot_mag.mac
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
|**
----------------------------
BOT_MAG.mac
----------------------------
This macro is configured for use by any melee class
Modify the BOT_CLS_CHARNAME.ini file for use by a specific toon
This was written ground up for usage with xiris's bots.
Usage: /mac bot_mag ${_tank1Name} ${_tank2Name} ${_healPoint} ${_assistArgs}
______________________________________________
REVISION HISTORY
11.16.10 xiris INITIAL REVISION using modified bot_nec
09.04.15 xiris Changed the variant_initialize to better handle the output from the loader
12.04.15 xiris Further modifications to variant_initialize
12.17.15 xiris Removed some extraneous /doevents calls
07.05.16 xiris Brought inline with latest events/assist calls
09.17.18 xiris Included ALL xiris bot libraries in common instead of in individual macros
04.05.22 xiris Added new Events aggregator and handlers
04.16.22 xiris Cleaned up some older code, normalized all vars/name
______________________________________________
REQUIRED PLUGINS
mq2cast
mq2eqbc
mq2debuffs
mq2moveutils
______________________________________________
REQUIRED INCLUDES
xiris_common/xiris_common.inc
**|
#include xiris_common/xiris_common.inc
#TURBO 120
#EVENT AEON "#*#aeNukeON"
#EVENT AEOFF "#*#aeNukeOFF"
Sub InitEvents_Class
/call RegisterClassEvents Events_MAG 2
/return
Sub Events_MAG
/doevents AEON
/doevents AEOFF
/return
Sub Main(string _tank1Name, string _tank2Name, string _tank3Name, int _healPoint, string _assistArgs)
/echo You are now in xiris_bot_${Me.Class.ShortName}.mac
|-- initialize the common xbot libraries
/call xbot_initialize ${_tank1Name} ${_tank2Name} ${_tank3Name} ${_healPoint} ${_assistArgs}
|-- initialize the macro specific libraries
/call variant_initialize
|-- report my status
/dgt [${Me.Class.ShortName}] ${Me.Name} ${str_action} >> ${Spawn[${_tank1Name}].CleanName} <<
|-- target the MT
/call TrueTarget ${int_MTID}
|**
----------------------------
Main Loop
----------------------------
Runs in order listed,
if adding any routine add the call here
----------------------------
**|
:MainLoop
/if (${Me.Hovering} || ${Window[tradewnd].Open} || ${Window[lootwnd].Open}) /goto :MainLoop
|-- Check all Events
/call RunAllEvents
|-- Check to make sure MT is still alive, if not, find another
/call chkMTAlive FALSE
|-- Check to see if self needs to be cured (xiris_curing.inc)
/call chkNeedCure
|-- Check Auto Assist if its on
/if (${bln_autoAssist}) /call chkAutoAssist
/if (${bln_engaged}) {
|-- check all events
/call RunAllEvents
|-- debuff lib
/if (${${DEBUFF_Total}}) /call chkDebuffsOnSingleTarget ${int_targetID}
|-- class specific
/if (${Pet.ID}) /call chkPetAttack
/if (${bln_cmbtBuffUse} && ${int_cmbtBuffTotal}) /call cmbtBuffMT
|-- dps library (AE caster)
/call chkNuke
/call chkAENuke
|-- std library (burns/aa/clicks)
/call RunRaidEvents
/call RunClassEvents
/call chkAA
/call chkBurn
/call chkClicky
|-- verify target status
/call chkTargetStatus
} else {
|-- check utilities, includes: sit,loot,leash (out of combat only) and only once every 10 seconds
/if (!${timer_check_utilities}) /call chkUtils
/if (!${timer_check_downshits}) /call chkDownshits
/if (!${timer_check_loot} && ${bln_looting}) /call chkLoot
}
|-- start again
/goto :MainLoop
/return
|**
----------------------------
Utility Checking
----------------------------
Checks the utilities such as fail states (GM, Lobby, etc)
Checks to see if we should med, loot, leash
note: these routines are defined in xiris_common for the most part
----------------------------
**|
Sub chkUtils
|-- Class Methods
/call chkPet
|-- Standard Methods
/call chkSit
/varset timer_check_utilities 20s
/return
Sub EVENT_AEON
/echo AE Nuking ACTIVE
/varset AENUKE_Active TRUE
/return
SUB EVENT_AEOFF
/echo AE Nuking DISABLED
/varset AENUKE_Active FALSE
/return
|**
----------------------------
INITIALIZATION Subs
----------------------------
Initialization of values for this specific macro variant
----------------------------
**|
Sub variant_initialize
|-- set up default vars
/declare str_action string outer Assisting
/memspellset ${str_spellset}
/echo \at${Me.Class.Name} Loaded: MT: ${str_MTName}(${int_MTID}) HealPoint:${healPoint} ST: ${str_STName}(${int_STID})
/call InitEvents_Class
/return