• Visit Rebornbuddy
  • Complex crafting profiles frequently "disconnect" the client

    Discussion in 'Rebornbuddy Support' started by ZaneMcFate, Mar 2, 2015.

    1. ZaneMcFate

      ZaneMcFate Member

      Joined:
      Nov 17, 2014
      Messages:
      137
      Likes Received:
      2
      Trophy Points:
      18
      I use the word "disconnect" here because the client literally does nothing. It appears to never know that the next step completed. It neither stops nor continues the bot. The problem seems to happen most often after Hasty Touch, though that could just be in my head. I have attached some of the runs where this has happened.

      I say complex profiles because I have used simpler crafting profiles with less if/whiles, and have never encountered this issue. Now that I am trying to incorporate advanced crafting logic for end-game recipes, I am regularly encountering this issue.

      I have attached the profile as well for reference. The section causing trouble is <!-- 80 dura, 586 progress = 4 star standard --> .
       

      Attached Files:

    2. mastahg

      mastahg Administrator Staff Member

      Joined:
      Feb 27, 2011
      Messages:
      4,755
      Likes Received:
      289
      Trophy Points:
      83
      Can you do

      Code:
      Log(CraftingManager.AnimationLocked);
      
      in the console when you encounter it locking up?
       
    3. mastahg

      mastahg Administrator Staff Member

      Joined:
      Feb 27, 2011
      Messages:
      4,755
      Likes Received:
      289
      Trophy Points:
      83
      So after looking at the profile and breaking it down, it looks like you're really pushing the limits of what the profile system is capable of.

      Code:
      					<LogMessage Message="4 star standard - Failure (Reclaim)"/>
      					<While Condition="True">
      						<!-- try to get CP to Reclaim, then Hasty Touch until failure -->
      						<While Condition="not Core.Me.HasAura(260)">
      							<If Condition="Core.Me.CurrentCP >= 55">
      								<CraftActionByName Name="Reclaim" />
      							</If>
      							<If Condition="CraftingManager.Condition == CraftingCondition.Good">
      								<CraftActionByName Name="Tricks of the Trade" />
      							</If>
      							<CraftActionByName Name="Hasty Touch" />
      						</While>
      						<CraftActionByName Name="Hasty Touch" />
      					</While>
      
      First the hasty touch issue. You've got that area wrapped in a while condition that will never break out. Basically at this point, the profile system keeps checking all the children over and over without clearing the memorycache because we assume that we will have something productive todo, if you put a logmessage or anything that will always run,it wouldn't happen(You'll still need to change that while loop condition to something else)

      Then the first logs issue:
      Code:
      				<LogMessage Message="4 star standard - Begin Block 2"/>
      				<!-- Second crafting block.  Get in as much quality as you can until durability is low enough to cast MMII. -->
      				<While Condition="CraftingManager.Durability > 10">
      					<!-- always cast ToT if possible -->
      					<If Condition="CraftingManager.Condition == CraftingCondition.Good">
      						<CraftActionByName Name="Tricks of the Trade" />
      					</If>
      					<!-- force loop if Crafting Condition is Good so ToT is cast -->
      					<While Condition="CraftingManager.Durability > 10 and not CraftingManager.Condition == CraftingCondition.Good">
      						<!-- keep Comfort Zone up -->
      						<If Condition="not Core.Me.HasAura(261)">
      							<CraftActionByName Name="Comfort Zone" />
      						</If>
      						<!-- keep Steady Hand II up -->
      						<If Condition="not Core.Me.HasAura(262)">
      							<CraftActionByName Name="Steady Hand II" />
      						</If>
      						<If Condition="Core.Me.HasAura(261) and Core.Me.HasAura(262)">
      							<CraftActionByName Name="Hasty Touch" />
      						</If>
      					</While>
      				</While>
      
      Same thing again almost, running a tight loop like that might result in the memory cache not being cleared, try sticking a logmessage or something in there.

      This system was designed to allow complex creations but you're really at the limit of what seems practical. I suggest instead you create a combatroutine and take advantage of synthsize ability to use a cr. Im thinking about ways to avoid this issue where while loops never release control but it will need a gentle touch as I don't want to go breaking anything.
       
    4. ZaneMcFate

      ZaneMcFate Member

      Joined:
      Nov 17, 2014
      Messages:
      137
      Likes Received:
      2
      Trophy Points:
      18
      You were right; adding a dummy log showed that it is getting confused in those tight loops, not actually freezing. It does look like a combat routine would be the best option; I think I'll go that route for my future high-end crafting :) Thank you for taking the time to look at this!
       

    Share This Page