SRL Archive - News and General

Converted old plugins to Simba => 0.99


CynicRus

2013-02-26 02:31:44

Hey. Today I found some time and converted the old solvers plugin to the Simba => 0.99. I have not yet tested it and am not sure that they will work, but maybe somebody will be able to debug it. I post the code and dll to the attachment. The plugin contains code Irokiplugin and part of Skyplugin. Maybe it would be helpful.

Cheers,
Cynic.

Ashaman88

2013-02-26 22:55:11

cynic this is great, ran into that major roadblock when converting the old includes and solvers to simba.. I will def test this out

Aegis

2013-02-28 20:05:28

Thanks for this, will take a look!

CynicRus

2013-03-01 01:12:20

Well. Archive is updated now, added converted BoxSolver and Aqua_Pet plugins.

J J

2013-03-01 06:03:21

Ooh nice :D I will look into this properly when my classes are over and my weekend starts!

Flight

2013-05-14 11:55:15

Thank you very much, CynicRus, for posting these! Just earlier I was looking around for the irokiplugin source to see if there's anything we can salvage and apply to our current random solvers. It's just what I was looking for. By chance, is there a Makefile for these to compile via Mingw?

Also, this thread should be getting more attention. If we're able to use these plugins for Oldschool Runescape we would have most of the random solvers right there with great speed and accuracy. This really needs to be looked into further.

Olly

2013-05-14 13:05:09


you can still mess with them :)

edit: nvm, i actually should have tried compiling first :p

CynicRus

2013-05-16 14:14:39

Source code of this plugin easily can be compiled with Lazarus + FPC. But….with MingGW this is impossible?)

CynicRus

2013-05-16 14:47:09

Fixed founded mistake. Archive has been update now.

Flight

2013-05-16 21:17:50

From: CynicRus
Source code of this plugin easily can be compiled with Lazarus + FPC. But….with MingGW this is impossible?)


Oh ok I didn't know if it was, I only assumed. I've never compiled these types of files before.

CynicRus

2013-05-17 04:12:41

From: Flight
Oh ok I didn't know if it was, I only assumed. I've never compiled these types of files before.

Well, yesterday I've share recompiled version of this, and now that can be compile in Simba.

Flight

2013-06-07 22:25:32

Hey @CynicRus, these plugins must be compiled along with Simba? I've tried compiling, for example, just "boxplugin" by itself but when doing so Lazarus also tries to compile the irokiplugin, which has compile errors. Would you mind giving a crash course explanation on compiling these plugins?

Ashaman88

2013-06-07 23:27:53

From: Flight
Hey CynicRus, these plugins must be compiled along with Simba? I've tried compiling, for example, just "boxplugin" by itself but when doing so Lazarus also tries to compile the irokiplugin, which has compile errors. Would you mind giving a crash course explanation on compiling these plugins?


PS if you are asking about the strange box solver, we already have one implemented, I just didn't realize I didn't pull a request to actually call solvebox… That needs to be added to the git :/

Olly

2013-06-08 00:04:15

From: Ashaman88
PS if you are asking about the strange box solver, we already have one implemented, I just didn't realize I didn't pull a request to actually call solvebox… That needs to be added to the git :/


Dont mean to be a douche, but im pretty sure the old solver had a near 100% rate, im not sure what yours is but if we can get it working it might be better to switch eventually :p

Flight

2013-06-08 01:14:45

From: Ollybest
Dont mean to be a douche, but im pretty sure the old solver had a near 100% rate, im not sure what yours is but if we can get it working it might be better to switch eventually :p


I agree, I would much rather use the old plugins and update them if needed. I remember how fast and accurate they were, it's really amazing.

Ashaman88

2013-06-08 01:20:25

From: Ollybest
Dont mean to be a douche, but im pretty sure the old solver had a near 100% rate, im not sure what yours is but if we can get it working it might be better to switch eventually :p


Not at all, but remember we tried running them for the box and it wouldn't work?

CynicRus

2013-06-08 06:51:41

From: Flight
Hey @CynicRus, these plugins must be compiled along with Simba? I've tried compiling, for example, just "boxplugin" by itself but when doing so Lazarus also tries to compile the irokiplugin, which has compile errors. Would you mind giving a crash course explanation on compiling these plugins?

Hey! Well, for compiling an old plugins you should be use a code parts of Simba, because in a plugin I use the TMufasaBitmap and other Simba types. You can see it in uses section of plugin code file.

Cheers,
Cynic.

Olly

2013-06-08 09:18:57

From: Ashaman88
Not at all, but remember we tried running them for the box and it wouldn't work?


Well, we were using the converted simba script perhaps the actual plugin may work.

Flight

2013-06-08 10:17:00

From: Ollybest
Well, we were using the converted simba script perhaps the actual plugin may work.


I'd sure like to find out. If I could compile them I'd test them out myself but I've yet to learn how exactly to do so. CynicRus, do you have a set of these plugins already compiled and ready-to-use?

CynicRus

2013-06-08 10:45:28

From: Flight
I'd sure like to find out. If I could compile them I'd test them out myself but I've yet to learn how exactly to do so. CynicRus, do you have a set of these plugins already compiled and ready-to-use?


Ehm…As far as I remeber, I've attached a compiled version of the plugin to the archive with a source code.

Olly

2013-06-08 11:16:22

From: Flight
I'd sure like to find out. If I could compile them I'd test them out myself but I've yet to learn how exactly to do so. CynicRus, do you have a set of these plugins already compiled and ready-to-use?


It's in the folder, solvers.dll they are all in there i messed around with the box one for 2 mins some time ago, and was getting errors. I am quite sure i was inputting the wrong bitmap size but i got bored and left it alone :p

Ashaman88

2013-06-08 11:18:01

From: Ollybest
Well, we were using the converted simba script perhaps the actual plugin may work.


True that. Well the solver we have now solves at like 85% success rate for each box… and eventually solves all of them (It's solved a full inv of them in like 10mins? or so)

Flight

2014-01-26 08:14:04

I would really like to get all of these compiled if possible. Perhaps @warpie might be able to take a look at these and optimize them?

Brandon

2014-01-26 12:56:47

From: Flight
I would really like to get all of these compiled if possible. Perhaps @warpie might be able to take a look at these and optimize them?



There are way too many things in that plugin that would need optimising..

For example:


x + xd[...] >= 0 and y + yd[...] >= 0 and x + xd[...] <= .. and y + yd[...]

would be easily done like:


var
xsum, ysum: some_type;

xsum = x + xd[...];
ysum = y + yd[...];
xsum >= 0 and ysum >= 0 and xsum <=.. and ysum <= ..

Another thing is replacing sqrt with multiplication, 2Darrays with 1Darrays (multiple-allocations to 1 allocation for square arrays)..

I doubt he's going to want to do all of that. The compiler should probably do it but it might not even with aggressive optimisations turned on (if it has that).

bg5

2014-01-28 15:25:31

I believe it's not so hard to run this code in Simba, without using plugin.

CynicRus

2014-01-31 00:25:31

Of course! But as plugin it should be work much faster.

Flight

2014-01-31 00:52:08

From: CynicRus
Of course! But as plugin it should be work much faster.


Exactly. :biggrin:

Flight

2014-03-05 00:10:53

Mr CynicRus, any ideas on why the Solvers.dll plugin isn't compiling?


Exception in Script: Unknown declaration "TExtPoint" at line 1, column 65 in file "!addGlobalType"
Exception TLPThread.Destroy: Access violation

Olly

2014-03-05 01:00:01

From: Flight
Mr CynicRus, any ideas on why the Solvers.dll plugin isn't compiling?


Exception in Script: Unknown declaration "TExtPoint" at line 1, column 65 in file "!addGlobalType"
Exception TLPThread.Destroy: Access violation


idk, looks fine to me.. or maybe it's because its 6am… heh could do it this way i guess,

https://www.dropbox.com/s/luvhac8cbdfxb70/Solvers.dll

type
TExtPoint = record x, y: double; end;
TPerspective = record m00, m01, m02,m10, m11, m12,m20, m21, m22: double; end;
TRectRemapper = record width, height: Integer; source: array of TExtPoint; end;

{$loadlib solvers}

begin

end;

Olly

2014-03-05 01:20:10

Code is nasty, not sure we will ever see such genius ppl again.


Circle
4
16 ms

Flight

2014-03-05 02:25:05

Oi why didn't I just copy those types from the plugin? :duh:

Nicely done as always Olly.

Edit:
Access Violation when trying to run it. Seems similar to the problem I had when converting SPS to OSR. Already tried everything I can think of, hm…

Edit2:
Nevermind, my bounds were incorrect. Working fine now.