Jump to content

Recommended Posts

Posted

//WH Dupe Script by RaRus. 2008  //


// How to use!
// 1. You need clean wh.
// 2. You need item what you want to dupe first in the wh deposit list.
// How to do it:
// (Deposit your item what you want to dupe and withdraw it.
// You will have this item first in inv and deposit list).
// 3. Run the script using L2phx
// 4. Target a wh and try 'Deposit Item (Private Warehouse)'
// Script will deposit first item to wh
// 5. Do 'Withdraw Item (Private Warehouse)'
// (First time you will get msg : 'Dupe items: DB1(), DB2()'
// That means items is dupes.. Do it some times and you will get msg:
// 'WithDraw Duped: Amount()' Ok, dupe is done.

// 5575 = Ancient Adena
// 9374 = Donator Coin
// 6029 = Lunargent
// 1374 = Greater Haste Potion

var
  dbid1,dbid2,am1,am2,dbid1_d,am1_d,ammount_d,whtype,ItemID,i,type:integer;

const
MIN=4;     // Min amount of items.(you need to have MIN+1)
MAX=999; // Max amount of items (for AA or Adena can be more).
ID=9374;   // ID of item what you want to dupe.


procedure Msg(msg:string);
begin 
     buf:=#$4A;
     WriteD(0);
     WriteD(9);
     WriteS('RaRus');
     WriteS(msg);
     SendToClient;
end;


procedure WithDraw2(OID,OID2,amountp:integer);
begin
     buf:=#$32;
     WriteD(3);
     WriteD(OID);
     WriteD(amountp);
     WriteD(OID2);
     WriteD(1);
     WriteD(OID2);
     WriteD(1);
     SendToServer;
     buf:=#$32;
     WriteD(3);
     WriteD(OID);
     WriteD(amountp);
     WriteD(OID2);
     WriteD(1);
     WriteD(OID2);
     WriteD(1);
     SendToServer;
end;

procedure DepItems(OID,amountp:integer);
begin
     buf:=#$31;
     WriteD(2);
     WriteD(OID);
     WriteD(amountp);
     WriteD(OID);
     WriteD(1);
     SendToServer;
end;

procedure WithDrawDuped(OID,amountp:integer);
begin
     buf:=#$32;
     WriteD(1);
     WriteD(OID);
     WriteD(amountp);
     SendToServer;
end;

begin

if FromServer and (pck[1]=#$41) then
begin
     ItemID:=ReadD(16);
     am1_d:=ReadD(20);
     dbid1_d:=ReadD(38);

     if ((ItemID) = ID) then
     begin

     if ((am1_d) > MIN) then
     begin
     ammount_d:=am1_d-3;
     DepItems(dbid1_d,ammount_d);
     Msg('Deposit items: DB1('+IntToStr(dbid1_d)+'), Amount('+IntToStr(ammount_d)+')');
     end;

     if ((am1_d) < MIN) then
     begin
     Msg('Deposit error: Amount('+IntToStr(am1_d)+')');
     end;

     if ((am1_d) > MAX) then
     begin
     Msg('Deposit error: Amount('+IntToStr(am1_d)+')');
     end;
     end;
end;



if FromServer and (pck[1]=#$42) then  //  Withdraw
begin
     whtype:=ReadH(8); //this is not a smile, this is number 8 and symbol )
     am1:=ReadD(20);
     am2:=ReadD(60);
     dbid1:=ReadD(38);
     dbid2:=ReadD(78);

     if ((am2) = 0) and ((am1) > 0) then
     begin
     WithDrawDuped(dbid1,am1);
     Msg('WithDraw Duped: Amount('+IntToStr(am1)+')');
     end;

     if ((am2) > 0 ) and ((whtype) = 2 ) then
     begin
     WithDraw2(dbid1,dbid2,am1);
     Msg('Dupe items: DB1('+IntToStr(dbid1)+'), DB2('+IntToStr(dbid2)+'), Amount('+IntToStr(am1)+')');
     end;

     if ((whtype) = 1 ) and ((am1) = 0) then
     begin
     Msg('WithDraw error: Amount('+IntToStr(am1)+')');
     end;

     if ((am1) > MAX) then
     begin
     Msg('WithDraw error: Amount more than MAX ('+IntToStr(am1)+')');
     end;
end;
end.

 

Work on all PTS (without fix)

Posted

[Hide]Its hard to understand wich packet u need to copy cuz they name it randomly liek Unknown, or ally create, or sum random bullsh!t. I had trouble in the middle part step 4 i didnt understand, but im told it doesnt work at all in ct2?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...