I've got me a problem i have writen one personalised script baset on yours, i did it for playing without quickspin and it worked perfectly.
but now i wanted to macke a copy of it but for quickspin instead and for some reason it skipps a step in the script?
what is the problem here, i cant figure it out^^
first script (working)
Code:
begin
Variable.Set("bet", "{MinimumBet}")
Function.Execute("Reset window location")
begin loop()
Function.Execute("Place bet")
Function.Execute("Check if we won")
if Variable.Is equal to("won", "yes")
begin
Macro.Report progress("We won! Resetting bet")
Variable.Set("bet", "{MinimumBet}")
end
if Variable.Is equal to("won", "no")
begin
Macro.Report progress("We lost! Doubling bet")
Variable.Multiply (Math)("bet", "2")
if Variable.Is greater than (Math)("bet", "{MaximumBet}")
begin
Macro.Report progress("Giving up and resetting bet")
Variable.Set("bet", "{MinimumBet}")
end
end
end
end
function("Reset window location")
begin
Window.Set location("PKR - let's play!", "yes", "1", "1")
Window.Bring to front("PKR - let's play!", "yes")
Macro.Pause("1000")
end
function
function("Place bet")
begin loop("{bet}")
Mouse.Move to coordinate("374", "434")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "100", "150")
Macro.Pause("{random}")
end
if Color.At coordinate is (RGB)("35", "3", "3", "371", "431")
begin loop("{bet}")
Mouse.Move to coordinate("374", "434")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "100", "150")
Macro.Pause("{random}")
end
begin
Variable.Set random number("random", "2000", "5000")
Macro.Pause("{random}")
Mouse.Move to coordinate("525", "726")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "1500", "2500")
Macro.Pause("{random}")
Mouse.Move to coordinate("525", "726")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "22000", "25000")
Macro.Pause("{random}")
end
function
function("Check if we won")
begin
Variable.Set("won", "no")
if Color.At coordinate is not within (RGB range)("2", "65", "64", "10", "989", "195")
begin
Variable.Set("won", "yes")
end
end
function
second script, quickspin (not working)
Code:
begin
Variable.Set("bet", "{MinimumBet}")
Function.Execute("Reset window location")
begin loop()
Function.Execute("Place bet")
Function.Execute("Check if we won")
if Variable.Is equal to("won", "yes")
begin
Macro.Report progress("We won! Resetting bet")
Variable.Set("bet", "{MinimumBet}")
end
if Variable.Is equal to("won", "no")
begin
Macro.Report progress("We lost! Doubling bet")
Variable.Multiply (Math)("bet", "2")
if Variable.Is greater than (Math)("bet", "{MaximumBet}")
begin
Macro.Report progress("Giving up and resetting bet")
Variable.Set("bet", "{MinimumBet}")
end
end
end
end
function("Reset window location")
begin
Window.Set location("PKR - let's play!", "yes", "1", "1")
Window.Bring to front("PKR - let's play!", "yes")
Macro.Pause("1000")
end
function
function("Place bet")
begin loop("{bet}")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Move to coordinate("374", "434")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "100", "150")
Macro.Pause("{random}")
end
if Color.At coordinate is (RGB)("35", "3", "3", "371", "431")
begin loop("{bet}")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Move to coordinate("374", "434")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "100", "150")
Macro.Pause("{random}")
end
begin
Variable.Set random number("random", "1000", "1500")
Macro.Pause("{random}")
Mouse.Move to coordinate("525", "726")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "1500", "2500")
Macro.Pause("{random}")
Mouse.Move to coordinate("525", "726")
Variable.Set random number("random", "50", "150")
Macro.Pause("{random}")
Mouse.Hold button("left")
Macro.Pause("100")
Mouse.Release button("left")
Variable.Set random number("random", "1000", "2000")
Macro.Pause("{random}")
end
function
function("Check if we won")
begin
Variable.Set("won", "no")
if Color.At coordinate is not within (RGB range)("2", "65", "64", "10", "989", "195")
begin
Variable.Set("won", "yes")
end
end
function
i meen it's virutualy the same script, why does one work and not the other?^^
here is the log
Log:
------------------------------------------------------------------------------
Started
Executing: Variable.Set(Variable name: bet, Value: {MinimumBet})
Error: A variable called MinimumBet, does not exist
Executing: Function.Execute(Name: Reset window location)
Executing: Window.Set location(Window ID/Title: PKR - let's play!, Exact match: yes, X Coordinate: 1, Y Coordinate: 1)
Executing: Window.Bring to front(Window ID/Title: PKR - let's play!, Exact match: yes)
Executing: Macro.Pause(Duration: 1000)
Executing: Function.Execute(Name: Place bet)
<--------------------------------------------------------------------------------------------------------------------here it skipps parts from the function "place bet"
Checking if: Color.At coordinate is (RGB)(R: 35, G: 3, B: 3, X coordinate: 371, Y coordinate: 431)
Result: No
Executing: Variable.Set random number(Variable name: random, From: 1000, To: 1500)
Executing: Macro.Pause(Duration: 1210)
Executing: Mouse.Move to coordinate(X Coordinate: 525, Y Coordinate: 726)
Executing: Variable.Set random number(Variable name: random, From: 50, To: 150)
Executing: Macro.Pause(Duration: 109)
Executing: Mouse.Hold button(Mouse Button: left)
Executing: Macro.Pause(Duration: 100)
Executing: Mouse.Release button(Mouse Button: left)
Executing: Variable.Set random number(Variable name: random, From: 1500, To: 2500)
Executing: Macro.Pause(Duration: 1896)
Executing: Mouse.Move to coordinate(X Coordinate: 525, Y Coordinate: 726)
Executing: Variable.Set random number(Variable name: random, From: 50, To: 150)
Executing: Macro.Pause(Duration: 112)
Executing: Mouse.Hold button(Mouse Button: left)
Executing: Macro.Pause(Duration: 100)
Executing: Mouse.Release button(Mouse Button: left)
Executing: Variable.Set random number(Variable name: random, From: 1000, To: 2000)
Executing: Macro.Pause(Duration: 1236)
Executing: Function.Execute(Name: Check if we won)
Executing: Variable.Set(Variable name: won, Value: no)
Checking if: Color.At coordinate is not within (RGB range)(R: 2, G: 65, B: 64, Range: 10, X Coordinate: 989, Y Coordinate: 195)
Result: Yes
Executing: Variable.Set(Variable name: won, Value: yes)
Checking if: Variable.Is equal to(Variable name: won, Value: yes)
Result: Yes
Executing: Macro.Report progress(Progress: We won! Resetting bet)
Executing: Variable.Set(Variable name: bet, Value: {MinimumBet})
Error: A variable called MinimumBet, does not exist
Checking if: Variable.Is equal to(Variable name: won, Value: no)
Result: No
Executing: Function.Execute(Name: Place bet)
Checking if: Color.At coordinate is (RGB)(R: 35, G: 3, B: 3, X coordinate: 371, Y coordinate: 431)
Result: No
Executing: Variable.Set random number(Variable name: random, From: 1000, To: 1500)
Executing: Macro.Pause(Duration: 1306)
Executing: Mouse.Move to coordinate(X Coordinate: 525, Y Coordinate: 726)
Executing: Variable.Set random number(Variable name: random, From: 50, To: 150)
Executing: Macro.Pause(Duration: 119)
Executing: Mouse.Hold button(Mouse Button: left)
Executing: Macro.Pause(Duration: 100)
Executing: Mouse.Release button(Mouse Button: left)
Executing: Variable.Set random number(Variable name: random, From: 1500, To: 2500)
Executing: Macro.Pause(Duration: 2445)
Executing: Mouse.Move to coordinate(X Coordinate: 525, Y Coordinate: 726)
Executing: Variable.Set random number(Variable name: random, From: 50, To: 150)
Executing: Macro.Pause(Duration: 56)
Executing: Mouse.Hold button(Mouse Button: left)
Executing: Macro.Pause(Duration: 100)
Executing: Mouse.Release button(Mouse Button: left)
Executing: Variable.Set random number(Variable name: random, From: 1000, To: 2000)
Executing: Macro.Pause(Duration: 1535)
Executing: Function.Execute(Name: Check if we won)
Executing: Variable.Set(Variable name: won, Value: no)
Checking if: Color.At coordinate is not within (RGB range)(R: 2, G: 65, B: 64, Range: 10, X Coordinate: 989, Y Coordinate: 195)
Result: Yes
Executing: Variable.Set(Variable name: won, Value: yes)
Checking if: Variable.Is equal to(Variable name: won, Value: yes)
Result: Yes
Executing: Macro.Report progress(Progress: We won! Resetting bet)
Executing: Variable.Set(Variable name: bet, Value: {MinimumBet})
Error: A variable called MinimumBet, does not exist
Checking if: Variable.Is equal to(Variable name: won, Value: no)
Result: No
Executing: Function.Execute(Name: Place bet)
Checking if: Color.At coordinate is (RGB)(R: 35, G: 3, B: 3, X coordinate: 371, Y coordinate: 431)
Result: No
Executing: Variable.Set random number(Variable name: random, From: 1000, To: 1500)
Executing: Macro.Pause(Duration: 1233)
Executing: Mouse.Move to coordinate(X Coordinate: 525, Y Coordinate: 726)
Executing: Variable.Set random number(Variable name: random, From: 50, To: 150)
Executing: Macro.Pause(Duration: 76)
Executing: Mouse.Hold button(Mouse Button: left)
Executing: Macro.Pause(Duration: 100)
Executing: Mouse.Release button(Mouse Button: left)
Executing: Variable.Set random number(Variable name: random, From: 1500, To: 2500)
Executing: Macro.Pause(Duration: 2119)
Aborted
------------------------------------------------------------------------------------
there is a error message that's coming up after i run it and ask if i want to se the log, so how do i make the program run the whole function?^^
P.S: i'm gonna modefy the first script to work for both later, but i'm still curius on what's wrong with this^^