• Visit Rebornbuddy
  • First Profile, Second Set of Eyes?

    Discussion in 'Community Developer Forum' started by anavidfan, Dec 9, 2015.

    1. anavidfan

      anavidfan New Member

      Joined:
      Dec 2, 2015
      Messages:
      19
      Likes Received:
      1
      Trophy Points:
      0
      Hey folks,

      Started work with Jonb1982 to build an all-in-one Red Scrip crafting scrip that could later be expanded to blue scrips. Plus, it could also build a nice repository of files for re-use in other projects.

      The goal is once a week, you run this, it gathers the required mats and crafts the required items to get 450 red tokens. While not wholly necessary (many of the sub-steps exist as profiles), it's a good exercise and I feel like I'm learning a lot more about RB while being able to leverage existing profiles to make progress.

      That said, if anyone more familiar with profiles doesn't mind taking a look, I'd love a second opinion on whether this file is going the right direction.

      File Structure (May help understand placeholder code in document)

      Main Folder
      RebornBuddy/Profiles/Red Scrip/Configuration.xml
      Sub Gather Folder
      RebornBuddy/Profiles/Red Scrip/Gathering/Adamantite_Ore.xml
      RebornBuddy/Profiles/Red Scrip/Gathering/Birch_Log.xml
      etc...
      Sub Crafting Folder
      RebornBuddy/Profiles/Red Scrip/Crafting/Rotations/1_Star.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Rotations/40_Durability.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Rotations/80_Durability.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Blacksmith/Adamantite_Nugget.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Blacksmith/Adamantite_Rivet.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Carpenter/Birch_Lumber.xml
      RebornBuddy/Profiles/Red Scrip/Crafting/Carpenter/Birch_Composite_Bow.xml
      etc...

      My current draft of the configuration file is attached, but here are some snippets to preview the current logic.

      <!-- Put Quantity Next to items you want to make -->
      <!ENTITY Griffin_Talon_Needle "0">

      This leads to here in the profile:

      <If Condition="&Griffin_Talon_Needle; !=0">
      <Exlog Color="#FFC0CB" Name="Red Scrip Profile" Message="Proceeding to gather and make Griffin_Talon_Needle"/>
      <RunCode Name=Dismount"/>
      <If Condition="ItemCount(14) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Fire_Cluster_Gather"/> </If>
      <If Condition="ItemCount(8) &lt. (&Griffin_Talon_Needle * 5)"> <RunCode Name="Fire_Crystal_Gather"/> </If>
      <If Condition="ItemCount(16) &lt. (&Griffin_Talon_Needle * 2)"> <RunCode Name="Wind_Cluster_Gather"/> </If>
      <If Condition="ItemCount(10) &lt. (&Griffin_Talon_Needle * 10)"> <RunCode Name="Wind_Crystal_Gather"/> </If>
      <If Condition="ItemCount(12577) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Griffin_Talon_Gather"/> </If>
      <If Condition="ItemCount(12538) &lt. (&Griffin_Talon_Needle * 5)"> <RunCode Name="Adamantite_Ore_Gather"/> </If>
      <If Condition="ItemCount(5121) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Darksteel_Ore_Gather"/> </If>
      <If Condition="ItemCount(12539) &lt. (&Griffin_Talon_Needle * 3)"> <RunCode Name="Cloud_Mica_Gather"/> </If>
      <If Condition="ItemCount(12579) &lt. (&Griffin_Talon_Needle * 5)"> <RunCode Name="Birch_Log_Gather"/> </If>
      <If Condition="ItemCount(12526) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Adamantite_Nugget_Craft"/> </If>
      <If Condition="ItemCount(12583) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Birch_Lumber_Craft"/> </If>
      <If Condition="ItemCount(12561) &lt. (&Griffin_Talon_Needle * 1)"> <RunCode Name="Cloud_Mica_Whetstone_Craft"/> </If>
      <If Condition="ItemCount(11894) &lt. (&Griffin_Talon_Needle)"> <RunCode Name="Griffin_Talon_Needle_Craft"/> </If>
      </If>

      Which runs various code chunks, allowing the profile to be a bit leaner. Since most of the red scrip items call on a subset of gathered items, it seems like an easy way to minimize copy/paste. Each code chunk would look like....

      <CodeChunk Name="Griffin_Talon_Gather">
      <![CDATA[ var Path = "Profiles/Gathering/Battle/Griffin_Talon_Gather.xml";
      ff14bot.RemoteWindows.CraftingLog.Close();
      await Buddy.Coroutines.Coroutine.Sleep(1000);
      NeoProfileManager.Load(Path, true);
      NeoProfileManager.UpdateCurrentProfileBehavior();
      ]]>
      </CodeChunk>

      Leading to an .xml file that does the appropriate crafting or gathering.

      A short list of what I know would need to be improved:
      • Prioritization of gathering within IF statements (aka gather Adamantite when it's up vs. Fire Shards which are always available).
      • Work on a way to programmatically generate code chunks
      • I'm developing a template for the gathering files -- change class, teleport (if necessary), go to area (if necessary), gather (these will be short since IF statements will do loops as appropriate until you have enough)
      • Within template, I'll surf the forums to minimize the amount of raw data collection for each mat that I need to do.
      • Jonb1982 is working on the crafting logic
      • So much more, but it's kind of fun!

      Worth noting I don't have access to the game this week, otherwise I'd be further along. My next step is to build out logic for (1) each item and start seeing where the profile breaks.

      Thanks in advance!
       

      Attached Files:

      y2krazy likes this.
    2. anavidfan

      anavidfan New Member

      Joined:
      Dec 2, 2015
      Messages:
      19
      Likes Received:
      1
      Trophy Points:
      0
      I already see a broken path (according to what I outlined above) in the code chunk, but those are placeholders anyway for now. Ultimately this profile would have a name and it'd be calling folders within that sub-folder. Hopefully enough to illustrate the point for now.
       
    3. tishat

      tishat Member

      Joined:
      May 29, 2015
      Messages:
      735
      Likes Received:
      7
      Trophy Points:
      18
      I gotta say love that it's being split up, looks pretty interesting =)
       

    Share This Page