Nils Posted November 3, 2011 Share Posted November 3, 2011 I wrote a small script to input arrows as they are shown on the screen Program DBSSS; var intX1:integer; intY1:integer; intColor:integer; intBackColor:integer; intFocusType:Integer; strMacroShards:string; strMacroShadow:string; strMacroFocus:string; Procedure Init; begin intX1:=405; intY1:=317; intColor:=3342336; intBackColor:=11974336; strMacroShards:='m'; strMacroShadow:='p'; strMacroFocus:='o'; intFocusType :=1; end; procedure Intypen; var intAantal:integer; intPijl:integer; begin For intAantal := 0 to 4 do begin If(GetColor(intX1 + intPijl ,intY1) = intColor) then begin SendArrow(2); end; If(GetColor(IntX1+5 + intPijl, intY1-6) = intColor) then begin SendArrow(1); end; If(GetColor(intX1 - 6 + intPijl, intY1 - 6) = intColor) then begin If(GetColor(intX1 -2 + intPijl, intY1- 1) = intColor) then begin SendArrow(3); end; end; If(GetColor(intX1 + intPijl, intY1- 11) = intColor) then begin If(GetColor(intX1 + 5 + intPijl,IntY1 - 6) = 0) then begin SendArrow(0); end; end; intPijl:=intPijl+16; end; end; Procedure Check; begin If not(GetColor(intX1+57, intY1-10) = intBackColor) then begin wait(500) SendKeys(strMacroFocus); Wait(1000) If intFocustype >= 1 Then begin SendArrow(2); Wait(300) end; If intFocustype >= 2 Then begin SendArrow(2); Wait(300) end; If intFocustype >= 3 Then begin SendArrow(2); Wait(300) end; If intFocustype >= 4 Then begin SendArrow(2); Wait(300) end; SendKeys(chr(13)); end; end; begin Init; Repeat Wait(1000) Intypen; Wait(300) Check; Until(False) end. It ran fine on 3 computers but on two others it did some strange stuff, It sent the commands to every window I clicked in, except for the one I had targeted, When I tried it there, it simply didn't do anything. I'm using the script for a game on BYOND Does anybody know what causes this? Thanks in advance, Nils Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 3, 2011 Share Posted November 3, 2011 Were there any differences between the computers? OS, resolution, color scheme... Quote Link to comment Share on other sites More sharing options...
Nils Posted November 3, 2011 Author Share Posted November 3, 2011 They were all running Windows 7 Color scheme and resolutions were different but I edited the variables so that should work Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 3, 2011 Share Posted November 3, 2011 Well, colors should be set to 32-bit, otherwise SCAR won't operate properly... Aside from that, it's hard to tell without actually being able to see the problem in action. Quote Link to comment Share on other sites More sharing options...
Nils Posted November 3, 2011 Author Share Posted November 3, 2011 Alright, I'll check if that fixes it Quote Link to comment Share on other sites More sharing options...
Neron Posted November 4, 2011 Share Posted November 4, 2011 Hmm, i run my scripts in 16 bit colors, less colors easy job. Is any problem with 16 bit? For now, script works fine. Quote Link to comment Share on other sites More sharing options...
FHannes Posted November 4, 2011 Share Posted November 4, 2011 Well, in theory SCAR only supports 32-bit, if it works, then there's no problem, but I can't make any guarantees... Quote Link to comment Share on other sites More sharing options...
Nils Posted November 5, 2011 Author Share Posted November 5, 2011 Nope changing color scheme doesn't work Quote Link to comment Share on other sites More sharing options...
ti.teg.tnod.I Posted November 5, 2011 Share Posted November 5, 2011 I'm going to move this to "Scripting help". Hopefully you'll get more support there. Quote Link to comment Share on other sites More sharing options...
VongolaXEspada Posted November 5, 2011 Share Posted November 5, 2011 (edited) I'm the person, he is trying to help setup this script on. We are doing it on TeamViewer and he's been trying to do it for the past 3 days but nothing has worked. I'm using an IMac 2011 27 inch with windows 7 64 bit running through bootcamp. Edit - Could maybe one the administrators help us through Teamviewer? There is Multi Client support on Teamviewer, so Nills can be in the session and so could one of your administrators. Edited November 5, 2011 by VongolaXEspada Quote Link to comment Share on other sites More sharing options...
Neron Posted November 5, 2011 Share Posted November 5, 2011 Diference from each computer is also clear type effect and other smuthing settings. Quote Link to comment Share on other sites More sharing options...