PDA

View Full Version : [SMART][OSR] Faceless Jewellery Enchanter



Faceless
09-12-2013, 03:39 PM
22191
Faceless' Jewellery Enchanter
Features:
- Fail safes
- Uses SMART
- Uses SRL-OSR
- Status report
- Good Antiban
- Custom methods
- Set amount of enchants

Requirements:
- SRL-OSR & SMART (http://villavu.com/forum/showthread.php?t=97599)
- Jewellery to enchant
- Cosmic runes & elemental staff
- Appropriate level for casting enchant spells

Instructions:
- Have cosmic runes in first inventory slot.
- Equip the correct staff for the spell you are casting.
- Put jewellery to be enchanted in the first bank slot at the top left.
- Start at any bank.

Please post any bugs or comments you have to help improve the script.
If enough people like it and the prices of enchanted items don't plummet,
I'll updated it to include things like dragonstone and maybe the whole crafting shebang.

Cheers, enjoy the script!

Sjoe
09-12-2013, 06:25 PM
Grats on release :)

rj
09-12-2013, 09:52 PM
Congratulations and not bad :D

Hoodz
09-12-2013, 09:53 PM
Gz!

maxime9516
01-16-2014, 06:11 PM
Hi The bot working but when he is in the bank the red dot mouse curser go on my sapphire ring in the top left bank slot... but the bot stop and it write : Could not find correct item, withdrew nothing.
We didnt withdraw anything, trying again
Could not find correct item, withdrew nothing.
Either you are out of items or something got fucked.
Stopping script...
Succesfully freed SMART[4400]
Successfully executed.

can someone post a configuration for enchante sapphire ring plz ?

Turpinator
01-16-2014, 06:24 PM
Hi The bot working but when he is in the bank the red dot mouse curser go on my sapphire ring in the top left bank slot... but the bot stop and it write : Could not find correct item, withdrew nothing.
can someone post a configuration for enchante sapphire ring plz ?

did you update this line?
ITEMTEXT = 'iam'; // A few letters of the item you want to enchant

maxime9516
01-16-2014, 06:41 PM
did you update this line?
ITEMTEXT = 'iam'; // A few letters of the item you want to enchant

Yeah i try "sapphire ring" "sap" "sr" ... no one work help plz

Hoodz
01-16-2014, 08:05 PM
Yeah i try "sapphire ring" "sap" "sr" ... no one work help plz

yes i had this at a given time too with the include. it couldnt read any uptext anymore... try to update your srl-osr include/ updating fonts.

maxime9516
01-16-2014, 11:22 PM
The script work good but when it has enchented 100 ring the bot stop and say : Did not find bank booth at all

how can i fix it ?

cmurray92
01-04-2015, 10:46 PM
Man, you need to slooooooow down the bank finding process. It sporadically moves around and very seldom actually finds the bank. Half the time it clicks the trading post or a voting poll booth.

Turpinator
01-05-2015, 02:02 AM
Man, you need to slooooooow down the bank finding process. It sporadically moves around and very seldom actually finds the bank. Half the time it clicks the trading post or a voting poll booth.

This is well over a year old, im surprised it still runs without an error from things being changed.
Perhaps the banking just needs new colors? you could probably update those?

jajo123
05-04-2015, 10:15 PM
is there some way to get this working again?

King
06-10-2015, 03:16 AM
It should be vey easy to get working again. Updating the bank booth colors, along with changing the areas of the banknscreen. Look in the tutorial section for an ACA tutorial. Replace the colors with the colors found in the "Find bank" procedure and run the script and see what happens. By and large this would be an easy script to craft. Look at the procedure in this script to get an idea. I doubt many people would release one publicly.

anth_
07-08-2015, 09:24 PM
I updated this for Maligkno as it was not working, you need reflection and the aerolib include.

Enchanting may be a bit off. The entire script needs changing but I cba to do it last night so there you go :P

I may fix it later. Feel free to do it yourselves!



program JewelleryEnchanter;
{$DEFINE SMART}
{$i AeroLib/AeroLib.Simba}
{$i Reflection/Reflection.simba}

{--------Jewellery-Enchanter--------
---------------v1.0----------------
------------By Faceless------------

/------------\
|Instructions|
\------------/

1. Have cosmic runes in inventory
2. Equip the correct staff for the spell you are casting.
3. Put jewellery to be enchanted wherever.
4. Start at any bank chest.}

const
SPELLTOCAST = 's'; // 's' for sapphire, 'e' for emerald, 'r' for ruby, 'd' for diamond

var
statusText, ItemID, EnchantedID, BankType: String;
MyPlayer: TReflectLocalPlayer;
Item, Enchanted : TReflectInvItem;



//---------- EDIT ANYTHING BELOW THIS LINE----------\\
//------------ YOU MAY OR MAY NOT KNOW WHAT YOU ARE DOING-----------\\ ;)

procedure Login;
begin
MyPlayer.UserName := '';
MyPlayer.Password := '';
MyPlayer.Active := True;
MyPlayer.Login;
ItemID := 'Sapphire ring'; //Name for the item to enchant. Case sensitive.
EnchantedID := 'Ring of recoil'; //Name for the enchanted item. Case sensitive.
BankType := 'Bank chest'; // Name for bank. 'Bank' or 'Bank chest'. Case Sensitive
end;

Procedure AntiBan;
begin
LevelUp;
case (Random) of
1:
begin
Status('Antiban: Random right');
RandomRClick;
Wait(RandomRange(1203, 3486));
end;
2:
begin
Status('Antiban: Random movement');
RandomMovement;
Wait(RandomRange(803, 2486));
end;
3:
begin
Status('Antiban: Bored human');
BoredHuman;
Wait(RandomRange(543, 3081));
end;
4:
begin
Status('Antiban: Pick up mouse');
PickUpMouse;
Wait(RandomRange(543, 3081));
end;
5:
begin

end;
6:
begin
Status('Antiban: Random compass movement');
CompassMovement(10, 30, true);
Wait(RandomRange(543, 3081));
end;
7:
begin
Status('Antiban: Examining random inventory item');
ExamineInv;
Wait(RandomRange(487, 2427));
end;
8:
begin
Status('Antiban: Hitting random F keys');
RandomFKeys(true);
Wait(RandomRange(813, 4072));
end;
9:
begin
Status('Antiban: Moving mouse off client');
MMouseOffClient('random');
Wait(RandomRange(3813, 9072));
end;
end;
end;


procedure OpenBank;

var Bank: TReflectObject;

begin

begin // Implement bank check if this fails, exit if not
Bank.Find(objGame, BankType, 5);
Reflect.Mouse.Move(Bank.GetMSPoint, 3, 3);
writeLn('Opening Bank');
Reflect.Mouse.Click(Mouse_Left);
end;

end;

procedure Deposit;

var Bank: TReflectObject;

begin
begin
wait(1000 + (Random(1000)));
if Enchanted.Find(EnchantedID) then
begin
Reflect.Mouse.Move(Enchanted.GetPoint, 3, 3);
Reflect.Mouse.Click(Mouse_Right);
ChooseOption('sit-All');
WriteLn('Depositing Enchanted Items!')
end;
begin
if not Reflect.Bank.IsOpen then
begin
WriteLn('Cannot find Bank!');
TerminateScript;
end;
end;
end;
end;

procedure Withdraw;
begin
begin
wait(1000 + Random(1000));
if Reflect.Bank.IsOpen then
begin
Reflect.Bank.Withdraw(ItemID, -1);
Reflect.Bank.Close;
end;
end;
end;

procedure CastEnchant(spellType:String);
begin
if (spellType = 's') then
begin
GaussMouseBox(685, 233, 695, 245, mouse_Move); //You're going to need to change all these co-ords!
wait(RandomRange(150,320)); //(Top left x,y, Bottom Right x,y) of the box
Status('Casting lvl 1 enchant spell'); //Try using GaussMouseBox(, , , , Mouse_Move);
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'e') then
begin
GaussMouseBox(613, 280, 623, 293, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 2 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'r') then
begin
GaussMouseBox(565, 329, 576, 339, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 3 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'd') then
begin
GaussMouseBox(590, 353, 599, 364, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 4 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else
begin
writeln('Invalid spell type');
end;
end;

Procedure UseMagics;
var
i:Integer;
begin
i := 2;
if (TabExists(tab_Magic)) then
begin
FTab(tab_Magic);
Wait(RandomRange(1000, 4000));
repeat

if (GetCurrentTab <> tab_Magic) then
FTab(tab_Magic);

CastEnchant(SPELLTOCAST);
WriteLn('casting enchant');
wait(RandomRange(150,320));
Reflect.Mouse.Move(Item.GetPoint, 3, 3);
WriteLn('Moving to item'); //This stuff may not work
wait(RandomRange(150,320));
FastClick(mouse_Left);
wait (1000 + Random(1000));
if Item.Find(ItemID) then //You'll have to change this so it recognises the item to enchant
Reflect.Mouse.Move(Item.GetPoint, 3, 3);
FastClick(mouse_Left);
wait (1000 + Random(1000));
until(false);
end;
end;

procedure MainLoop;
begin
AntiBan;
OpenBank;
Deposit;
Withdraw;
Wait(RandomRange(400, 1500));
UseMagics;
end;

begin
// Startup methods
initAL; // This is for aerolib, needed
Reflect.Setup; //This is for reflection, needed
Login; //The login procedure
// start of main loop
repeat
MainLoop;
until(false);
end.

jajo123
07-20-2015, 05:18 AM
I updated this for Maligkno as it was not working, you need reflection and the aerolib include.

Enchanting may be a bit off. The entire script needs changing but I cba to do it last night so there you go :P

I may fix it later. Feel free to do it yourselves!



program JewelleryEnchanter;
{$DEFINE SMART}
{$i AeroLib/AeroLib.Simba}
{$i Reflection/Reflection.simba}

{--------Jewellery-Enchanter--------
---------------v1.0----------------
------------By Faceless------------

/------------\
|Instructions|
\------------/

1. Have cosmic runes in inventory
2. Equip the correct staff for the spell you are casting.
3. Put jewellery to be enchanted wherever.
4. Start at any bank chest.}

const
SPELLTOCAST = 's'; // 's' for sapphire, 'e' for emerald, 'r' for ruby, 'd' for diamond

var
statusText, ItemID, EnchantedID, BankType: String;
MyPlayer: TReflectLocalPlayer;
Item, Enchanted : TReflectInvItem;



//---------- EDIT ANYTHING BELOW THIS LINE----------\\
//------------ YOU MAY OR MAY NOT KNOW WHAT YOU ARE DOING-----------\\ ;)

procedure Login;
begin
MyPlayer.UserName := '';
MyPlayer.Password := '';
MyPlayer.Active := True;
MyPlayer.Login;
ItemID := 'Sapphire ring'; //Name for the item to enchant. Case sensitive.
EnchantedID := 'Ring of recoil'; //Name for the enchanted item. Case sensitive.
BankType := 'Bank chest'; // Name for bank. 'Bank' or 'Bank chest'. Case Sensitive
end;

Procedure AntiBan;
begin
LevelUp;
case (Random) of
1:
begin
Status('Antiban: Random right');
RandomRClick;
Wait(RandomRange(1203, 3486));
end;
2:
begin
Status('Antiban: Random movement');
RandomMovement;
Wait(RandomRange(803, 2486));
end;
3:
begin
Status('Antiban: Bored human');
BoredHuman;
Wait(RandomRange(543, 3081));
end;
4:
begin
Status('Antiban: Pick up mouse');
PickUpMouse;
Wait(RandomRange(543, 3081));
end;
5:
begin

end;
6:
begin
Status('Antiban: Random compass movement');
CompassMovement(10, 30, true);
Wait(RandomRange(543, 3081));
end;
7:
begin
Status('Antiban: Examining random inventory item');
ExamineInv;
Wait(RandomRange(487, 2427));
end;
8:
begin
Status('Antiban: Hitting random F keys');
RandomFKeys(true);
Wait(RandomRange(813, 4072));
end;
9:
begin
Status('Antiban: Moving mouse off client');
MMouseOffClient('random');
Wait(RandomRange(3813, 9072));
end;
end;
end;


procedure OpenBank;

var Bank: TReflectObject;

begin

begin // Implement bank check if this fails, exit if not
Bank.Find(objGame, BankType, 5);
Reflect.Mouse.Move(Bank.GetMSPoint, 3, 3);
writeLn('Opening Bank');
Reflect.Mouse.Click(Mouse_Left);
end;

end;

procedure Deposit;

var Bank: TReflectObject;

begin
begin
wait(1000 + (Random(1000)));
if Enchanted.Find(EnchantedID) then
begin
Reflect.Mouse.Move(Enchanted.GetPoint, 3, 3);
Reflect.Mouse.Click(Mouse_Right);
ChooseOption('sit-All');
WriteLn('Depositing Enchanted Items!')
end;
begin
if not Reflect.Bank.IsOpen then
begin
WriteLn('Cannot find Bank!');
TerminateScript;
end;
end;
end;
end;

procedure Withdraw;
begin
begin
wait(1000 + Random(1000));
if Reflect.Bank.IsOpen then
begin
Reflect.Bank.Withdraw(ItemID, -1);
Reflect.Bank.Close;
end;
end;
end;

procedure CastEnchant(spellType:String);
begin
if (spellType = 's') then
begin
GaussMouseBox(685, 233, 695, 245, mouse_Move); //You're going to need to change all these co-ords!
wait(RandomRange(150,320)); //(Top left x,y, Bottom Right x,y) of the box
Status('Casting lvl 1 enchant spell'); //Try using GaussMouseBox(, , , , Mouse_Move);
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'e') then
begin
GaussMouseBox(613, 280, 623, 293, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 2 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'r') then
begin
GaussMouseBox(565, 329, 576, 339, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 3 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'd') then
begin
GaussMouseBox(590, 353, 599, 364, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 4 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else
begin
writeln('Invalid spell type');
end;
end;

Procedure UseMagics;
var
i:Integer;
begin
i := 2;
if (TabExists(tab_Magic)) then
begin
FTab(tab_Magic);
Wait(RandomRange(1000, 4000));
repeat

if (GetCurrentTab <> tab_Magic) then
FTab(tab_Magic);

CastEnchant(SPELLTOCAST);
WriteLn('casting enchant');
wait(RandomRange(150,320));
Reflect.Mouse.Move(Item.GetPoint, 3, 3);
WriteLn('Moving to item'); //This stuff may not work
wait(RandomRange(150,320));
FastClick(mouse_Left);
wait (1000 + Random(1000));
if Item.Find(ItemID) then //You'll have to change this so it recognises the item to enchant
Reflect.Mouse.Move(Item.GetPoint, 3, 3);
FastClick(mouse_Left);
wait (1000 + Random(1000));
until(false);
end;
end;

procedure MainLoop;
begin
AntiBan;
OpenBank;
Deposit;
Withdraw;
Wait(RandomRange(400, 1500));
UseMagics;
end;

begin
// Startup methods
initAL; // This is for aerolib, needed
Reflect.Setup; //This is for reflection, needed
Login; //The login procedure
// start of main loop
repeat
MainLoop;
until(false);
end.


banking works, but when enchanting it seems to attempt to click the position of the item while it's still on the spells tab.

anth_
07-20-2015, 06:06 PM
banking works, but when enchanting it seems to attempt to click the position of the item while it's still on the spells tab.

Sorry mate, I only changed it over to reflection/aerolib for Maligkno. I haven't used it - the original script is a couple of years old. Why not try and fix it yourself? I'm sure if you were running in to problems people here would help :)

jajo123
07-21-2015, 04:36 AM
Sorry mate, I only changed it over to reflection/aerolib for Maligkno. I haven't used it - the original script is a couple of years old. Why not try and fix it yourself? I'm sure if you were running in to problems people here would help :)

alright, i'll try and see what i can figure out :cool:

Bumbaa
09-08-2016, 02:19 PM
I have to thanks the creator of this script,faceless and Anth for updating it. Sadly, it still wasn't working properly and banking was not working. I am no programmer an with the help of Joogi on the IIRC chat managed to make the script work again with a logout option after your Runes for enchanting are depleted.

Here is the code:


program JewelleryEnchanter;
{$DEFINE SMART}
{$i AeroLib/AeroLib.Simba}
{$i Reflection/Reflection.simba}

{--------Jewellery-Enchanter--------
---------------v1.0----------------
------------By Faceless------------

/------------\
|Instructions|
\------------/

1. Have cosmic runes in inventory
2. Equip the correct staff for the spell you are casting.
3. Put jewellery to be enchanted wherever.
4. Start at any bank chest.}

const
SPELLTOCAST = 's'; // 's' for sapphire, 'e' for emerald, 'r' for ruby, 'd' for diamond

var
statusText, ItemID, EnchantedID, BankType, RuneID: String;
MyPlayer: TReflectLocalPlayer;
Item, Enchanted, Rune: TReflectInvItem;





//---------- EDIT ANYTHING BELOW THIS LINE----------\\
//------------ YOU MAY OR MAY NOT KNOW WHAT YOU ARE DOING-----------\\ ;)

procedure Login;

begin
MyPlayer.UserName := '';
MyPlayer.Password := '';
MyPlayer.Active := True;
MyPlayer.Login;
ItemID := 'Sapphire ring'; //Name for the item to enchant. Case sensitive.
EnchantedID := 'Ring of recoil'; //Name for the enchanted item. Case sensitive.
BankType := 'Bank booth'; // Name for bank. 'Bank' or 'Bank chest'. Case Sensitive
RuneID := 'Cosmic rune';
end;

function Variantify(s : string) : TVariantArray;
begin
result := [s];
end;

Procedure AntiBan;
begin
LevelUp;
case (Random) of
1:
begin
Status('Antiban: Random right');
RandomRClick;
Wait(RandomRange(1203, 3486));
end;
2:
begin
Status('Antiban: Random movement');
RandomMovement;
Wait(RandomRange(803, 2486));
end;
3:
begin
Status('Antiban: Bored human');
BoredHuman;
Wait(RandomRange(543, 3081));
end;
4:
begin
Status('Antiban: Pick up mouse');
PickUpMouse;
Wait(RandomRange(543, 3081));
end;
5:
begin

end;
6:
begin
Status('Antiban: Random compass movement');
CompassMovement(10, 30, true);
Wait(RandomRange(543, 3081));
end;
7:
begin
Status('Antiban: Examining random inventory item');
ExamineInv;
Wait(RandomRange(487, 2427));
end;
8:
begin
Status('Antiban: Hitting random F keys');
RandomFKeys(true);
Wait(RandomRange(813, 4072));
end;
9:
begin
Status('Antiban: Moving mouse off client');
MMouseOffClient('random');
Wait(RandomRange(3813, 9072));
end;
end;
end;


procedure OpenBank;

var Bank: TReflectObject;

begin

begin // Implement bank check if this fa4ils, exit if not

Bank.Find(objGame, BankType, 5);
Reflect.Mouse.Move(Bank.GetMSPoint, 3, 3);
writeLn('Opening Bank');
wait(500 + Random(150));
Reflect.Mouse.Click(Mouse_Left);
end;

end;

procedure Deposit;

var Bank: TReflectObject;

begin
begin
wait(1000 + (Random(1000)));
if Enchanted.Find(EnchantedID) then
begin
Reflect.Mouse.Move(Enchanted.GetPoint, 3, 3);
Reflect.Mouse.Click(Mouse_Right);
ChooseOption('sit-All');
WriteLn('Depositing Enchanted Items!')
end;
begin
if not Reflect.Bank.IsOpen then
begin
repeat
OpenBank;
until(Reflect.Bank.IsOpen = true);
end;
end;
end;
end;

procedure Withdraw;
begin
begin
wait(1000 + Random(1000));
if Reflect.Bank.IsOpen then
begin
Reflect.Bank.Withdraw(ItemID, -1);
Reflect.Bank.Close;
end;
end;
end;

procedure CastEnchant(spellType:String);
begin
if (spellType = 's') then
begin
GaussMouseBox(685, 233, 695, 245, mouse_Move); //You're going to need to change all these co-ords!
wait(RandomRange(150,320)); //(Top left x,y, Bottom Right x,y) of the box
Status('Casting lvl 1 enchant spell'); //Try using GaussMouseBox(, , , , Mouse_Move);
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'e') then
begin
GaussMouseBox(616, 278, 619, 281, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 2 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'r') then
begin
GaussMouseBox(565, 329, 576, 339, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 3 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else if (spellType = 'd') then
begin
GaussMouseBox(590, 353, 599, 364, mouse_Move);
wait(RandomRange(150,320));
Status('Casting lvl 4 enchant spell');
FastClick(mouse_Left);
wait(RandomRange(150,320));
end else
begin
writeln('Invalid spell type');
end;
end;

Procedure UseMagics;
var
i:Integer;
g:Integer;
r:Integer;


begin


i := 2;
if (TabExists(tab_Magic)) then
begin
FTab(tab_Magic);
Wait(RandomRange(400, 1700));
repeat

if (GetCurrentTab <> tab_Magic) then
FTab(tab_Magic);

CastEnchant(SPELLTOCAST);
WriteLn('casting enchant');
wait(RandomRange(100,225));
WriteLn('Moving to item'); //This stuff may not work
wait(RandomRange(90,203));
wait (175 + Random(200));
if Item.Find(ItemID) then //You'll have to change this so it recognises the item to enchant
Reflect.Mouse.Move(Item.GetPoint, 3, 3);
FastClick(mouse_Left);
wait (125 + Random(225));
g := Reflect.inv.Count(Variantify(EnchantedID));
if (Rune.Find(RuneID) = false) then
begin
logoutPlayer;
WriteLn('No more runes');
TerminateScript;
end;
if Reflect.inv.count(Variantify(ItemID)) = 0 then
begin
OpenBank;
Deposit;
Withdraw;
end;
until(g = 27);
end;
end;


procedure MainLoop;
begin
OpenBank;
Deposit;
Withdraw;
AntiBan;
Wait(RandomRange(400, 1500));
UseMagics;
end;

begin
// Startup methods
initAL; // This is for aerolib, needed
Reflect.Setup; //This is for reflection, needed
Login; //The login procedure
// start of main loop
repeat
MainLoop;
until(false);
end.

Cheers,
Bumbaaa

crazedkooga
02-18-2017, 09:39 AM
I have to thanks the creator of this script,faceless and Anth for updating it. Sadly, it still wasn't working properly and banking was not working. I am no programmer an with the help of Joogi on the IIRC chat managed to make the script work again with a logout option after your Runes for enchanting are depleted.

Here is the code:

Cheers,
Bumbaaa

Hello Fella's

Don't know too much about all this coding business, but been messing with this strict and Bumbaaa's version seems to be working to a satisfactory standard (tweaked the wait timings etc), but I found the script kept opening the bank twice as when the script checks for jewellery line 245 seems to be tripping the script up.
I changed:

245: until(g = 27)
to
245: until(g = -1)

And this double bank error seemed to vanish, sorry bad explanation but just a quick fix :)

Thanks Fella's.