SRL Archive - SRL Bugs

AveragePixelShift?


Valithor

2013-01-10 23:58:26

I don't think I've seen another thread on this, but it appears that AveragePixelShift isn't working for me. The function simply won't read any movement (or shifts in pixels). My Simba and SRL should be to date.

Here's the code I've been using.
program PrintMyPixels;
{$DEFINE SMART}
{$i SRL/srl.simba}

Procedure DebugShiftCount;
var
PBox: TBox;
begin
PBox := IntToBox(245, 130, 285, 195);
Writeln(IntToStr(AveragePixelShift(PBox, 250, 500)));
end;


begin
setupSRL;
Repeat
DebugShiftCount;
Until(False);
end.

My first thought was that the PBox was off because that bit of code was written by Flight (in his Tutorial) before EoC. So, I updated the box to:

PBox := IntToBox(230, 190, 275, 265);

The function still doesn't read any change in pixels even if you rotate the camera.
Any Thoughts?

riwu

2013-01-11 01:08:56

Are you on fixed screen min settings etc? Also is your Smart enabled, and the character is already animating when you run the script?

xtrapsp

2013-01-11 04:51:44

Doesn't sound like APS is bugged, it sounds like your simba is bugged.

Force update it all, Close and reopen and give it another go, make sure you have smart enabled etc

Valithor

2013-01-11 10:49:26

From: xtrapsp
Doesn't sound like APS is bugged, it sounds like your simba is bugged.


That did the trick! :) Reinstalled Simba, and there doesn't seem to be any problems now. Thanks for the help.