• Visit Honorbuddy
  • Visit Rebornbuddy
  • Visit Demonbuddy
  • Visit Exilebuddy
  • Visit Hearthbuddy
  • Visit Pokefarmer
  • Visit Buddystore

Writing Gathering Crew Skills Plugin

Discussion in 'Community Developer Forum' started by tsukasadt, Aug 8, 2017.

  1. tsukasadt

    tsukasadt Member

    Joined:
    May 7, 2015
    Messages:
    31
    Likes Received:
    0
    Trophy Points:
    6
    So, as the title suggests, I'm attempting to write a Gathering Crew Skills plugin. What it doesn't say is that I know next to nothing about C# and am failing miserably.

    To explain the situation, I'm trying to create a plugin to send predefined companions on gathering missions based on available skills and desired results. For example, if you are a non-subscriber and have a Consular (pre-KotFE) with the slicing skill, you'd have three dropdowns to identify which three crew members you want to send, three dropdowns listing the possible skill selections, and three dropdowns identifying the desired reward (i.e., Grade 9 Lockboxes, Grade 5 Sliced Tech Parts, etc.). There would also be logic to use the highest level missions to level the skill to the desired missions or, in the case of the Lockboxes which are limited to 2-per-grade, use the next grade down for a third.

    Problem is, I can't even get started with that if I can't detect what skills the player has available.

    I've tried what I thought was the correct way to do this by using:
    Code:
    ProfessionComponent.HasProfession(ProfessionType.Slicing)
    However, this errs:
    Code:
    An object reference is required for the non-static field, method, or property 'Buddy.Swtor.Objects.Components.ProfessionComponent.HasAnyProfession.get'
    I've no idea why. I can log the ProfessionType retrieving the Member Name and the Value, but it's erring when I plug it into the HasAnyProfession method and I don't understand C# anywhere near enough to know what I'm doing wrong.
     

Share This Page