SRL Archive - OSR Help

MakeCompass Problem


jollyjumbuck

2010-04-15 06:04:00

Hi

I need to incorporate MakeCompass into a few of my scripts as they depend on the way the active screen is aligned when it starts but I just can't seem to get a reaction out of the MakeCompass procedure.

If I strip out everything else but MakeCompass (see below) I still get no change of the compass/screen angle. The script compiles ok and executes but with no change of angle direction.

Have I missed the point of what the procedure is supposed to do or have a I got something else simple wrong?

PS Am running the lastest version of Scar (3.22) and all the includes are updated on a daily basis with SVN.

Thanks for any advice.


Program MoveScreen1;
{.include SRL\SRL.Scar}

begin
SetUpSRL;
ActivateClient;
MakeCompass('w')
end.

Sex

2010-04-15 06:33:29

Try using SCAR 3.23. Checkout http://freddy1990.com/svn/scarprerelease.

jollyjumbuck

2010-04-15 11:05:26

Actually sorry am using 3.23. Had the problem on 3.22 but have been using the beta release for about a week.

Thx.

Sebo

2010-04-15 15:11:25

Try this:


Program MoveScreen1;
{.include SRL\SRL.Scar}

begin
SetUpSRL;
ActivateClient;
Wait(2000); // Before doing anything, lets make sure it did activate the client.
MakeCompass('W'); // Made it a capital W, not sure if that changes it.
end.

JPHamlett

2010-04-15 15:48:36

yay you need a wait time before makecompass I had this same problem a little while back

i luffs yeww

2010-04-15 19:28:04

If that doesn't work, try MakeCompass(270);.

jollyjumbuck

2010-04-16 19:11:00

Ok thanks for the suggestions.

Added the wait and also tried settling the angle by degrees as an alternative.

Still no error message - so is obviously recognizing the command but still getting no rotation either. Commands before and after the MakeCompass command will work fine.

Any other ideas??

Thx.

Sebo

2010-04-16 19:25:20

Are you installed the SRL SVN correctly? And is it updated to the latest version?
And did you move the plugin files correctly?

JPHamlett

2010-04-16 21:20:11

did you drag the crosshairs over the client?

i luffs yeww

2010-04-16 23:25:35

Also, try different angles. Make your compass directly north by hand, then run it and make it go south. Should work.

jollyjumbuck

2010-04-17 09:26:15

Sebo - yes using scar 3.23 and daily updates of SRL thru Tortoise SVN. Followed all installation instructions in the tut including moving the files to the right folders. Downloaded and installed again as a double check. Most other SRL functions are working fine.

Pizzle - yes correctly selected client window - as evidenced by the rest of the script functioning properly.

Yewws - had tried it from lots of angles.

Obviously something at my end given nobody else has a problem with it! :(

I have managed a temporary work around by Mouse clicking over the compass itself which resets it to North and then using
KeyDown(VK_Up); and
KeyDown(VK_Left); to adjust the direction
- although is a bit more cumbersome and not as accurate but can live with it….just would have been nice to get the proper functions included.

Will keep fiddling with it then and see if i can figure it out.

Cheers.

Frement

2010-04-17 09:28:56

I use this code to make it north and up:
ClickNorth( True );
SetAngle( True );

ZephyrsFury

2010-04-17 10:59:17

I'm getting the problem too. MakeCompass only works some of the time. Not sure why yet.

i luffs yeww

2010-04-17 14:02:39

It was happening for me when I was (attempting to) add ivy for Cohen. It seems as though it'd only not move it if the current angle was within the semi circle of the angle you're trying to achieve.

(In case that's not clear, what seems to have been happening to me was that if I was trying to do MakeCompass('E');, it'd only work if the compass was currently set to 271-359 degrees. If it was anywhere between north and south on the east side of the compass, it wouldn't work.)