ScriptUO

Official ScriptUO EasyUO Scripts => Submit your Script => Topic started by: sumsum on September 19, 2017, 11:03:28 AM

Title: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on September 19, 2017, 11:03:28 AM
UPDATED to 2.0

How to use:
Go to the big grassy spot and hit play. This script works best when there is a bigger spawn of snakes. You may want to work the spawn up if its low.
This script will work well and you can use it semi AFK

Updates:
Now auto sets hole location based on screen size. This will only work if you do not move your screen around. If the script is not clicking the hole, you may have to adjust where it clicks in the top of the script. PM me if you need help with this.

Now the script will loop 13 times and the walk back to the middle of the grassy spot. This stops the script from getting stuck at a hole that has not spawned all the way or spawned under brush or a cliff edge.  It DOES NOT remove that spot from the code so there's a chance you could walk back to that spot again. That's why this script is semi AFK.

Script no longer walk off screen for no reason.   

Farming eggs sucks. This will help!

Farms about 5 to 6 runs per 2 hours.

Good Luck. Please PM or post ideas.


Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: llamas_rule on September 27, 2017, 05:01:12 AM
Thanks for sharing this script! One problem I have is when I run it, it will walk to the nest, use flute, and then target the nest instead of targetting a snake first.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on September 27, 2017, 04:55:59 PM
Is it pulling the snakes health bar? Is there a snake on the screen? Let me know happy to help!
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on March 24, 2018, 12:36:04 PM
Updated
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: cybercasper on May 30, 2018, 07:19:18 AM
just tried this script out. so far not working as intended. it will walk to the first hole then it keeps cycling  through the mobs but never pick one or uses a flute
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on May 30, 2018, 04:40:49 PM
by chance are you using non exceptional flutes? I didn't think anyone would by them.. I'll upload a new copy now with non exceptional ones added!
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on May 30, 2018, 04:44:15 PM
Heres my ICQ if that doesnt work..413875533 I tough more people would use this script. But so far no luck!
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: The Ghost on May 30, 2018, 06:02:44 PM
I wanted to try it when u post it.  Sorry I forget about it.   I will set up one of my toon and test it.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: bendel on May 31, 2018, 03:29:23 AM
I tried it but without success, can't remember what was the problem.

I will set up character again when i have time :)
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on May 31, 2018, 06:39:50 PM
Thanks! It's definitely slower then doing it by hand, since it only sends one snake at a time. But I let it run for 2 hours or so and get about 30 eggs.

Key note: I set it up so it knows where the hole is based on your screen size. To do this make sure you screen is at 0x0 or the far left and very top or you can just change the x y in the script. I though it would be better then trying to get everyone to set the x y of the hole based on their screen settings.

Let know what you think.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Ghavall on July 24, 2018, 03:42:15 AM
it works for me. Slow... will mess up if no snakes on screen. ( it just stands there and loops forever). when that starts just have to move yourself to where there is snakes. Other than that works fine.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on July 25, 2018, 06:01:30 PM
Thanks, it is slow...Its best if there's snakes there already...if not in time they build up...I get about 30 eggs in an hour an half..It's just easy to run while I watch TV for guild hunts...

Thanks for the feed back!
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Oracle on March 06, 2020, 09:03:51 PM
Just wondering if this type of Script ever got finished...!
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on March 07, 2020, 05:46:23 AM
I use it. I just uploaded a new copy that I run that I have cut a few seconds of the time it takes to charm the snakes.

Here are the Issues with this type of script:

1. Holes spawn under brush.

2. Snakes Move off the screen as built in the the area of the game

3. Holes spawn on the other side of the rock wall, where you can see but cant pathfind to or under the rock ledge.

4. If you think it would be better, I can change the setup to select the hole on startup? right now it selects the hole based off screen size, but if you move you screen it will NOT select the hole. This can be fixed.

 Other then that if you start the scrip with a bunch of snakes on the screen it runs fine. I will run it for a couple hours and get 40 or 50 eggs and be set for the week of medusa solo runs. I do while I watch TV just in case something happens. I dont think it will get to 100% afk but its pretty good. I would be nice to run in enhanced razor for finding the hole but Pathfinding isnt working so well on that platforum yet.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Gaderian on March 07, 2020, 08:06:28 AM
I have only examined the latest one.

A few comments on the code:
You have repeat without an until in a few places. These isolated repeat statements do nothing functionally - possibly slow down the code a little if your #LPC setting is low enough.

You should restructure the routines so they have the opportunity to return cleanly. If you need to short cut back to the main loop, then provide a return status to determine the next goto statement instead of directly using a goto out of the sub.

Easyuo has a stack limit (I think it is 1000) for how many blocks it can keep track of. It is possible to get to enough to go over that limit. When that happens, scripts get into a non-responsive state. If you are only collecting for 2 hours with lots of snakes around, you are doing at most 4 per minute (a good cycle has more than 14 seconds of wait time), 240 per hour and 480 in 2 hours - maybe you don't get there. If there is a lack of snakes to charm, then it will take much less time to get to the unresponsive stack overflow state. Without the well structured subs it becomes very hard to read and follow what the script is doing.

Since I do not know the #sysmsg values, I can't figure out what happens after the sub flutechecker is called. I can't tell if it returns cleanly or builds the "gosub charm" on the stack?
I do not know if the remaining subs that process #sysmsg ever happen.

The hard coded click location could be determined using the variables for where the client window is placed (#clileft and #clitop) and even the offset could be calculated using the game window size (#clixres and #cliyres). This would improve the script so no matter the user's screen resolution, it would still target what I have to guess is near their character.

My example here assumes the original was 800x600 game window size. If it was something else then my math will need adjustments.
Code: easyuo
  1. ; At the start of the code create the X and Y offsets
  2. set %ClickXOffset #clixres / 2 + 14
  3. set %ClickYoffset #cliyres / 2 + 18
  4.  
  5. ; later in the Charm subroutine:
  6. ...
  7. gosub flutechecker
  8. set %ClickX #clileft + %ClickXoffset
  9. set %Clicky #clitop + %ClickYoffset
  10. click %ClickX %ClickY mc
  11. ...
  12.  
Generally players do not change the game window size while playing, but the game window could be adjusted depending on whether they want the banner menu (I forget what it's called). I have the menu sometimes to swap chat from Help to General when I am looking for something. Other times I want to move my screen layout for arranging icons or whatever - so I could see that changing. That just gives a more resilient way to handle the click locations for a variety of players.

Gaderian
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on March 07, 2020, 08:17:12 AM
Thank you for the input.

Im at best a D student when it comes to coding and just write scripts that I have a need for, otherwise Im pretty content with what everyone else has made. I can take your feed back and try and clean it up a bit. But I really just the guy that posted a way to click the holes....
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Nightsaber2000 on February 02, 2021, 12:20:54 AM
I checked this out, and it has a slight error where it gets stuck in a loop if certain conditions are/arent met, because grabber sub has no return. I have made some edits to make this run with magery to cure,heal,hide as needed with many checks in place. Id still be posting it with OP as author, just a tag at bottom that I edited it. Just dont wanna overstep and post when its not wanted.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: sumsum on February 02, 2021, 02:03:51 AM
Feel free to post it. I run a Separate script for cures and smoke bombs. If you are in a loop, walking or so on and get attacked it won't cure and hide till it goes back to the poison and visible check.
Thanks
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Nightsaber2000 on February 02, 2021, 07:25:39 AM
ok, im still tweaking it a bit, will post soon, i think you'll like the results.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: baldielocks on May 16, 2021, 06:16:28 PM
I have been trying to get this to work. I am using both version of the farmer posted.
Medusa egg farmer (newest).
Hit play, finds hole, walks to hole, uses flute, new target system reticule flashes around a bunch, then the cursor hangs and rarely selects a snake. When it does, it is almost always out of range. After this, the script always seems to select the same snake and the cursors hangs. When it DOES click the snake, then second target will just click a random spot on the ground.
Title: Re: Medusa Egg Farmer Stealth/Ninja
Post by: Gaderian on May 16, 2021, 06:29:36 PM
Do you have the "new target system" enabled? It relies on it, but doesn't set it to be active.