krycess
-
Posts
25 -
Joined
-
Last visited
Reputation Activity
-
krycess got a reaction from Droidz in Warrior Stances and Weapon Enhancements
these are mostly for my own reference but also for anyone who is looking to do the same things that I was trying to do.
these properties and methods assist in swapping warrior stances and checking for weapon enhancements such as poisons/oils/shaman enhancements etcetcetc
public static Task<bool> HasBattleStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(1);", "isActive") == 1); public static Task CastBattleStanceAsync() { Lua.LuaDoString("CastSpellByName('Battle Stance')"); return Task.CompletedTask; } public static Task<bool> HasDefensiveStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(2);", "isActive") == 1); public static Task CastDefensiveStanceAsync() { Lua.LuaDoString("CastSpellByName('Defensive Stance')"); return Task.CompletedTask; } public static Task<bool> HasBerserkerStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(3);", "isActive") == 1); public static Task CastBerserkerStanceAsync() { Lua.LuaDoString("CastSpellByName('Berserker Stance')"); return Task.CompletedTask; } public static Task<bool> HasMainHandEnhancement => Task.FromResult(Lua.LuaDoString<int>("result = GetWeaponEnchantInfo()", "result") == 1); public static Task<bool> HasOffHandEnhancement => Task.FromResult(Lua.LuaDoString<int>("_, _, _, result = GetWeaponEnchantInfo()", "result") == 1);
-
krycess got a reaction from TheSmokie in Warrior Stances and Weapon Enhancements
these are mostly for my own reference but also for anyone who is looking to do the same things that I was trying to do.
these properties and methods assist in swapping warrior stances and checking for weapon enhancements such as poisons/oils/shaman enhancements etcetcetc
public static Task<bool> HasBattleStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(1);", "isActive") == 1); public static Task CastBattleStanceAsync() { Lua.LuaDoString("CastSpellByName('Battle Stance')"); return Task.CompletedTask; } public static Task<bool> HasDefensiveStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(2);", "isActive") == 1); public static Task CastDefensiveStanceAsync() { Lua.LuaDoString("CastSpellByName('Defensive Stance')"); return Task.CompletedTask; } public static Task<bool> HasBerserkerStance => Task.FromResult(Lua.LuaDoString<int>("_,_,isActive,_ = GetShapeshiftFormInfo(3);", "isActive") == 1); public static Task CastBerserkerStanceAsync() { Lua.LuaDoString("CastSpellByName('Berserker Stance')"); return Task.CompletedTask; } public static Task<bool> HasMainHandEnhancement => Task.FromResult(Lua.LuaDoString<int>("result = GetWeaponEnchantInfo()", "result") == 1); public static Task<bool> HasOffHandEnhancement => Task.FromResult(Lua.LuaDoString<int>("_, _, _, result = GetWeaponEnchantInfo()", "result") == 1);