Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cursor stuck on upper left corner of the screen #30

Closed
RandomFisher opened this issue Dec 11, 2014 · 67 comments
Closed

Cursor stuck on upper left corner of the screen #30

RandomFisher opened this issue Dec 11, 2014 · 67 comments
Labels

Comments

@RandomFisher
Copy link

Hi. I've been trying to make Fishbot working with no effect.

Every time I start the Fishbot, it casts fine. However after casting, the mouse cursor goes straight to the upper left corner of the screen and never moves. When I try to move the cursor, it goes back to the corner. As it doesn't try to search the bobber, it appears to do nothing after the splash but release the cursor to be able to move again.

Is there any solution?

@henrikhermansen
Copy link
Collaborator

@RandomFisher are you still having this issue? If so I can try to analyze this a bit more closely, but it does sound like an odd bug. Do you have a multi monitor setup btw?

@Huddo89
Copy link

Huddo89 commented Jan 15, 2015

My issue too. I do have multi monitor, playing vanilla wow. Cursor goes to top left of my right hand (main monitor) I have tried disconnecting my second monitor and restarting with just a single. I have also tried to play wow in my second monitor. Did have a load of mods including xperl, disabled all but to no effect

@Mograine
Copy link
Collaborator

Mograine commented Feb 1, 2015

Can you please re-try with the newest version since we re-coded the bobber finder ?

@henrikhermansen
Copy link
Collaborator

@RandomFisher @Huddo89

@Huddo89
Copy link

Huddo89 commented Feb 7, 2015

Still same issue, building new PC within the week with single GPU will test again. *Note playing vanilla wow

@Muffinek
Copy link

i have this problem too, cursor stuck in left top corner, I have only one monitor :/

@MeiHouwang
Copy link

I have the same problem, with cursor going straight to upper left corner. And I have one monitor too. Please fix it.

@gmillerd
Copy link

I am pretty sure you are in windowed mode, but maximized to full screen (no border). Try windowed mode and still be able to see the minimize/maximize/close buttons.

@vdanielpop
Copy link

Has anyone came up with a solution for this? I am running it with WoW 2.4.3, the casting works fine but the mouse goes up in the left corner and just stays there

OS: Windows 8.1
Resolution: 1366x768

EDIT: After a bit of debugging, I got to the GetWowRectangle() method in Win32.cs . For some reason, it doesn't find the window and the pointer that returns is 0, causing the mouse cursor to be stuck in the left corner.

EDIT2: Ok, so the problem was fixed partially, after I replaced
IntPtr Wow = FindWindow("GxWindowClass", "World of Warcraft");
with
IntPtr Wow = FindWindow(null, "World of Warcraft");

The next issue that appeared is that the cursor icon while you hover the bobber is different from the one you use in your app, looks like this. I'll try to find a workaround for this issue and will come back with comments later on.

@gmillerd
Copy link

gmillerd commented May 9, 2015

Need to be on the primary display as well, if you have multiple monitors have wow on the primary monitor.

The cursor doesnt matter, its looking for cursor changes so if a monster walks buy during the can it will grab it.

@vdanielpop
Copy link

I am playing on my laptop, so I only have one display.
And I am pretty sure the mouse cursor matters, otherwise, I don't see any way he can establish the initial position of the blobber while surfing the rectangle.

@gmillerd
Copy link

Sorry to hear that, I am sure there are a number of issues with this corner problem. I have a number of monitors and this application only works when the monitor is primary, the cursor always moves over to the primary corner if the window is moved to another monitor.

If you go to display properties and then identify, just make sure the monitor is "1" and not your external monitor if any. To be clear, if you are using another video port it may not be the primary.

On the cursor discussion, the cursor is moved across the window within the x,y x2,y2 area

Ever so often the cursorinfo is checked to see if it has changed, this rate of check is a configuration option.

The detection of the cursor changing is all that is looked for, it doesnt know what changed it, so for example if a enemy walks in the path of the cursor scan, the cursor would change from hand to sword (to attack) and the bobber would be though to have been detected ... and the cursor movement stops.

You can see this easily when you fish in mop areas with monsters on the water surface or when other players walk in front of your bobber.

This is exactly as described in the faq and how the application works in practice.

You can make it detect a bobber pretty easily if you just bring up your bags 'b' key infront of the cursor and it changes when looking at a item to use it.

@Crystalleaf
Copy link
Contributor

I have solved this problem with 2 changes.
I'm from China so my wow.exe is actually named 魔兽世界 and in this project it is written to be World of Warcraft.
So my solution is:

In the function SendMouseClick() in Classes\helpers\win32.cs
change the first line from
IntPtr Wow = FindWindow("GxWindowClass", "World Of Warcraft");
to
IntPtr Wow = FindWindow(null, "魔兽世界");

Second in the function SendMouseClick() in Classes\helpers\win32.cs
change the first line from
IntPtr Wow = FindWindow("GxWindowClass", "World Of Warcraft");
to
IntPtr Wow = FindWindow(null, "魔兽世界");

After this the program works great on my computer.
Thanks the author~!

@SoftwareGuyRob
Copy link

Thank you @Crystalleaf for your post.

I'm embarrassed to say that I never considered the name of the .exe being different!

@mullz0r
Copy link

mullz0r commented Jun 30, 2015

Guys.. I have this exact problem. My cursor gets stuck in the top-left part of the screen as the program tries to find the bobber. As I try to move the mouse it keeps moving itself to the top-left corner, so it's definitely doing something. It just doesn't seem to be able to move around inside the WoW window.

I'm a total noob when it comes to code, so I have no idea what Crystalleaf is talking about. Anyone fixed this problem and got a version that works that a noob like me can use?

@Formeszter
Copy link

Hey, Folks. I tried to fish with your bot, but I'm stuck with this problem too!
As far as I can tell I've tried it:

  • Fullscreen-Windowed(maxd)-Windowed(usual) none worked! (how to says make it window and shrink it, so regular windowed seems to work, but not for me!)
  • Several Cursos Findung settings from both low to both high, high-low and low-high and kinda all possible tries! (none worked)
  • Also tried to change code as Crystalleaf did. Re-did all my previous tries! (still not working)

Some other stuff I experienced. As I use latest version with the spiral route alt cursor finding, if that is checked the cursos stays out of game window (but finds it) like its stuck and the border of the window! If not checked it gets inside but stays where wants to stay.
Somehow I was able to move my mouse from tha starting point, but when casting starts again, it goes back! I tried to take mouse over blobber by hand and waited the bot to 'catch', but nothing happened! Not even heard it. So I started to check about sounding options.
I'm pretty sure others noticed that casting is also with sound (when string touches water it splashes too).
I started to look in the setting, which effect is louder... Well starting splash was usually just 2-3 point less then actual splash!
So I guess putting it the best amount would be hard.
I also tried to put the Delay After Cast timer as high as it cannot hear the start-splash but usually would start before actually catching anything...
After all this noobish tries i looked my Statistics and saw only fish not found numbers...
Can it happen for like it casts and then nothing happened? :S

I also did something that I don't know how, but the bot started to cast fishing so fast like a spammer, like 1cast/sec - If you know why this happened, please tell me!

If anybody wants to know I'm using Win 7 32bit system and playing on 1.12 patch.

So if anybody using the same OS / patch AND can share a working bot with setting via some download I'd appreciate it!

Sorry for the long post, but it is really annoying that I found a quite cool bot and its not working at all!!!

Thanks

@LaBlazer
Copy link
Collaborator

Can you try using the latest version with custom area selection? If that'll work for you, then we can be sure that there is a problem with the bot getting the wow window...

@Xeiro
Copy link

Xeiro commented Sep 26, 2015

Hello,

I have the same problem. When I download last version, I can not compile it in VS coz of 1 error.

CODE
1>MSBUILD : error : Fody: An unhandled exception occurred:
1>MSBUILD : error : Exception:
1>MSBUILD : error : Unknown custom metadata item kind: 7
1>MSBUILD : error : StackTrace:
1>MSBUILD : error : at Microsoft.Cci.Pdb.PdbFunction.ReadCustomMetadata(BitAccess bits)
1>MSBUILD : error : at Microsoft.Cci.Pdb.PdbFunction..ctor(ManProcSym proc, BitAccess bits)
1>MSBUILD : error : at Microsoft.Cci.Pdb.PdbFunction.LoadManagedFunctions(BitAccess bits, UInt32 limit, Boolean readStrings)
1>MSBUILD : error : at Microsoft.Cci.Pdb.PdbFile.LoadFuncsFromDbiModule(BitAccess bits, DbiModuleInfo info, IntHashTable names, ArrayList funcList, Boolean readStrings, MsfDirectory dir, Dictionary2 nameIndex, PdbReader reader) 1>MSBUILD : error : at Microsoft.Cci.Pdb.PdbFile.LoadFunctions(Stream read, Dictionary2& tokenToSourceMapping, String& sourceServerData, Int32& age, Guid& guid)
1>MSBUILD : error : at Mono.Cecil.Pdb.PdbReader.PopulateFunctions()
1>MSBUILD : error : at Mono.Cecil.Pdb.PdbReader.ProcessDebugHeader(ImageDebugDirectory directory, Byte[] header)
1>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ProcessDebugHeader()
1>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ReadSymbols(ISymbolReader reader)
1>MSBUILD : error : at Mono.Cecil.ModuleReader.ReadSymbols(ModuleDefinition module, ReaderParameters parameters)
1>MSBUILD : error : at Mono.Cecil.ModuleReader.CreateModuleFrom(Image image, ReaderParameters parameters)
1>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ReadModule(Stream stream, ReaderParameters parameters)
1>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ReadModule(String fileName, ReaderParameters parameters)
1>MSBUILD : error : at InnerWeaver.ReadModule() in c:\TeamCity\buildAgent\work\7495521761d392b9\FodyIsolated\ModuleReader.cs:line 14
1>MSBUILD : error : at InnerWeaver.Execute() in c:\TeamCity\buildAgent\work\7495521761d392b9\FodyIsolated\InnerWeaver.cs:line 28
1>MSBUILD : error : Source:
1>MSBUILD : error : Mono.Cecil.Pdb
1>MSBUILD : error : TargetSite:
1>MSBUILD : error : Void ReadCustomMetadata(Microsoft.Cci.Pdb.BitAccess)
1>MSBUILD : error :
1> Finished Fody 11ms.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
CODE

Can u help me LaBlazer pls?

@LaBlazer
Copy link
Collaborator

Are you compiling it with latest version of VS??

@Xeiro
Copy link

Xeiro commented Sep 27, 2015

Yes, I am - VS for comunity.

Odesláno z iPhonu

    1. 2015 v 17:53, LaBlazer notifications@github.com:

Are you compiling it with latest version of VS??


Reply to this email directly or view it on GitHub.

@LaBlazer
Copy link
Collaborator

I just tried to download the code and compiled it from scratch, and it worked without problems... It seems that the fody version is outdated...

@Xeiro
Copy link

Xeiro commented Sep 27, 2015

I will sound dumb, but what is Fody pls? ;)

Odesláno z iPhonu

    1. 2015 v 19:26, LaBlazer notifications@github.com:

I just tried to download the code and compiled it from scratch, and it worked without problems... It seems that the fody version is outdated...


Reply to this email directly or view it on GitHub.

@LaBlazer
Copy link
Collaborator

In short Fody is a dependency for Costura and Costura is package that embeds other dependencies as resources into application...

@LaBlazer
Copy link
Collaborator

try to compile it now, ive updated the dependencies...

@Xeiro
Copy link

Xeiro commented Sep 27, 2015

I just tried to compile lastes version and this is the result:

1>C:\Users\Xeiro\Desktop\UltimateFishbot-CSharp\UltimateFishBot\UltimateFishBot.csproj(212,5): error : This project references NuGet package(s) that are missing on this computer. Enable NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is ..\packages\Fody.1.26.1\build\Fody.targets.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

I do have enabled downloading of the missing packages.

@LaBlazer
Copy link
Collaborator

Yeah, it just happened to me too... i will repair it, but Im unable to run visual studio, because Im updating it from 2013 to 2015

@Xeiro
Copy link

Xeiro commented Sep 27, 2015

Ok, np. Anyway - i downloaded older version and used fix to recognize wow process (window). I used IntPtr Wow = FindWindow(null, "World of Warcraft");

So now It switch to wow and starts to find bobber. But my problem is, that it is not casting my fishing skill and if I cast it manually, it does not click when it should. So problem is, that it is not sending "key usage" to wow.

Any ideas pls?

@LaBlazer
Copy link
Collaborator

i dont know, try to running it as administrator

@Xeiro
Copy link

Xeiro commented Sep 27, 2015

Still the same problem.

@magnapeccatrix
Copy link

I have deleted my comments because no one is helping. We have sorted out the problem.

@LaBlazer
Copy link
Collaborator

Sorry, but I was busy with my school... Can you at least tell us how did you fix it??

@Lenni-s
Copy link

Lenni-s commented Nov 13, 2015

Windows 7 uses different then "GxWindowClass" class name. My local fix was to use null instead

@LaBlazer
Copy link
Collaborator

Can you then please download winlister (http://www.nirsoft.net/utils/winlister.html) and tell me what is your class name?

@Lenni-s
Copy link

Lenni-s commented Nov 29, 2015

GxWindowClassD3d

http://imgur.com/hqlaL9Q

@LaBlazer
Copy link
Collaborator

Thank you, i will try to fix it...

@wowkiller
Copy link

I just started playing vanilla wow and tried fishbot but I have the same issue, cursor hits the top left of the desktop and just stays there. Anyupdate on a fix for that? I have windows 7 installed and I am using a monitor connected (HDMI) to my Dell laptop. Thanks! I look forward to catching some tasty fish!

@wowkiller
Copy link

Is anyone able to use this on Windows 7 with Vanilla Wow and no problems?

@MonstaKilla
Copy link

I tested on WotLK client (probably works with TBC and vanilla too) replacing GxWindowClass with GxWindowClassD3d at SendMouseClick and GetWowRectangle and disabling Check Cursor Icon and works fine.
According to Winlister, Cata is GxWindowClass so you should have no problem there (probably the same with MoP,WoD). It has probably something to do with the graphical changes during Cata.
Since the icon for bobber mouseover was changed from gear cursor to hook cursor in Cata, having Check Cursor Icon option toggled on while using wotlk or lower will not work.
I tried replacing the .bmp file of the cursor in Resources folder but the mouse didn't stop neither. I tried many gear icons, even screenshotting the one in game (with highest quality) but didn't work. I guess it has something to do with the size of the icon since the method imageCompare checks first if the two images have the same height and width. I noticed that the hook icon has 35x35 but the gear icon i found on WowWiki had 32x32 (screenshotted icon had 28x28 which is a bit odd). It would probably work if someone got the actual image from game data files.

If you have wotlk version or lower just download the newest version of the Fishbot, correct the code lines I mentioned above and toggle off Check Cursor Icon in the settings (don't forget to manually set the scanning area in the settings, the searching is much more efficient if you select the area well). If you have Cata or higher, your problem should be solved by tweaking the Settings.

@evilpookie
Copy link

Thanks for your input MonstaKilla, Downloading VSC now, I'm also having the cursor issue. I'll let you know if i can confirm

Running Vanilla WoW 1.12.1 x32 bit Client
Windows 10

@evilpookie
Copy link

Update*

Following your steps provided Fishbot is working as intended, besides the Anti-AFK function, it crashes the bot every time.

@Dudein
Copy link

Dudein commented Mar 22, 2016

Hi guys! :)

I have currently more than lost my mind trying to get this to work...

those thingies you talk about chaning, how and where do i find them to be exact?

If you could specify exactly how, and maybe a path for us (aparently retardos) that would be great!

@Hexenbane89
Copy link

So, anyone solved problem with left corner of the screen ?

@StefanZivanovic
Copy link

Hello, i made Github account to ask you. I'm having same problem. I'm don't have skills and i don't know anything about coding. Can someone help me with this by simple download and anything like that? Thanks

@Gasur Gasur mentioned this issue Apr 29, 2016
@MetaverseJosh
Copy link

Having same issue, has anyone found a fix that doesn't require recompiling stuff? I don't know jack about code and compiling. Can someone just upload a fixed version if you have it working?

@raaloid
Copy link

raaloid commented Nov 24, 2016

http://www.filedropper.com/fishbot

i compiled it with the necessary changes, re-uploaded...

it's latest version (as of 11/24/2016)

@Gromgar
Copy link

Gromgar commented Dec 9, 2016

@raaloid

Unfortunately, your compiled version doesn't work for current Legion patch, cursor is still stuck on top left of screen.

@dissonanceoflove
Copy link

how does this filedropper work? Same problem w10, 1.12.1 client , 1 monitor

@dissonanceoflove
Copy link

MonstaKilla? can you please explain how to edit the prgram in VSC?

@hezt
Copy link

hezt commented Jan 7, 2018

@Crystalleaf 多谢多谢!

@ilikefish
Copy link

I'm having the exact issue as well. I've tried the latest download, from here: https://github.com/UltimateFishbot/UltimateFishbot/releases/tag/Fishbot-4.0.36

Cursor just sit in the top left hand corner.

I only have the one monitor, I'm on a private server - tbc - 2.4.3.
If you need any more information, let me know.

@braczy
Copy link

braczy commented Mar 13, 2018

All, I found the issue. Leaving the code exactly as it is for US/ENGLISH versions, the task manager name of the application for WoW.exe is World of Warcraft. This also can be seen in the properties of the executable. The code in the Win32.cs file has two functions:

public static Rectangle GetWowRectangle()
IntPtr Wow = FindWindow("GxWindowClass", "World Of Warcraft");

This fails because of the capital "O" for Of. Changing this to lowercase "o" allows the wow window to be found by the fishingbot and the cursor to begin searching within it.

As well as in the function:

public static void SendMouseClick()
IntPtr Wow = FindWindow("GxWindowClass", "World of Warcraft");

Corrected: IntPtr Wow = FindWindow("GxWindowClass", "World of Warcraft");

After changing these, I rebuilt, published, and executed and works like a charm!

Hope this helps the developer and others!

@dissonanceoflove
Copy link

so braczy could you pls explain me in layperson language how you "changed, rebuilt, published, and executed"? I really want to fish bro pls.
<3

@pgarrett1121
Copy link

Based on @daniel-widrick's work in March / April 2018, it looks like he resolved this issue. Is this newest version available for download somewhere?

@daniel-widrick
Copy link
Collaborator

I haven't seen any movement from the original dev in awhile:
https://github.com/daniel-widrick/UltimateFishbot/releases

@pgarrett1121
Copy link

pgarrett1121 commented Jul 31, 2018 via email

@NaNraptor
Copy link
Collaborator

Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests