Bully: Scholarship Edition

Bully: Scholarship Edition

(Servono più voti)
[AutoHotKey] Shop Class mouse movement script
Da Max Noskill
Autohotkey-script for passing that irritating Shop Class. Jimmy Hopkins wins again. As additional bonus script works for lock-picking!
   
Premio
Aggiungi ai preferiti
Preferito
Rimuovi dai preferiti
Foreword
Mouse and keyboard doesn't really work very well this game and I'm not getting XBOX360-controller adapter for just one game. So I scraped few things together from the Internets and *tadaa*, ladies and gents, here it is: Autohotkey-script for passing Shop Classes. And lock-picking!
Installing
You need AutoHotKey[ahkscript.org] program for this to work. If you don't know what it is, read about it first from the wikipedia[en.wikipedia.org]. It's free open-source program and safe to use.

1) Install AutoHotKey[ahkscript.org]. You can press YES when installer asks about default script, but if you install the default script, that one runs always when you open AHK from the start menu.
2) Copy the script from the next section and save it as bullymousescript.ahk to your home directory or desktop or anywhere where you find it.
3) Right-click bullymousescript.ahk and select Run Script
4) Check that it's working by pressing F1 and F2. Your mouse pointer should move. If you have something else bound on those keys, you need to change the keys in the script.
5) Start Bully: Scholarship edition
6) Go to the Shop Class and follow my instructions from Shop Class-section
Script code
So, I searched the internet and put together some bits and pieces. This was whipped up in half an hour and I haven't done much coding with AHK, so pardon me if code looks bad. :-)

Script works when you press F1 to go counter-clockwise direction (left) and F2 to go clockwise-direction (right). You can change the keys inside the script to whatever you want.

Just copy all of the code below and paste it to texteditor. Save it someplace you can find it easily as bullymousescript.ahk and you're done.

Easiest way to copy this is by selecting it carefully with mouse and just pressing Ctrl+C (copy) and paste it to editor (Ctrl+V). See that you copy ALL of script text and nothing is left out. If AHK is unhappy about the script, check again that you have all of the code. Especially check that { and } markings are in your copied code.

If you are having problems with windows notepad, I recommend Notepad++[notepad-plus-plus.org] which is also open-source and free.

CoordMode, Mouse, Screen SetDefaultMouseSpeed, 0 r = 25 2r := r * 2 + 1 r2 := r * r $F1:: Loop { MouseGetPos, a, b a := a - r Loop, % 2r { x := a + r - A_Index + 1 y := b - Round((r2-(x-a)**2)**0.5) MouseMove, x, y if not GetKeyState("F1", "P") break } Loop, % 2r { x := a - r + A_Index - 1 y := b + Round((r2-(x-a)**2)**0.5) MouseMove, x, y if not GetKeyState("F1", "P") break } return } $F2:: Loop { MouseGetPos, a, b a := a + r Loop, % 2r { x := a - r + A_Index - 1 y := b - Round((r2-(x-a)**2)**0.5) MouseMove, x, y if not GetKeyState("F2", "P") break } Loop, % 2r { x := a + r - A_Index + 1 y := b + Round((r2-(x-a)**2)**0.5) MouseMove, x, y if not GetKeyState("F2", "P") break } return }
Starting the script
How to start the script
Right-click on text file bullymousescript.ahk and you should see Run Script and start the script from there. AutoHotKey should appear as mini-icon.

How to check it's working
Check that it's working by pressing F1 and F2. Your mouse pointer should move on your desktop as long you press the key. If you have something else bound on those keys, you need to change the keys in my script.

Now you can start Bully: Scholarship Edition.

How to exit AHK
You can right-click AHK mini-icon and select Exit when you want to exit the AHK. This will stop the script and F1 and F2 works now normally.
Shop Classes
Best way to use the script is press scripted button BEFORE game tells you to do so. You need to hold scripted button down as long as game tells you to rotate the mouse.

Here's Shop Class button chart with default button setup. Study & memorize it and just press buttons in the correct order.

Example
Press the scripted button a moment before game tells you do so. For example when you arrive to the Class 1 and Jimmy is behind the bike, "Begin" text appears on screen. You can start pressing F2 right there. Hold the key down until the first step is over! When the first step is done, release F2. Mash down-button (S) when game tells you to do so in the second step. When that part is over, you can start holding F1 for the third step before the prompt appears. Congratulations, you passed Shop Class 1.

Shop Class 1
Progress
Button
Step 1
Rotate right (F2)
Step 2
Press down (S)
Step 3
Rotate left (F1)

Shop Class 2
Progress
Button
Step 1
Rotate right (F2)
Step 2
Press left (A)
Step 3
Press down (S)
Step 4
Rotate left (F1)

Shop Class 3
Progress
Button
Step 1
Rotate right (F2)
Step 2
Press down (S)
Step 3
Rotate right (F2)
Step 4
Press left (A)
Step 5
Rotate left (F1)

Shop Class 4
Progress
Button
Step 1
Rotate left (F1)
Step 2
Press down (S)
Step 3
Rotate right (F2)
Step 4
Press left (A)
Step 5
Press right (D)
Step 6
Rotate right (F2)

Shop Class 5
Progress
Button
Step 1
Press right (D)
Step 2
Press up (W)
Step 3
Rotate right (F2)
Step 4
Press down (S)
Step 5
Rotate left (F1)
Step 6
Press left (A)
Step 7
Press right (D)
Step 8
Rotate left (F1)
Links
Thanks
I would like to thank Oldman on some AHK-script site where google pointed out the most of the meat for the code. Saved me time to write this.

I would like to thank Rockstar Q&A department for failing PC-port testing so I can spend my spare gaming time efficiently.
22 commenti
Max Noskill  [autore] 26 dic 2021, ore 13:19 
@whitewood: script works but on 800x600 and r value of 10. :lunar2019grinningpig:

Game is really picky how large the circle is and how fast the rotation is.

Let's see if I can find better values and speed for larger resolutions, 25 was from 1080p I think.
Max Noskill  [autore] 26 dic 2021, ore 7:26 
@whitewood: Russell is done, Halloween pranks are over and Edna has ITS groceries, so this is slowly advancing... did also first part of classes to level five but I never remembered some of those were so hard. Got good laughs though. :lunar2019grinningpig:
whyteworth 26 dic 2021, ore 4:50 
Ah brilliant, thanks for your dedication, especially over Christmas! It seems to be in a perfect circular motion so it should work but haven't had the time to test it just yet.
Max Noskill  [autore] 26 dic 2021, ore 1:23 
@whitewood: I added circle offset to initial mouse position, does this help?

Unfortunately I have no saves so I really can't test this fast but it seems to work on lockpicking.

I'll let you know when I get to Shop Class part and see if it actually works.
Max Noskill  [autore] 25 dic 2021, ore 20:53 
@whitewood: ok, I had theory different resolution could be the cause but that's confirmed now.

I guess I'll install the game and see if I learn anything about the problem.
whyteworth 25 dic 2021, ore 14:02 
Still doesn't work with the same resolution. I test it on the desktop does the exact same rotation.
Max Noskill  [autore] 25 dic 2021, ore 8:14 
@whitewood: does the script work if you test the change the resolution to 1440p, just for testing?

Can't remember if game supports 1440p... or halve it to 720p (2* 720 = 1440)?
whyteworth 25 dic 2021, ore 7:07 
Turns out the game is 1080p with my monitor being 1440p. I'm guessing that's at fault here? Merry Christmas my friend!
Max Noskill  [autore] 24 dic 2021, ore 22:00 
@whitewood: ... should have asked earlier but what you can do if you just wake up and don't even have morning coffee before writing the answer.

What screen resolution do you use? Is desktop resolution and game resolution the same?
Max Noskill  [autore] 24 dic 2021, ore 21:09 
@whitewood: I haven't played the game in ages but if you do modifications to the script, please share so let's see if we can improve this. I think it worked quite well and other have said that too but AHK might have changed or something else will affect your mouse cursor position.

Happy Christmas and new year! :lunar2019piginablanket: