ScriptUO

Official ScriptUO EasyUO Scripts => Script Library => Gold Farming => Topic started by: DeadIssue2 on June 17, 2009, 09:23:38 PM

Title: AFK Silver Farmer
Post by: DeadIssue2 on June 17, 2009, 09:23:38 PM
This is a simple script for farming silver with a hidden naked tamer. It will sit there while your Cu kills silver serpents in blighted. It will recognize if you are taking damage and send back silver and log out. It will log out if any of the named monsters are lured to your hunting grounds. It will check your weight and send silver when you get close to max weight. If you are out of powder it will refill your bag if you have more on you. It will even log you out before server down so you do not lose your pet for lack of loyalty.
Title: Re: AFK Silver Farmer
Post by: Cerveza on June 18, 2009, 05:18:34 AM
Cool script. Whenever I do math, I like to enclose it....
Code: [Select]
If #weight => #Maxweight -50
Code: [Select]
If #weight => ( #Maxweight - 50 )
That -50 might give you an issue.

I've migrated away from #findKind, and have been using #findCnt a lot more

Code: [Select]
If #findkind <> -1
Code: [Select]
If #findCnt > 0
For the BoS portion, TM has a great sub already available thats true tested to work excellent. You should consider using it.

I'm assuming that your char is hidden FAR away from any monster types... thats why you log out if one is spotted within 4 spaces of you?

Overall, looks pretty good. Consider the changes mentioned, and utilizing TM's BOS sub.
Title: Re: AFK Silver Farmer
Post by: DeadIssue2 on June 18, 2009, 05:33:06 AM
Thank you for the input , I had tested this thing left and right and was working properly until this morning when it went all wonky on me. These should fix the problem. I have it in testing for V2.0 right now
Title: Re: AFK Silver Farmer
Post by: rana70 on June 18, 2009, 07:48:23 AM
Hi,

I have to agree to Cerveza's comment about the weight issue.

Weight calculation is Shard and Race dependent:

Regular Shard:
-> HUMAN Char
Code: [Select]
   Set %MaxFreeLoad ( #MAXWEIGHT + 60 ) - #WEIGHT->Elf Char
Code: [Select]
   Set %MaxFreeLoad #MAXWEIGHT - #WEIGHT
SP Shard
-> Elf and Human Char
Code: [Select]
   Set %MaxFreeLoad #MAXWEIGHT - #WEIGHT
So I usually do a shard and a race check
when I have to worry about weight in a script.

cu
Title: Re: AFK Silver Farmer
Post by: DeadIssue2 on June 18, 2009, 08:28:18 AM
I have to be honest I do not understand how race or shard could effect weight as compared to max weight. I do understand how one race can hold more than another but not sure why that would matter. And I really did not know each shard could carry different weight max.

I have the changes in place and I am testing it now. This will be updated today.
Title: Re: AFK Silver Farmer
Post by: rana70 on June 18, 2009, 08:55:21 AM
..... I do not understand how race or shard could effect weight as compared to max weight.

Basicly it is all about to make sure a char is not becomming "overweighted",
in this state the char is unable to walk or recall.

So the calculations simply shows there is a difference in Race (humans and elfs) on regular shard,
this came up with the intruduction of the new elf race like the other differences Night Sight and stuff.

I am not sure why thy did not do this on SP in the same way, mybe someone else knows an answer.

I figured this out because a human char using one of my scripts on SP became overweighted ...
even when the same script on a regular shard never had this issue

cu
Title: Re: AFK Silver Farmer
Post by: Cerveza on June 18, 2009, 09:04:21 AM
The difference is that Humans can hold more weight before becoming overloaded. But... if your strength is high enough and your human, your PACK can't hold that much weight.

So waiting for you to be 50 under your maximum might not work if the char is a Human, because your pack won't support more then 100 under your maximum... it would cause a loop and the script would fail.

Lemme see if I have something already written....
Title: Re: AFK Silver Farmer
Post by: rana70 on June 18, 2009, 09:07:53 AM
This is what I use ....

in the scriptheader you have to call it ones with
GoSUB RANA_WeightCheck INIT
to get the basic data colected

Later just use it without parameter and you can use the vars
it provides in the comment part



Code: [Select]
; Char Weight Handling SUB
; Version 1.0
; %1 OPTION: INIT
;            Prepair Data for propper Weight Calculations
; Vars that can be used:
; %WC_RACE         -> HUMAN / ELF
; %WC_ServerTypeSP -> TRURE Server is Siege Perilous
; %WC_ServerName   -> Name of Server
; %WC_MaxFreeLoad  -> Max amount of stones before you overweighted
;------------------------ Routine -----------------------------
SUB RANA_WeightCheck %1
  Set !MODE %1
  ;Makre sure Data can be gathered
   if #MAXWEIGHT = N/A
    {
     Event Macro 8 2
     Wait %DelayEvent
     }
  ; INIT the WeightCheck and Collect needed Data
  if INIT in !MODE
   {
    Set %WC_RACE N/A
    Set %WC_ServerTypeSP #FALSE
    Set %WC_ServerName Regular
    ; Check out Race ELFs and Humans have differend weight limits
    FindItem #CHARID *
     if #FindType notin XU_AV
      Set %WC_RACE HUMAN
     if #FindType in XU_AV
      Set %WC_RACE ELF
    ; Check out Sever Name because SP has other Limits
    If Siege , #SPC , Perilous in #SHARD
     {
      Set %WC_ServerName SP
      Set %WC_ServerTypeSP #TRUE
     }
    ;Check Status of BackPack
    GoSUB RANA_ContainerItemCheck #BackPackID
    Set %WC_MaxFreeItems #RESULT
   }
   ; Calculate Weight Limits
   if HUMAN in %WC_RACE
    Set %WC_MaxFreeLoad ( #MAXWEIGHT + 60 ) - #WEIGHT
   if ELF in %WC_RACE || %WC_ServerTypeSP = #TRUE
    Set %WC_MaxFreeLoad #MAXWEIGHT - #WEIGHT
   ; Check if Data is in Range
   if %WC_MaxFreeLoad > 550
    Set %WC_MaxFreeLoad 550
   if %WC_MaxFreeLoad < 0
    Set %WC_MaxFreeLoad 0
RETURN
Title: Re: AFK Silver Farmer
Post by: Cerveza on June 18, 2009, 09:15:23 AM
Wow thats a lot of code there Rana....

Here's mine

Code: [Select]
set %backpackmaxweight 550
gosub fix_maxweight
set %maxweight #result


sub fix_maxweight
  if #maxweight = N/A
  {
    event macro 8 2
    wait 10
    event macro 10 2
  }
  set %_dummyvar #maxweight
  finditem #charid
  if #findtype notin AV_XU ; NOT ELF
    set %_dummyvar #maxweight + 60
  ;Backpack max
  if %_dummyvar > %backpackmaxweight
    set %_dummyvar %backpackmaxweight
return %_dummyvar
Title: Re: AFK Silver Farmer
Post by: rana70 on June 18, 2009, 09:25:44 AM
Cerveza you are true .. yours is much shorter...

This long and commented code is because I am a kind of noob with scipting
and I like to understand what I was doing .. and .. why I did what :-O)
I try to get regular stuff I do over and over in scripts ... into multi useable
SUBs .. and this Weigtht Handler is one of the results


But I guess yours will struggle on SP ...
a human on SP hasn't the + 60

DeadIssue2 sorry for spam your script thread ... but I am sure TM and Cerveza
will delete this for you :-)
cu

Title: Re: AFK Silver Farmer
Post by: Cerveza on June 18, 2009, 09:38:47 AM
NP Rana, my sub surely won't work on SP. I'll leave these posts as they are, great example of different coding trains of though. But if you look deeply, you see they are very similar at the core.

Hopefully DI2 has a clear understanding of what's going on. It's not about how much weight a char can carry, but how much weight the backpack will support. Chars now are capable of carrying more then the pack can hold LOL.
Title: Re: AFK Silver Farmer
Post by: DeadIssue2 on June 18, 2009, 02:27:04 PM
Thank you both so much don't delete a thing for a day or 2 I am finally understanding what your talking about (i think) and I wanna pick thru both codes you guys posted. And hell maybe someone else can learn at the same time.
Title: Re: AFK Silver Farmer
Post by: DeadIssue2 on June 20, 2009, 06:50:14 PM
Okay fixed the weight math and it runs like a charm. I will still work on the stuff that was mentioned as far as different shards go this coming week. But as is seems to work wonders for me. Farmed 80k silver in 1 night.
Title: Re: AFK Silver Farmer
Post by: madatu on February 27, 2011, 09:26:37 AM
Well i am new to farming silver.  I did as said and got my tamer to blighted grove. Was dressed. Does the silver fall into the pack? I didnt see anything on the bodies nor in my pack. I am in a faction. Well joined one today.
Title: Re: AFK Silver Farmer
Post by: Kalaka on February 27, 2011, 09:48:59 AM
Make sure you're not in TB, and in fel..
Title: Re: AFK Silver Farmer
Post by: madatu on February 27, 2011, 09:52:48 AM
I am in tb  why not TB ?
Title: Re: AFK Silver Farmer
Post by: NObama on February 27, 2011, 10:00:17 AM
Because you don't get silver for killing serpents if you are in TB.  Go read up on factions: http://www.uoguide.com/Factions
Title: Re: AFK Silver Farmer
Post by: madatu on February 27, 2011, 06:27:19 PM
Well thanks foir the info. I will have topwait three days to be able to leave the True Britanians. I was trying to join COM. Any idea where to join them. They have vendors in Moonglow but i didnt see a guild stone. After reading what you sent said Magantica but they town was destroyed a couple years ago. Sorry if i am a pain never got into factions.
Title: Re: AFK Silver Farmer
Post by: Hoby on February 27, 2011, 07:10:24 PM
the stone was moved to moonglow i believe. 
Title: Re: AFK Silver Farmer
Post by: madatu on March 03, 2011, 07:10:19 PM
ok finally got out of the TB took 3 days, I joined Minax. Still not getting silver. I am in fel Twisted weald killing silver serpants. No silver in pack nor the corpse. The silver serpants are in TB.
Title: Re: AFK Silver Farmer
Post by: Kalaka on March 04, 2011, 03:35:22 AM
Well the only other thing that could be now is if the Minax commanding lord has the tithe rate to 100%, which means it takes all your silver and gives it for leadership use.
Title: Re: AFK Silver Farmer
Post by: madatu on March 04, 2011, 03:51:54 AM
Are you serous? For crying out loud.
Title: Re: AFK Silver Farmer
Post by: madatu on March 04, 2011, 05:17:46 AM
Not sure what changed but it is giving me silver now. Thanks for your advice and guidance. Thanks for this script
Title: Re: AFK Silver Farmer
Post by: Kalaka on March 04, 2011, 05:46:51 PM
Could have been the tithe rate got adjusted.
Title: Re: AFK Silver Farmer
Post by: masteryoda on March 05, 2011, 11:33:40 AM
This script just tries to log out on me everytime i run it any ideas?
Title: Re: AFK Silver Farmer
Post by: Hollywood_Shono on April 18, 2011, 09:00:23 AM
Where are you starting it?
Title: Re: AFK Silver Farmer
Post by: Tidus on April 18, 2011, 02:04:06 PM
Any suggestions on a good place to leave your char while in blighted?  I jsut found i killed coil and then hid right where the silver serps spawn with my pet and i have no issue...  human hide...
Title: Re: AFK Silver Farmer
Post by: Amoskane1234 on August 14, 2018, 02:16:01 AM
This is a simple script for farming silver with a hidden naked tamer. It will sit there while your Cu kills silver serpents in blighted. It will recognize if you are taking damage and send back silver and log out. It will log out if any of the named monsters are lured to your hunting grounds. It will check your weight and send silver when you get close to max weight. If you are out of powder it will refill your bag if you have more on you. It will even log you out before server down so you do not lose your pet for lack of loyalty.
a
Title: Re: AFK Silver Farmer
Post by: Crisis on August 15, 2018, 08:00:41 PM
This is a simple script for farming silver with a hidden naked tamer. It will sit there while your Cu kills silver serpents in blighted. It will recognize if you are taking damage and send back silver and log out. It will log out if any of the named monsters are lured to your hunting grounds. It will check your weight and send silver when you get close to max weight. If you are out of powder it will refill your bag if you have more on you. It will even log you out before server down so you do not lose your pet for lack of loyalty.
a

Blind quoting will definitely get you unrestricted!  ::)
Title: Re: AFK Silver Farmer
Post by: onlyindreams on August 19, 2018, 08:22:40 AM
This is a simple script for farming silver with a hidden naked tamer. It will sit there while your Cu kills silver serpents in blighted. It will recognize if you are taking damage and send back silver and log out. It will log out if any of the named monsters are lured to your hunting grounds. It will check your weight and send silver when you get close to max weight. If you are out of powder it will refill your bag if you have more on you. It will even log you out before server down so you do not lose your pet for lack of loyalty.
a

Blind quoting will definitely get you unrestricted!  ::)

And on a 7+ year old thread about a game mechanic that no longer exists!