PDA

View Full Version : Lape Reflection Include



Kyle
01-20-2015, 02:11 PM
Lape Reflection



If you feel so inclined to donate towards the development of both the include and the updater, please do so:

https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif (https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9GBUW5VMNL2RN)


The Lape version on Reflection is being completely maintained and develouped constantly, and is the main include, as the new SRL for old school runescape will be using lape soley as well. This include can be used standalone, or alongside with Aerolib.

The link for the include is at https://github.com/Elfyyy/OSR-Reflection and in order to use it and allow it to auto update, you will need a SSL supporting plugin, called prosocks https://github.com/Brandon-T/ProSocks/releases/download/v0.5/ProSocks.dll

Once both of those are downloaded, extract the include to Simba/Includes/, renaming it to just "reflection" and place the prosocks.dll in Simba/Plugins.

It is included by:{$i Reflection/Reflection.simba}
Always ensure that you call the setup as follows:

Reflect.Setup;

sportsguy217
01-20-2015, 08:31 PM
So do we delete the the reflection folders in simba\includes\aerolib\reflection and simba\includes\srl-OSR\srl\reflection? or just the one under SRL?


Another way I could put this: when the include is updated like this, are we supposed to replace every folder with the name 'reflection' this new update?

Fitta
01-20-2015, 09:20 PM
So do we delete the the reflection folders in simba\includes\aerolib\reflection and simba\includes\srl-OSR\srl\reflection? or just the one under SRL?


Another way I could put this: when the include is updated like this, are we supposed to replace every folder with the name 'reflection' this new update?

Reflection is supposed to be put in
Includes/Reflection/

It is NOT inside the aerolib folder anymore.

rj
01-20-2015, 09:34 PM
Can we use SetUpReflection instead of Reflect.Setup;, vice versa? both compile but IDK if both work

Kyle
01-20-2015, 09:59 PM
So do we delete the the reflection folders in simba\includes\aerolib\reflection and simba\includes\srl-OSR\srl\reflection? or just the one under SRL?


Another way I could put this: when the include is updated like this, are we supposed to replace every folder with the name 'reflection' this new update?

To expand on what Fitta said. You shouldn't ever have to change the folder again, as it will stay as it is now forever. Lape include is now in Includes/ and PascalScript version is still in Includes/SRL-OSR/SRL


Can we use SetUpReflection instead of Reflect.Setup;, vice versa? both compile but IDK if both work

SetupSrl points to Reflect.Setup; SetupReflection; will eventually be removed so it's best to just use Reflect.Setup;

rj
01-20-2015, 11:51 PM
To expand on what Fitta said. You shouldn't ever have to change the folder again, as it will stay as it is now forever. Lape include is now in Includes/ and PascalScript version is still in Includes/SRL-OSR/SRL



SetupSrl points to Reflect.Setup; SetupReflection; will eventually be removed so it's best to just use Reflect.Setup;

Ok, and to be clear all objects have to be initiated before they can be properly used right?

Eg TInventoryInvItem.find must be called before click, etc etc

akarigar
01-21-2015, 12:15 AM
Ok, and to be clear all objects have to be initiated before they can be properly used right?

Eg TInventoryInvItem.find must be called before click, etc etc


Yes, you're correct. Objects needs to be properly initialized before they can be used.

For details on how to properly use non static functions, refer to the Basic Lape Reflection Tutorial (https://villavu.com/forum/showthread.php?t=111664) in the Tutorials (https://villavu.com/forum/forumdisplay.php?f=659) section.

Shatterhand
02-12-2015, 11:00 PM
Nice! Gonna try this out soon. Lape is new to me though. :)

kingarabian
02-12-2015, 11:12 PM
Nice! Gonna try this out soon. Lape is new to me though. :)

Same here, but it's really similar. As soon as reflection is updated!!

slipper14
02-22-2015, 05:43 AM
Just followed the exact steps listed and still getting

Error: File "SRL-OSR/SRL/Reflection/Reflection.simba" not found at line 7
Compiling failed.

MonsterMashPublicV1.10.simba

Myke
02-22-2015, 05:46 AM
Just followed the exact steps listed and still getting

Error: File "SRL-OSR/SRL/Reflection/Reflection.simba" not found at line 7
Compiling failed.

MonsterMashPublicV1.10.simba


did you have the reflection.simba file at that directory?

you can change the path at top of script to go where u have the reflection include

Kyle
02-24-2015, 03:43 AM
Just followed the exact steps listed and still getting

Error: File "SRL-OSR/SRL/Reflection/Reflection.simba" not found at line 7
Compiling failed.

MonsterMashPublicV1.10.simba

That is the Pascal script version that the script is looking for. You installed the Lape version

Czepa
02-28-2015, 02:03 PM
Error: File "Reflection/Reflection.simba" not found at line 4
tavarly chaos druid collector. reflection.simba is in: C:\Simba\Includes\OSR-Reflection
ill post back an edit if i can fix it
EDIT: and the solution is naming the folder 'reflections' instead

EDIT2: it seems this is a problem common to the last OSR reflections update: Error: Unknown declaration "GetGlobalTile" at line 1368
something about the actor script. I hope this helps

Athylus
03-08-2015, 05:08 PM
Whenever I bot for a while I get this error, but honestly have no idea what it is...

Acces violation at line 153.


function TReflectionSmart.GetFieldInt(Ref: Integer; Hook: THook): Integer;
begin
Result := SmartGetFieldInt(Reflect.Smart.Target, Ref, Hook.Path) * Hook.Multi;
end;

What does this mean? It loses the smart target or something?

Kyle
03-08-2015, 05:25 PM
Whenever I bot for a while I get this error, but honestly have no idea what it is...

Acces violation at line 153.


function TReflectionSmart.GetFieldInt(Ref: Integer; Hook: THook): Integer;
begin
Result := SmartGetFieldInt(Reflect.Smart.Target, Ref, Hook.Path) * Hook.Multi;
end;

What does this mean? It loses the smart target or something?

What script are you using? Never seen an access violation there before, but Lape has really bad error messages so I wouldn't be surprised if it was from something going out of range, or it could be referencing a null pointer.

Athylus
03-08-2015, 05:43 PM
What script are you using? Never seen an access violation there before, but Lape has really bad error messages so I wouldn't be surprised if it was from something going out of range, or it could be referencing a null pointer.

I am using my own made script, it's happened a couple of times. I'll try to see when exactly it happens. The script stops (as in, I have to press the green button again) and it 'disconnects' from smart.

Kyle
03-08-2015, 06:51 PM
I am using my own made script, it's happened a couple of times. I'll try to see when exactly it happens. The script stops (as in, I have to press the green button again) and it 'disconnects' from smart.

Yeah then I'd definitely say that you are trying to access a object reference that either is null or has already been freed.

Unfold
04-05-2015, 05:18 PM
Error: Access violation at line 66
Execution failed.
The following DTMs were not freed: [0]
The following bitmaps were not freed: [0, 1, 2, 3, 4, 5

I get that whenever I use the function .WaitWhileMoving or even .IsAnimating.

flamingo1
04-08-2015, 08:05 PM
Error: Access violation at line 66
Execution failed.
The following DTMs were not freed: [0]
The following bitmaps were not freed: [0, 1, 2, 3, 4, 5

I get that whenever I use the function .WaitWhileMoving or even .IsAnimating.

https://github.com/Elfyyy/OSR-Reflection/commit/9e132852c538298ba5f3a7c081a09b01659cb883

MariusK
06-14-2015, 09:33 PM
I think that the latest update broke the include. Error:Error: Unknown declaration "TReflectWidget" at line 45

xujnea
06-14-2015, 09:49 PM
I think that the latest update broke the include. Error:Error: Unknown declaration "TReflectWidget" at line 45

Same here, tried changing into TReflectionWidget got this error :
Error: Unknown declaration "IsValid" at line 47

Ian
06-14-2015, 09:59 PM
I think that the latest update broke the include. Error:Error: Unknown declaration "TReflectWidget" at line 45

Broken because of another change that was made, I submitted a pull request here (https://github.com/Elfyyy/OSR-Reflection/pull/71).
elfyyy;

Kyle
06-14-2015, 10:12 PM
Done.. Please force update if you still get error

TheRedGlow
06-14-2015, 10:14 PM
As stated by BMWxi above, the fix for the issue is to:

Open up your simba folder
Navigate to includes
Open reflection
Open lib
Open internal
Open includes

Move line 16 ({$include reflection/lib/widgets/Widgets.simba})
above line 9 ({$include reflection/lib/internal/Login.simba})
Close and save

Thanks for the fast response elfyyy :spot:

stata
06-14-2015, 11:36 PM
I force updated but I'm still getting the error. Anyone else having problems?

MariusK
06-14-2015, 11:41 PM
I force updated but I'm still getting the error. Anyone else having problems?

It is working for me. Did you download the include from github?

stata
06-14-2015, 11:49 PM
It is working for me. Did you download the include from github?

Nope, working now thanks. I was under the impression that with prosocks I could just hit the update buttons in Simba.

superfonz
07-14-2015, 03:34 PM
i keep getting an 'error: access violation' error, ive tried redownloading java and it seems to be coming from the lape reflection so i redownloaded it and it still wont work

captainblast
07-16-2015, 10:17 PM
i keep getting an 'error: access violation' error, ive tried redownloading java and it seems to be coming from the lape reflection so i redownloaded it and it still wont work

I had this error earliar, and was stumped as well. This problem fixed it for me!

To do this remove these 3 lines at line 77 in "Includes > Reflection > lib > misc > Misc.Simba":

{$IFNDEF Aerolib}
{$loadlib prosocks}
{$ENDIF}

carib0u
07-16-2015, 11:01 PM
I had this error earliar, and was stumped as well. This problem fixed it for me!

To do this remove these 3 lines at line 77 in "Includes > Reflection > lib > misc > Misc.Simba":

{$IFNDEF Aerolib}
{$loadlib prosocks}
{$ENDIF}

Would this cause issues with using f-include?

Romet
07-27-2015, 10:24 PM
Can't run FoolMonsterMashAlpha0.010 on lape

[Error] C:\Simba\Includes\SRL-OSR\SRL\Reflection\Core\Misc.simba(21:21): Unknown identifier 'SmartStringFromString' at line 22

What does this error indicate?

Turpinator
07-28-2015, 01:10 AM
Can't run FoolMonsterMashAlpha0.010 on lape

[Error] C:\Simba\Includes\SRL-OSR\SRL\Reflection\Core\Misc.simba(21:21): Unknown identifier 'SmartStringFromString' at line 22

What does this error indicate?

This error indicates you arent using Lape Reflection.

lempa
07-30-2015, 10:54 AM
Im interested how much time will need for new hooks? Sorry for asking, but i have to go so i want to make run bots

Harrier
07-30-2015, 11:12 AM
Im interested how much time will need for new hooks? Sorry for asking, but i have to go so i want to make run bots

Depends on how busy elfyyy is. Could be a few hours to a few days, and try not to post 12 minutes after an update about hooks :p

Curse
08-02-2015, 03:09 PM
I had this error earliar, and was stumped as well. This problem fixed it for me!

To do this remove these 3 lines at line 77 in "Includes > Reflection > lib > misc > Misc.Simba":

{$IFNDEF Aerolib}
{$loadlib prosocks}
{$ENDIF}

You sir are a legend, thank you. This fixed the error on my only release on the site!

cosmasjdz
08-14-2015, 05:12 AM
Has anyone fixed the tiletoms accuracy yet? It seems to be very innacurate after update, especially in larger distances.

ineedbot
08-14-2015, 08:23 AM
Has anyone fixed the tiletoms accuracy yet? It seems to be very innacurate after update, especially in larger distances.
I think its because it doesn't take the zoom into consideration. It seems when its on default zoom level it works just fine.
http://i57.tinypic.com/2q3u3rm.png

thatOneGuyWithTheFace
08-26-2015, 05:02 AM
So I don't know if anyone has had trouble with this as well but this has been bugging me....
MyPlayer.GetHealth doesn't return the proper value... Most of the other functions work though. ._.

program reflectionDemo;
{$DEFINE SMART}
{$i Reflection/Reflection.Simba}
var
MyPlayer: TReflectLocalPlayer;

begin
Reflect.Setup;
MyPlayer.Username := '-----';
MyPlayer.Password := '-----';
MyPlayer.Pin := '';
MyPlayer.Active := true;
MyPlayer.Login;
wait(500);
writeln(MyPlayer.GetRunEnergy); // this returns the proper value
writeln(MyPlayer.GetWeight); // also returns the right value
writeln(MyPlayer.IsRunOn); // also works...
writeln(MyPlayer.IsMoving); // also works!!!!
writeln(MyPlayer.GetHealth); // this returns 0 even though my health im at full heatlh
writeln(MyPlayer.GetMaxHealth); // Doesn't work either... go figure.
// so wtf is going on here?
end.

Also if this is in the wrong section please forgive me. Im pretty nooby... Also thanks in advanced for a response!

Kyle
08-26-2015, 10:51 AM
So I don't know if anyone has had trouble with this as well but this has been bugging me....
MyPlayer.GetHealth doesn't return the proper value... Most of the other function work though. ._.

program reflectionDemo;
{$DEFINE SMART}
{$i Reflection/Reflection.Simba}
var
MyPlayer: TReflectLocalPlayer;

begin
Reflect.Setup;
MyPlayer.Username := '-----';
MyPlayer.Password := '-----';
MyPlayer.Pin := '';
MyPlayer.Active := true;
MyPlayer.Login;
wait(500);
writeln(MyPlayer.GetRunEnergy); // this returns the proper value
writeln(MyPlayer.GetWeight); // also returns the right value
writeln(MyPlayer.IsRunOn); // also works...
writeln(MyPlayer.IsMoving); // also works!!!!
writeln(MyPlayer.GetHealth); // this returns 0 even though my health im at full heatlh
writeln(MyPlayer.GetMaxHealth); // Doesn't work either... go figure.
// so wtf is going on here?
end.

Also if this is in the wrong section please forgive me. Im pretty nooby... Also thanks in advanced for a response!

GetHealth only works when your health bar is above your head i.e. in combat

Joopi
10-12-2015, 08:42 PM
Hi.
I decided to try and using reflection this morning for a script im writing.
I hadnt used it in a long time.
So when i ran an old script it first updated hooks, then updated them again.

After updating twice running any scripts just gives me an Invalid evaluation @ no line.
I tried re-downloading reflection, same results.
I dont know if its related to OSRS updating this morning or if I'm doing something wrong.

Obvious things: yes I use Lape for Lape version, yes it was not only one script but 3 different, 1 of which my old.

MariusK
10-12-2015, 09:06 PM
The hooks are currently outdated.

OneWish
10-13-2015, 01:05 PM
Will log in but won't do anything since update

Kyle
10-13-2015, 01:31 PM
Should be fixed now MariusK;

MariusK
10-13-2015, 02:16 PM
Should be fixed now MariusK;

I was just pointing out to @YouPee, why his script was not working at that moment. I know it's annoying when someone is complaining, that the hooks are outdated. :)

Blak Fishy
10-13-2015, 02:24 PM
Still seems outdated? Finds aren't working for npcs or objects.

Edit: I think the second update fixed it for me, I didn't fetch it but I thought I did.

OneWish
10-13-2015, 03:59 PM
Still seems outdated? Finds aren't working for npcs or objects.

Edit: I think the second update fixed it for me, I didn't fetch it but I thought I did.


Now Im getting an access violation and I have already removed the lines in the reflection code that normally cause this.

r3hab
10-13-2015, 04:34 PM
same here

Smalfinn
10-22-2015, 02:38 PM
and now we play the waiting game.

gfbank
10-23-2015, 01:42 AM
Compiled successfully in 967 ms.
[21:32:06:945] [Reflection] [Status] Paired with SMART client 7948.
[21:34:06:999] [Reflection] [Fatal] Failed to detect or load OSRS.
[21:34:07:003] [Reflection] [Status] All cached references free'd from memory
Successfully executed.

is this a reflection issue?
or script issue?

was working fine earlier this week with the same script i am trying to use.

AFools
10-23-2015, 02:19 AM
Compiled successfully in 967 ms.
[21:32:06:945] [Reflection] [Status] Paired with SMART client 7948.
[21:34:06:999] [Reflection] [Fatal] Failed to detect or load OSRS.
[21:34:07:003] [Reflection] [Status] All cached references free'd from memory
Successfully executed.

is this a reflection issue?
or script issue?

was working fine earlier this week with the same script i am trying to use.

This generally happens when rs updates; taking to long for the login screen to appear. i think the hooks are outdated atm anyway

AFools
01-16-2016, 01:03 AM
I am not sure where to post this... Kyle;


fflag(0);

Do we have the equivalent to this in reflection??? Something like..


reflect.flag;

I do remember seeing something like this?? but i am not too sure

Kyle
01-16-2016, 01:13 AM
I am not sure where to post this... Kyle;


fflag(0);

Do we have the equivalent to this in reflection??? Something like..


reflect.flag;

I do remember seeing something like this?? but i am not too sure

https://github.com/Elfyyy/OSR-Reflection/blob/master/lib/core/renderable/LocalPlayer.simba#L150

AFools
01-16-2016, 01:40 AM
Thank you. =D

I must have overlooked it. When searching through the include.

terrorbyte
02-16-2016, 02:24 PM
Kyle; all my reflection scripts keep poping up keyboard.simba or mouse.simba files from the includes. not sure why.

Picture for refence: http://i.imgur.com/7aNSF77.png

doesn't matter whichever the script is using reflection, this window will popup. only happens with reflection scripts only though. AeroLib standalone scripts are working just fine

Kyle
02-16-2016, 02:58 PM
Kyle; all my reflection scripts keep poping up keyboard.simba or mouse.simba files from the includes. not sure why.

Picture for refence: http://i.imgur.com/7aNSF77.png

doesn't matter whichever the script is using reflection, this window will popup. only happens with reflection scripts only though. AeroLib standalone scripts are working just fine

Meh, it's nothing with reflection, something I assume is overloaded in Aerolib is messing it up. Iunno what, since I don't have AL downloaded, maybe try removing the "[0]" at the end of the replace function?

slyce
02-16-2016, 04:14 PM
Meh, it's nothing with reflection, something I assume is overloaded in Aerolib is messing it up. Iunno what, since I don't have AL downloaded, maybe try removing the "[0]" at the end of the replace function?

I get the same error. Removing [0] works at first but it results in another error:
Error: GetKeyCode - char (s) to key is not available for this target. at line 74

Scripts withouth AL work, so u are probably right that it's messing it up.

Certified
02-19-2016, 04:01 PM
I get

Error:
Unknown declaration "Init" at line 86
Compiling failed.

in TReflectionMisc when I try to compile my script. Any ideas?

Obscurity
02-19-2016, 04:39 PM
Update ProSocks.

Wolfskull
03-16-2016, 07:53 AM
Heya, had the reflection antiban.boredhuman function break on me earlier.

Some reason it wasn't happy with the type assigned to the variable Deg which was set up as being variable.
Anyway, I've changed it to an extended like the value being assigned to it, couldn't see any reason to have it as a variant.

Edit: I realised this was actually causing more issues, no clue what exactly is breaking :/

GTFO_Jagex
05-21-2016, 04:25 AM
I'm facing this issue
Error: Unknown declaration "i" at line 111

function TReflectLocalPlayer.GetSkillExp(SkillConst: Integer): Integer;
begin
Result := Result + Reflect.Smart.GetFieldArrayInt(0, Client_Experiences, i); <---------------- line 111
end;


edit : fixed it by redownloading and re-extracting

Netzone
05-21-2016, 07:34 AM
I'm facing this issue
Error: Unknown declaration "i" at line 111

function TReflectLocalPlayer.GetSkillExp(SkillConst: Integer): Integer;
begin
Result := Result + Reflect.Smart.GetFieldArrayInt(0, Client_Experiences, i); <---------------- line 111
end;


edit : fixed it by redownloading and re-extracting

You could also have fixed it by changing the i to SkillConst.

caseythegreatest
01-27-2017, 07:16 AM
[QUOTE=Kyle;1326830]To expand on what Fitta said. You shouldn't ever have to change the folder again, as it will stay as it is now forever. Lape include is now in Includes/ and PascalScript version is still in Includes/SRL-OSR/SRL

Do I need to have Pascal version in SRL-OSR and SRL??
Everything compiles and boots but it doesn't ever detect and then just crashes after
I need to get my game on

Abrazive
02-13-2017, 07:26 AM
Error: File "Reflection/Reflection.Simba" not found at line 2
Compiling failed.

mellower
02-13-2017, 07:48 PM
Abrazive, if you go into simba's includes folder, you should have Reflection named folder there. If not you need to create that folder and just copy and paste reflection files there too.

Maligkno
03-27-2017, 02:49 PM
"Error: Block expected at line 90
Compiling failed"

TeeVii
07-18-2017, 11:33 AM
ok so im very new to this but i downloaded reflection and put it in the includes and added the plugin as well but everytime i go to start a script (aio fisher) and i hit the play button this pops up, "Error: File "Reflection/Reflection.Simba" not found at line 2
Compiling failed." i do have the reflection in the includes and everything so im so lost right now... any help?

tls
07-18-2017, 03:49 PM
ok so im very new to this but i downloaded reflection and put it in the includes and added the plugin as well but everytime i go to start a script (aio fisher) and i hit the play button this pops up, "Error: File "Reflection/Reflection.Simba" not found at line 2
Compiling failed." i do have the reflection in the includes and everything so im so lost right now... any help?

The import is case-sensitive, meaning it is looking for a folder named *exactly* "Reflection" inside of the includes folder.

TeeVii
07-19-2017, 07:32 AM
The import is case-sensitive, meaning it is looking for a folder named *exactly* "Reflection" inside of the includes folder.

well i tried exactly what the guides say and still nothing. messed with it forever and still get the same thing. could there be like a video guide or something. so lost with this

lolskilla
09-27-2017, 02:32 PM
I had this error earliar, and was stumped as well. This problem fixed it for me!

To do this remove these 3 lines at line 77 in "Includes > Reflection > lib > misc > Misc.Simba":

{$IFNDEF Aerolib}
{$loadlib prosocks}
{$ENDIF}

still getting this error regardless of removing the lines

darker2k
09-27-2019, 05:12 PM
Hi, I'm getting this error:


ERROR: Plugin "prosocks" architecture mismatch

I downloaded the dll and put it into the Plugins folder.

Any idea of what is happening?

Note: The script I'm trying to run on Simba 1.3 is Kristi's Pest Control (https://villavu.com/forum/showthread.php?t=116131)