Author Topic: Mentor needed  (Read 5005 times)

0 Members and 1 Guest are viewing this topic.

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Mentor needed
« on: December 28, 2013, 05:01:17 PM »
0
Novice scripter looking to becoming adept. I have a bunch of crafting scripts that I want to finish but I am struggling with the move resources and the main crafting loop. I am hoping someone that is knowledgable might have some free time to explain the reasons for specific commands in a couple of scripts that I am learning from. I have learned a lot but I really want to understand some of the mechanics and commands better so I can finish some scripts that I am working on. Thanks for reading and let me know if you are interested in helping me understand better. Thanks!  ;D

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13303
  • Activity:
    0.4%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Mentor needed
« Reply #1 on: December 28, 2013, 05:32:40 PM »
0
Just try and post your questions and let us see what we can work through. 
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #2 on: December 28, 2013, 06:34:14 PM »
0
The problem is that I am learning from others scripts and I cannot ask my questions without posting parts of their scripts. I am looking to understand why they did certain things and what some of those things do.

Offline 12TimesOver

  • Another Day, Another Vendetta
  • Global Moderator
  • *
  • *
  • Posts: 3694
  • Activity:
    0%
  • Reputation Power: 41
  • 12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.12TimesOver is a force to reckon with.
  • Gender: Male
  • Respect: +321
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #3 on: December 29, 2013, 06:11:05 AM »
0
If you are just posting snippets of scripts with specific questions regarding their code that is different than posting another author's script without permission with the intention of people using it. Or, even worse, posting others work and claiming it as your own.

I starting learning the same way, going through other peoples scripts.

I say post questions with examples and if something goes too far then we'll deal with it.

X
When they come for me I'll be sitting at my desk
     with a gun in my hand wearing a bulletproof vest
My, my, my how the time does fly
     when you know you're gonna die by the end of the night

Offline _C2_

  • AFK FtW
  • Global Moderator
  • *
  • *
  • Posts: 4077
  • Activity:
    0%
  • Reputation Power: 48
  • _C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!_C2_ has great potential!
  • RIP Pen Trick
  • Respect: +254
  • Referrals: 4
    • View Profile
Re: Mentor needed
« Reply #4 on: December 29, 2013, 06:52:10 AM »
0
Yep, just don't claim it as your own and use snips and there is a crew here that can help for sure!

Offline Endless Night

  • Global Moderator
  • *
  • *
  • Posts: 5467
  • Activity:
    0%
  • Reputation Power: 62
  • Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!
  • Respect: +393
  • Referrals: 1
    • View Profile
Re: Mentor needed
« Reply #5 on: December 29, 2013, 07:18:05 AM »
0
ask and you shall be answered.
Outlaw Josey Wales - "Manwink, A Long Gone Scripty, and Endless are always teasing us with their private sections lol. What there realy saying is scripters rule and users drool."
Briza - "Your a living breathing vortex of usefulness."

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #6 on: December 29, 2013, 08:10:26 AM »
0
Ok this is from Paulonius' Bowyer Trainer 1.0 Script

I am looking at the main crafting section and I will be asking things on the side in red. I will also comment on what I think it means to see if I am understanding it correctly.

Code: [Select]
Sub CraftAway
CraftAwayLoop:
finditem %TinkerTools C_ , #backpackid
if #findcnt < 2
   gosub MakeTinkerKit
finditem %FletchersTools C_ , #backpackid
if #findcnt < 2
   gosub MakeFletchersTools
finditem %FletchersTools C_ , #backpackid
set #lobjectid #findid
event macro 17
gosub waitforgump %cwin
if ! #result
   {
   Goto CraftAwayLoop
   }
Set %Find%CurrentItemAttempts 0
Set %Find%CurrentItemAttemptsSuccess 0        ;;[color=red]I am not sure about these 3 lines, looks like code for a menu but maybe the script uses it to track other than real skill?[/color]
Set %NeedToResetCurrentItem No
REPEAT
      {
      finditem %FletchersTools C_ , #backpackid   ;;[color=red]If there aren't at least 2 fletcher kit it goes to the loop that tell is to make more kits[/color]
      If #findcnt < 2
         goto CraftAwayLoop
      chooseskill bowc real
      Set %CurrentSkill #Skill       ;;  [color=red]I believe this is so the script can reference which items to make[/color]
      Gosub OffSetClick 280 450      ; make last ;; [color=red] This confuses me, what if the last thing made was to low and it should have gone to something new?[/color]
      gosub waitforgump %cwin
      if ! #result                        ;;  [color=red]Checking to see if tool is still working?[/color]
         Goto CraftAwayLoop
      Finditem %CurrentItem C_ , #BackpackID              ;;  [color=red] I don't understand this. Is it looking for the item made in the bag? If so, why?[/color]
      Set %FindCurrentItemAttempts %FindCurrentItemAttempts + 1
      If #FindCnt >= 1
         {
         Set %FindCurrentItemAttemptsSuccess %FindCurrentItemAttemptsSuccess + 1  ;;  [color=red]I am confused on this to, is this and the previous one checking so it knows what to dump but I don't see a ref to weight. Does the weight sub run constantly and independently from the crafting sub?[/color]
         Gosub Dump
         }
      If %FindCurrentItemAttempts > 9 && %FindCurrentItemAttemptsSuccess < 1  ;;  [color=red]Does this mean it is going to go to a lower item regardless of skill since it made 9 without a success? Is this the reason for the lines at the beginning?[/color]
         Set %NeedToResetCurrentItem Yes
      Chooseskill Bowc real
      If Siege in #Shard && #Skill >= 700  ;;  [color=red]Siege ROT timer, completely understand this one, nice sub! EN's?[/color]
         {
         GoSub RoT_Timer Bowc
         finditem %FletchersTools C_ , #backpackid
         If #FindCnt < 1
            Goto CraftAwayLoop
         set #lobjectid #findid
         event macro 17
         }
      If #skill >= %threshhold || %NeedToResetCurrentItem = Yes
         gosub SkillCheck
      If #Skill = #SkillCap
         Gosub SkillCheck
      gosub weightcheck
      finditem %Boards C_ , #backpackid
      }
UNTIL #findstack < %ItemBoards  ;;  [color=red]board check? I don't think I have seen a check like this but is it referring to the stack being smaller than the amount needed to make the bow which is addressed in the item1 item2 section of the script?[/color]
Gosub OffsetClick 30 450  ;;  [color=red]Does this close out the crafting gump? If so, Why? So it can grab more boards?[/color]
Return
      

I really appreciate the help in understanding how these subs work so I can make my own.

After previewing it, I see that color is not taken in the code section but it will help make it easier to find my comments lol.

« Last Edit: December 29, 2013, 08:14:21 AM by Crisis »

Offline Tidus

  • Lazy
  • Administrator
  • *
  • *
  • Posts: 1291
  • Activity:
    0%
  • Reputation Power: 15
  • Tidus is working their way up.Tidus is working their way up.Tidus is working their way up.
  • Gender: Male
  • Mind Blown
  • Respect: +151
  • Referrals: 2
    • View Profile
    • Ultimate Apparel
Re: Mentor needed
« Reply #7 on: December 30, 2013, 01:50:00 PM »
0
I'll break down the code so as to answer each little bit.



Code: [Select]
Sub CraftAway
CraftAwayLoop:
finditem %TinkerTools C_ , #backpackid
if #findcnt < 2
   gosub MakeTinkerKit
finditem %FletchersTools C_ , #backpackid
if #findcnt < 2
   gosub MakeFletchersTools
finditem %FletchersTools C_ , #backpackid
set #lobjectid #findid
event macro 17
gosub waitforgump %cwin
if ! #result
   {
   Goto CraftAwayLoop
   }
Set %Find%CurrentItemAttempts 0
Set %Find%CurrentItemAttemptsSuccess 0        ;;[color=red]I am not sure about these 3 lines, looks like code for a menu but maybe the script uses it to track other than real skill?[/color]

He is setting Variables up to later be used in his script to define how many times it has attepted to do the items and how many times it was actually successful in making the item.

Code: [Select]
Set %NeedToResetCurrentItem No
REPEAT
      {
      finditem %FletchersTools C_ , #backpackid   ;;[color=red]If there aren't at least 2 fletcher kit it goes to the loop that tell is to make more kits[/color]

      If #findcnt < 2
         goto CraftAwayLoop

Yes, if there is less than 2 fletcher kits it goes back to the beginning of the sub to make new kits. There are different ways of doing this rather than using gotos but that will come with practice. Some of us don't like gotos. Some do.

Code: [Select]
      chooseskill bowc real
      Set %CurrentSkill #Skill       ;;  [color=red]I believe this is so the script can reference which items to make[/color]
      Gosub OffSetClick 280 450      ; make last ;; [color=red] This confuses me, what if the last thing made was to low and it should have gone to something new?[/color]


This part of the script is just for updating the current skill level prior to it making last so that it can see if you get a gain. That is all.

Code: [Select]

      gosub waitforgump %cwin
      if ! #result                        ;;  [color=red]Checking to see if tool is still working?[/color]
         Goto CraftAwayLoop

This is using a different sub to check for the gump. So unless the other sub is posted we cannot see what the #result means.

Code: [Select]
      Finditem %CurrentItem C_ , #BackpackID              ;;  [color=red] I don't understand this. Is it looking for the item made in the bag? If so, why?[/color]
      Set %FindCurrentItemAttempts %FindCurrentItemAttempts + 1
      If #FindCnt >= 1
         {
         Set %FindCurrentItemAttemptsSuccess %FindCurrentItemAttemptsSuccess + 1  ;;  [color=red]I am confused on this to, is this and the previous one checking so it knows what to dump but I don't see a ref to weight. Does the weight sub run constantly and independently from the crafting sub?[/color]
         Gosub Dump
         }
      If %FindCurrentItemAttempts > 9 && %FindCurrentItemAttemptsSuccess < 1  ;;  [color=red]Does this mean it is going to go to a lower item regardless of skill since it made 9 without a success? Is this the reason for the lines at the beginning?[/color]
         Set %NeedToResetCurrentItem Yes

The reason it has a finditem is to search for the item you are making to see if it successfully made the item. By it finding 1 or more, it knows that it was successful and it will udpate with how many are in the bag. Then it moves them using gosub dump and gets rid of the item in your backpack so it does not count it again.

I believe it will go to a lower level item. Not sure, it is based on how he wrote his other subs to determine the correct item.  Maybe you were using a bracelet before and then took it off and now you are below the minimum. It will make it update itself to do the correct item.
Code: [Select]
      Chooseskill Bowc real
      If Siege in #Shard && #Skill >= 700  ;;  [color=red]Siege ROT timer, completely understand this one, nice sub! EN's?[/color]
         {
         GoSub RoT_Timer Bowc
         finditem %FletchersTools C_ , #backpackid
         If #FindCnt < 1
            Goto CraftAwayLoop
         set #lobjectid #findid
         event macro 17
         }
      If #skill >= %threshhold || %NeedToResetCurrentItem = Yes
         gosub SkillCheck
      If #Skill = #SkillCap
         Gosub SkillCheck
      gosub weightcheck
      finditem %Boards C_ , #backpackid
      }
UNTIL #findstack < %ItemBoards  ;;  [color=red]board check? I don't think I have seen a check like this but is it referring to the stack being smaller than the amount needed to make the bow which is addressed in the item1 item2 section of the script?[/color]
Gosub OffsetClick 30 450  ;;  [color=red]Does this close out the crafting gump? If so, Why? So it can grab more boards?[/color]
Return
     

yes, that is saying that it will do the repeat until there are not enough boards to do the item.  So whatever %ItemBoards is set to it will not break out of it.  It is a different way of writing it, but it is effective.

I  am not sure what click is 30 450, but only way to close a gump is to make it do a right click.  So i am unsure of this click.

For those who have fought for it, freedom has a taste the protected will never know ~ Anonymous, Vietnam, 1968

Offline Endless Night

  • Global Moderator
  • *
  • *
  • Posts: 5467
  • Activity:
    0%
  • Reputation Power: 62
  • Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!
  • Respect: +393
  • Referrals: 1
    • View Profile
Re: Mentor needed
« Reply #8 on: December 31, 2013, 08:44:28 AM »
0
by the way this is an invalid variable name

Code: [Select]
Set %Find%CurrentItemAttempts 0
I think you meant

Code: [Select]
Set %FindCurrentItemAttempts 0
Note 2 % vs 1 %
Outlaw Josey Wales - "Manwink, A Long Gone Scripty, and Endless are always teasing us with their private sections lol. What there realy saying is scripters rule and users drool."
Briza - "Your a living breathing vortex of usefulness."

Offline dxrom

  • Master of the milestones!
  • Elite
  • *
  • *
  • Posts: 1080
  • Activity:
    0%
  • Reputation Power: 15
  • dxrom is working their way up.dxrom is working their way up.dxrom is working their way up.
  • KEYBOARD COWBOY, GREAT SAMURAI OF THE INTERNET.
  • Respect: +100
  • Referrals: 1
    • View Profile
Re: Mentor needed
« Reply #9 on: December 31, 2013, 08:11:30 PM »
0
fyi, cant do color codes in code box :>



 ​_██​_
(ಠ​_ృ)
I do say, ol' Chap! Come play EVE Online! Why here is a 21 Day Free Trial!

Offline TrailMyx

  • Officially retired from UO
  • Administrator
  • *
  • *
  • Posts: 13303
  • Activity:
    0.4%
  • Reputation Power: 154
  • TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!TrailMyx is awe-inspiring!
  • Gender: Male
  • Viper!
  • Respect: +1349
  • Referrals: 33
    • View Profile
    • ScriptUO
Re: Mentor needed
« Reply #10 on: December 31, 2013, 08:13:20 PM »
0
fyi, cant do color codes in code box :>

Welcome to the 1st disappointment of 2014.  ;)
Please read the ScriptUO site RULES
Come play RIFT with me!

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #11 on: January 01, 2014, 06:20:32 AM »
0
I have been looking at a lot of the crafting scripts out there and I see a lot of huge differences. Now a lot of them are more than a couple of years old and I understand that easyuo language allows for a different way of writing things but I am very thoroughly confused.

Some of them seem to have 2 crafting sections, similar to Paulonius. They have a crafting gump and a craftaway section. His script link http://www.scriptuo.com/index.php?topic=7555.0


Code: [Select]
sub SetBowyerGump
;event sysmessage in Set Gump. Item is %Item . %Skilllevel
If Siege in #Shard
   {
   chooseskill Bowc real
   Set %CurrentSkill #Skill
   }
finditem %Tinkertools C_ , #backpackid
if #findcnt < 1
   {
   display Get a tinker tool in your backpack and restart the script.
   halt
   }
if #findcnt < 2
   gosub MakeTinkerKit
finditem %FletchersTools C_ , #backpackid
if #findcnt < 2
   gosub MakeFletchersTools
CraftSetLoop:
finditem %FletchersTools C_ , #backpackid
set #lobjectid #findid
event macro 17
gosub waitforgump %cwin
if ! #result
   Goto CraftSetLoop
gosub offsetClick %xclick1 %yclick1
gosub waitforgump %cwin
if ! #result
   Goto CraftSetLoop
gosub OffsetClick %xclick2 %yclick2
gosub waitforgump %cwin
if ! #result
   Goto CraftSetLoop
If %xclick2 = 380
   {
   gosub OffsetClick %xclick3 %yclick3
   gosub waitforgump %cwin
   if ! #result
      Goto CraftSetLoop
   }
If Siege in #Shard && #skill >= 700
   {
   chooseskill Bowc real
   If %CurrentSkill < #Skill
      Gosub RoT_Timer Bowc
   }
Return

then the craftaway section

Code: [Select]
Sub CraftAway
CraftAwayLoop:
finditem %TinkerTools C_ , #backpackid
if #findcnt < 2
   gosub MakeTinkerKit
finditem %FletchersTools C_ , #backpackid
if #findcnt < 2
   gosub MakeFletchersTools
finditem %FletchersTools C_ , #backpackid
set #lobjectid #findid
event macro 17
gosub waitforgump %cwin
if ! #result
   {
   Goto CraftAwayLoop
   }
Set %Find%CurrentItemAttempts 0
Set %Find%CurrentItemAttemptsSuccess 0
Set %NeedToResetCurrentItem No
REPEAT
      {
      finditem %FletchersTools C_ , #backpackid
      If #findcnt < 2
         goto CraftAwayLoop
      chooseskill bowc real
      Set %CurrentSkill #Skill
      Gosub OffSetClick 280 450      ; make last
      gosub waitforgump %cwin
      if ! #result
         Goto CraftAwayLoop
      Finditem %CurrentItem C_ , #BackpackID
      Set %FindCurrentItemAttempts %FindCurrentItemAttempts + 1
      If #FindCnt >= 1
         {
         Set %FindCurrentItemAttemptsSuccess %FindCurrentItemAttemptsSuccess + 1
         Gosub Dump
         }
      If %FindCurrentItemAttempts > 9 && %FindCurrentItemAttemptsSuccess < 1
         Set %NeedToResetCurrentItem Yes
      Chooseskill Bowc real
      If Siege in #Shard && #Skill >= 700
         {
         GoSub RoT_Timer Bowc
         finditem %FletchersTools C_ , #backpackid
         If #FindCnt < 1
            Goto CraftAwayLoop
         set #lobjectid #findid
         event macro 17
         }
      If #skill >= %threshhold || %NeedToResetCurrentItem = Yes
         gosub SkillCheck
      If #Skill = #SkillCap
         Gosub SkillCheck
      gosub weightcheck
      finditem %Boards C_ , #backpackid
      }
UNTIL #findstack < %ItemBoards
Gosub OffsetClick 30 450
Return

The gump part seems to set up the initial clicks while the second part seems to actually craft the items using craft last item button. It also seems to keeping track of stuff but he has no menu so it must be an internal tracking.

XIIxover seems to have a simple and to the point craft section. Link to his here http://www.scriptuo.com/index.php?topic=1927.0

Code: [Select]
sub CartCraft
   repeat
      {
      repeat
         {
         finditem %BlankScrollTypes C_ , #BackPackID
         if #findkind = -1
            {
            gosub Restock %BlankScrollTypes %Secure %ScrollAmount
            if #RESULT = #FALSE
               {
               Display You seem to be out of scrolls. Please restock and Resume. Script Pausing!
               gosub Pause
               }
            }
      until #findkind <> -1

      repeat
         {
         finditem %PenTypes C_ , #BackPackID
         if #findkind = -1
            {
            gosub Restock %PenTypes %Secure 1
            if #RESULT = #FALSE
               {
               Display You seem to be out of Mapmaker Pens. Please restock and Resume. Script Pausing!
               gosub Pause
               }
            }
      until #findkind <> -1
      
      finditem %PenTypes C_ , #backpackid
      set #lobjectid #findid
      event macro 17
      gosub Gumpwait generic_gump generic_gump 530_497
      gosub ClickNWait 28 91 #TRUE generic_gump 530_497

      if %CurrentMap = LocalMap
         gosub ClickNWait 235 70 #FALSE
      if %CurrentMap = CityMap
         gosub ClickNWait 235 90 #FALSE
      if %CurrentMap = SeaChart
         gosub ClickNWait 235 110 #FALSE
      if %CurrentMap = WorldMap
         gosub ClickNWait 235 130 #FALSE
      if %CurrentMap = WallMapSouth
         gosub ClickNWait 235 150 #FALSE
      if %CurrentMap = WallMapEast
         gosub ClickNWait 235 170 #FALSE

      finditem %MapTypes C_ , #backpackid
      wait %sWait

      if #menubutton = Pause
         gosub Pause
      }
   until #findkind <> -1
return

Now the things he is crafting is all on the same page as cartography doesn't have to bounce around the menu much. You click maps then you have all the maps to make on that same page.

I have seen others where they do the crafting and telling the script what to use all in the same thing such as how Tidus did his - Snows scribeomatic  http://www.scriptuo.com/index.php?topic=10401.msg87010#msg87010

Code: [Select]
ub train
  if %currentskill <= 321
  {
    ;Poison
    if %iteration = 1
    {
      ;setup
      gosub MWResource %box %scroll N/A 10 50
      gosub MWResource %box %reagent3 N/A 10 50
      gosub getpen
      gosub MWCraft Scribe N/A 2 1 4
    }
    set %iteration %iteration + 1
    gosub MWResource %box %scroll N/A 10 50
    gosub MWResource %box %reagent3 N/A 10 50
    gosub getpen
    gosub MWCraft Scribe MakeLast
    gosub manacheck
    gosub weightcheck %spellscroll %box2
    if %currentskill = 322
    {
      gosub MWResource %box %scroll N/A 10 50
      gosub MWResource %box %reagent2 N/A 10 50
      gosub MWResource %box %reagent7 N/A 10 50
      gosub MWResource %box %reagent8 N/A 10 50
      gosub getpen
      gosub MWCraft Scribe N/A 2 2 6
      gosub manacheck
      gosub weightcheck %spellscroll %box2
    }
  }
  if %currentskill > 322 && %currentskill <= 578
  {
    ;Recall
    if %iteration = 1
    {
      ;setup
      gosub returnitems
      gosub MWResource %box %scroll N/A 10 50
      gosub MWResource %box %reagent2 N/A 10 50
      gosub MWResource %box %reagent7 N/A 10 50
      gosub MWResource %box %reagent8 N/A 10 50
      gosub getpen
      gosub MWCraft Scribe N/A 2 2 6
    }
    
    set %iteration %iteration + 1
    gosub MWResource %box %scroll N/A 10 50
    gosub MWResource %box %reagent2 N/A 10 50
    gosub MWResource %box %reagent7 N/A 10 50
    gosub MWResource %box %reagent8 N/A 10 50
    gosub getpen
    gosub MWCraft Scribe MakeLast
    gosub manacheck
    gosub weightcheck %spellscroll %box2
    
  }
  if %currentskill = 579
  {
    gosub MWResource %box %scroll N/A 10 50
    gosub MWResource %box %reagent2 N/A 10 50
    gosub MWResource %box %reagent7 N/A 10 50
    gosub MWResource %box %reagent8 N/A 10 50
    gosub getpen
    gosub MWCraft Scribe N/A 3 2 3
    gosub manacheck
    gosub weightcheck %spellscroll %box2
  }
  if %currentskill > 579 && %currentskill <= 864
  {
    ;Mark
    if %iteration = 1
    {

I am really confused on a solid way to write the crafting section. I also see some use namespace while others don't and I am not sure what namespace does.
« Last Edit: January 01, 2014, 06:24:55 AM by Crisis »

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #12 on: January 01, 2014, 06:26:16 AM »
0
fyi, cant do color codes in code box :>

Yeah I noticed that after I posted but it was hard to miss where I asked my questions with the unused colorcode wrapped around it.  ;D

Offline Endless Night

  • Global Moderator
  • *
  • *
  • Posts: 5467
  • Activity:
    0%
  • Reputation Power: 62
  • Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!Endless Night is awe-inspiring!
  • Respect: +393
  • Referrals: 1
    • View Profile
Re: Mentor needed
« Reply #13 on: January 05, 2014, 07:09:08 AM »
0
If you want to see a generic crafting set of subs.. check out my crafting subs in:

http://www.scriptuo.com/index.php?topic=10609.0
Outlaw Josey Wales - "Manwink, A Long Gone Scripty, and Endless are always teasing us with their private sections lol. What there realy saying is scripters rule and users drool."
Briza - "Your a living breathing vortex of usefulness."

Offline CrisisTopic starter

  • Global Moderator
  • *
  • *
  • Posts: 3022
  • Activity:
    3%
  • Reputation Power: 41
  • Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.Crisis is a force to reckon with.
  • Gender: Male
  • Scripting well enough to break things!
  • Respect: +206
  • Referrals: 2
    • View Profile
Re: Mentor needed
« Reply #14 on: January 05, 2014, 07:33:02 AM »
0
I will do that, thanks!  ;D

Tags: