Repository navigation
Expand file tree
/
Copy pathCoreUpdate.cs
More file actions
53 lines (46 loc) · 1.59 KB
/
Copy pathCoreUpdate.cs
File metadata and controls
53 lines (46 loc) · 1.59 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
using System.Linq;
using ExileCore;
using ExileCore.PoEMemory.Components;
using ExileCore.PoEMemory.MemoryObjects;
// ReSharper disable ConstantConditionalAccessQualifier
namespace VmsHelper
{
public partial class VmsHelperCore : BaseSettingsPlugin<Settings>
{
private ActorVaalSkill UpdateVms()
{
return GetVaalSkill("vaal_molten_shell");
}
private ActorVaalSkill UpdateVaalHaste()
{
return GetVaalSkill("vaal_haste");
}
private ActorVaalSkill UpdateVaalGrace()
{
return GetVaalSkill("vaal_grace");
}
private ActorVaalSkill UpdateVaalD()
{
return GetVaalSkill("vaal_discipline");
}
private Life UpdateLifeComponent() => GameController?.Player?.GetComponent<Life>();
private Buffs UpdateBuffsComponent() => GameController?.Player?.GetComponent<Buffs>();
private ActorVaalSkill GetVaalSkill(string internalName)
{
var actorSkill = GameController
?.Player
?.GetComponent<Actor>()
?.ActorSkills
?.FirstOrDefault(s =>
s?.InternalName == internalName);
if (actorSkill?.IsOnSkillBar != true) return null;
var actorVaalSkill = GameController
?.Player
?.GetComponent<Actor>()
?.ActorVaalSkills
?.FirstOrDefault(s =>
s?.VaalSkillInternalName == internalName);
return actorVaalSkill;
}
}
}