forked from Luricz285/GoS
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRyze.lua
More file actions
244 lines (192 loc) · 8.11 KB
/
Ryze.lua
File metadata and controls
244 lines (192 loc) · 8.11 KB
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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
if GetObjectName(GetMyHero()) ~= "Ryze" then return end
require('Inspired')
require('DeftLib')
require('DamageLib')
AutoUpdate("/D3ftsu/GoS/master/Ryze.lua","/D3ftsu/GoS/master/Ryze.version","Ryze.lua",11)
local RyzeMenu = MenuConfig("Ryze", "Ryze")
RyzeMenu:Menu("Combo", "Combo")
RyzeMenu.Combo:Boolean("Q", "Use Q", true)
RyzeMenu.Combo:Boolean("W", "Use W", true)
RyzeMenu.Combo:Boolean("E", "Use E", true)
RyzeMenu.Combo:Boolean("R", "Use R", true)
RyzeMenu:Menu("Harass", "Harass")
RyzeMenu.Harass:Boolean("Q", "Use Q", true)
RyzeMenu.Harass:Boolean("W", "Use W", true)
RyzeMenu.Harass:Boolean("E", "Use E", true)
RyzeMenu.Harass:Slider("Mana", "if Mana % is More than", 30, 0, 80, 1)
RyzeMenu:Menu("Killsteal", "Killsteal")
RyzeMenu.Killsteal:Boolean("Q", "Killsteal with Q", true)
RyzeMenu.Killsteal:Boolean("W", "Killsteal with W", true)
RyzeMenu.Killsteal:Boolean("E", "Killsteal with E", true)
RyzeMenu:Menu("Misc", "Misc")
if Ignite ~= nil then RyzeMenu.Misc:Boolean("Autoignite", "Auto Ignite", true) end
RyzeMenu.Misc:Boolean("Seraph", "Use Seraph", true)
RyzeMenu.Misc:KeyBinding("Passive", "Auto Stack Passive (toggle)", string.byte("N"), true)
RyzeMenu.Misc:Slider("Mana", "Minimum Mana %", 50, 0, 100, 1)
RyzeMenu.Misc:Slider("PStacks", "Max Stacks To Maintain", 2, 0, 4, 1)
RyzeMenu:Menu("LaneClear", "LaneClear")
RyzeMenu.LaneClear:Boolean("Q", "Use Q", true)
RyzeMenu.LaneClear:Boolean("W", "Use W", true)
RyzeMenu.LaneClear:Boolean("E", "Use E", true)
RyzeMenu.LaneClear:Slider("Mana", "if Mana % is More than", 30, 0, 80, 1)
RyzeMenu:Menu("JungleClear", "JungleClear")
RyzeMenu.JungleClear:Boolean("Q", "Use Q", true)
RyzeMenu.JungleClear:Boolean("W", "Use W", true)
RyzeMenu.JungleClear:Boolean("E", "Use E", true)
RyzeMenu:Menu("Drawings", "Drawings")
RyzeMenu.Drawings:Boolean("Q", "Draw Q Range", true)
RyzeMenu.Drawings:Boolean("WE", "Draw W+E Range", true)
RyzeMenu.Drawings:Boolean("Passive", "Draw AutoStack Stat", true)
OnDraw(function(myHero)
local pos = GetOrigin(myHero)
if RyzeMenu.Drawings.Q:Value() then DrawCircle(pos,900,1,25,GoS.Pink) end
if RyzeMenu.Drawings.WE:Value() then DrawCircle(pos,600,1,25,GoS.Yellow) end
if RyzeMenu.Drawings.Passive:Value() then
local drawPos = WorldToScreen(1,GetOrigin(myHero))
if RyzeMenu.Drawings.Passive:Value() then
DrawText("Auto Stack : ON",20,drawPos.x,drawPos.y,0xff00ff00)
else
DrawText("Auto Stack : OFF",20,drawPos.x,drawPos.y,0xffff0000)
end
end
end)
local PassiveEndTime = 0
local PStacks = 0
local IsEmpowered = false
local target1 = TargetSelector(900,TARGET_LESS_CAST_PRIORITY,DAMAGE_MAGIC,true,false)
local target2 = TargetSelector(600,TARGET_LESS_CAST_PRIORITY,DAMAGE_MAGIC,true,false)
OnTick(function(myHero)
local slot = GetItemSlot(myHero,3040)
local Qtarget = target1:GetTarget()
local Wtarget = target2:GetTarget()
if IOW:Mode() == "" and RyzeMenu.Misc.Passive:Value() and PStacks < RyzeMenu.Misc.PStacks:Value() and GetPercentMP(myHero) >= RyzeMenu.Misc.Mana:Value() then
local timeRemaining = PassiveEndTime - GetGameTimer()
if timeRemaining < 0.5 then
CastSkillShot(_Q,GetMousePos())
end
end
if IsReady(slot) and RyzeMenu.Misc.Seraph:Value() then
local threshold = math.huge
do
local totalHP = 0
local totalDamage = 0
for _, enemy in pairs(GetEnemyHeroes()) do
if ValidTarget(enemy,600) then
totalHP = totalHP + GetHP(enemy)
totalDamage = totalDamage + GetBonusAP(enemy) + (GetBaseDamage(enemy)+GetBonusDmg(enemy)) * GetAttackSpeed(enemy)
end
end
threshold = totalHP / totalDamage
end
local shield = 150 + GetCurrentMana(myHero) * 0.2
local HP = GetHP(myHero)
local damage = GetBonusAP(myHero) * (1 + (GetBonusAP(myHero)/100)) + (GetBaseDamage(myHero)+GetBonusDmg(myHero)) * GetAttackSpeed(myHero)
if threshold > HP / damage and (threshold < (HP + shield) / damage) then
CastSpell(slot)
end
end
if IOW:Mode() == "Combo" then
local qcost, wcost, ecost = 40, GetCastLevel(myHero,_W) * 10 + 50, GetCastLevel(myHero,_E) * 10 + 50
if RyzeMenu.Combo.R:Value() and ValidTarget(Wtarget, 600) and GetCurrentMana(myHero) > qcost + wcost + ecost then
if GetHP(Wtarget) > getdmg("Q",Wtarget)+getdmg("W",Wtarget)+getdmg("E",Wtarget) then
CastSpell(_R)
else
for _, enemy in pairs(GetEnemyHeroes()) do
if GetNetworkID(enemy) ~= GetNetworkID(Wtarget) and ValidTarget(enemy,950) then
CastSpell(_R)
end
end
end
end
if IsReady(_W) and ValidTarget(Wtarget, 600) and RyzeMenu.Combo.W:Value() then
CastTargetSpell(Wtarget, _W)
end
if IsReady(_E) and ValidTarget(Wtarget, 600) and RyzeMenu.Combo.E:Value() then
CastTargetSpell(Wtarget, _E)
end
if IsReady(_Q) and RyzeMenu.Combo.Q:Value() then
Cast(_Q,Qtarget)
end
if IsReady(_Q) and RyzeMenu.Combo.Q:Value() and IsEmpowered or (PStacks > 3) then
Cast(_Q,Qtarget,myHero,1700,0.25,900,55,3,false)
end
end
if IOW:Mode() == "Harass" and GetPercentMP(myHero) >= RyzeMenu.Harass.Mana:Value() then
if IsReady(_W) and ValidTarget(Wtarget, 600) and RyzeMenu.Harass.W:Value() then
CastTargetSpell(Wtarget, _W)
end
if IsReady(_E) and ValidTarget(Wtarget, 600) and RyzeMenu.Harass.E:Value() then
CastTargetSpell(Wtarget, _E)
end
if IsReady(_Q) and RyzeMenu.Harass.Q:Value() then
Cast(_Q,Qtarget)
end
if IsReady(_Q) and RyzeMenu.Harass.Q:Value() and IsEmpowered or (PStacks > 3) then
Cast(_Q,Qtarget,myHero,1700,0.25,900,55,3,false)
end
end
for i,enemy in pairs(GetEnemyHeroes()) do
if Ignite and RyzeMenu.Misc.Autoignite:Value() then
if IsReady(Ignite) and 20*GetLevel(myHero)+50 > GetHP(enemy)+GetHPRegen(enemy)*3 and ValidTarget(enemy, 600) then
CastTargetSpell(enemy, Ignite)
end
end
if IsReady(_Q) and ValidTarget(enemy, 900) and RyzeMenu.Killsteal.Q:Value() and GetHP2(enemy) < getdmg("Q",enemy) then
Cast(_Q,enemy)
elseif IsReady(_W) and ValidTarget(enemy, 600) and RyzeMenu.Killsteal.W:Value() and GetHP2(enemy) < getdmg("W",enemy) then
CastTargetSpell(enemy, _W)
elseif IsReady(_E) and ValidTarget(enemy, 600) and RyzeMenu.Killsteal.E:Value() and GetHP2(enemy) < getdmg("E",enemy) then
CastTargetSpell(enemy, _E)
end
end
if IOW:Mode() == "LaneClear" then
for _,mobs in pairs(minionManager.objects) do
if GetTeam(mobs) == 300 then
if IsReady(_W) and RyzeMenu.JungleClear.W:Value() and ValidTarget(mobs, 600) then
CastTargetSpell(mobs, _W)
end
if IsReady(_Q) and RyzeMenu.JungleClear.Q:Value() and ValidTarget(mobs, 900) then
CastSkillShot(_Q,GetOrigin(mobs))
end
if IsReady(_E) and RyzeMenu.JungleClear.E:Value() and ValidTarget(mobs, 600) then
CastTargetSpell(mobs, _E)
end
end
if GetTeam(mobs) == MINION_ENEMY and GetPercentMP(myHero) >= RyzeMenu.Harass.Mana:Value() then
if IsReady(_W) and RyzeMenu.LaneClear.W:Value() and ValidTarget(mobs, 600) then
CastTargetSpell(mobs, _W)
end
if IsReady(_Q) and RyzeMenu.LaneClear.Q:Value() and ValidTarget(mobs, 900) then
CastSkillShot(_Q,GetOrigin(mobs))
end
if IsReady(_E) and RyzeMenu.LaneClear.E:Value() and ValidTarget(mobs, 600) then
CastTargetSpell(mobs, _E)
end
end
end
end
end)
OnUpdateBuff(function(unit,buff)
if unit == myHero then
if buff.Name == "ryzepassivestack" then
PStacks = buff.Count
PassiveEndTime = buff.ExpireTime
end
if buff.Name == "ryzepassivecharged" then
IsEmpowered = true
end
end
end)
OnRemoveBuff(function(unit,buff)
if unit == myHero then
if buff.Name == "ryzepassivestack" then
PStacks = 0
end
if buff.Name == "ryzepassivecharged" then
IsEmpowered = false
end
end
end)
AddGapcloseEvent(_W, 600, true, RyzeMenu)
PrintChat(string.format("<font color='#1244EA'>Ryze:</font> <font color='#FFFFFF'> By Deftsu Loaded, Have A Good Game ! </font>"))
PrintChat("Have Fun Using D3Carry Scripts: " ..GetObjectBaseName(myHero))