Jump to content

Condition for Profession


nudl

Recommended Posts

Hey guys,

I am searching for a Profession Level Condition.

Like if Tailoring skill is =>100, then the quest is complete.

I searched for the *ObjectManager* but couldn't find what I am looking for. (I already thought about KnowsSpell, but that's too vague, as I need the exact level of skill.)

Could anybody help me out with this please? Thank you. :)

Link to comment
Share on other sites

This plugin reads profession level through Lua. You can check out the source code.

Here is the relevant C# code:

private void SetMiningSkill()
    {
        CurrentMining = Lua.LuaDoString<int>(@"
        miningSkill = 1;

        for i = 1, GetNumSkillLines() do
		    local skillName, isHeader, isExpanded, skillRank, numTempPoints, skillModifier = GetSkillLineInfo(i)
		    if isHeader and not isExpanded then
			    ExpandSkillHeader(i);
            end
        end
        

	    for i = 1, GetNumSkillLines() do
		    local skillName, isHeader, isExpanded, skillRank, numTempPoints, skillModifier = GetSkillLineInfo(i)
		    if not isHeader and skillName == ""Mining"" then
			    miningSkill = skillRank
		    end
	    end
        ", "miningSkill");
    }

 

Link to comment
Share on other sites

12 minutes ago, Matenia said:

...This plugin reads profession level through Lua. You can check out the source code.

Here is the relevant C# code..

 

That's a bit more complicated than I thought it would be. Nontheless I'll use what's possible.

Thank you for your fast answer, I'll definitely try to use this for me. I sure hope there will be an easier solution in the future.

Have a nice day.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...