Stripped ProjectAlchemy Source Code

01/08/2011 21:13 gahanabobo#556
can someone give me a working hunt/looting code? :(
01/08/2011 21:29 [GM]#557
Quote:
Originally Posted by argon69 View Post
I believe it predefined constant. Try it define as 18. So random number will be generated from -18 to 18.
great now problem is solved,
but i got another problem, since i changed this line:
public static bool NewBot(Client C)
to this:
public static void NewBot(Client C)
as P4N said
now this line in Client.cs
Code:
while ([COLOR="Red"]this.RunBot && Handler.NewBot(this)[/COLOR])
is underlined red and says that i can't use && between bool and void

so what should i do now? :confused:
01/08/2011 22:37 vecko12#558
Quote:
Originally Posted by [GM] View Post
great now problem is solved,
but i got another problem, since i changed this line:
public static bool NewBot(Client C)
to this:
public static void NewBot(Client C)
as P4N said
now this line in Client.cs
Code:
while ([COLOR="Red"]this.RunBot && Handler.NewBot(this)[/COLOR])
is underlined red and says that i can't use && between bool and void

so what should i do now? :confused:
because void specifies that the method does not return a value, and bool is used to declare variables to store the Boolean values, true and false.
01/08/2011 23:03 [GM]#559
Quote:
Originally Posted by vecko12 View Post
because void specifies that the method does not return a value, and bool is used to declare variables to store the Boolean values, true and false.
i know sir, so if i use bool i get an error, and if i use void i get another error
iam using ur old hunting method btw which is in here:
[Only registered and activated users can see links. Click Here To Register...]
but i get alot of errors, if u updated it, it would be nice if you realese it
ty
01/09/2011 01:38 argon69#560
Quote:
Originally Posted by [GM] View Post
great now problem is solved,
but i got another problem, since i changed this line:
public static bool NewBot(Client C)
to this:
public static void NewBot(Client C)
as P4N said
now this line in Client.cs
Code:
while ([COLOR="Red"]this.RunBot && Handler.NewBot(this)[/COLOR])
is underlined red and says that i can't use && between bool and void

so what should i do now? :confused:
If you don't want NewBot to return anything, then while loop should be like

while (this.RunBot)
{
NewBot(this);
...
}
01/09/2011 01:53 OELABOELA#561
Quote:
Originally Posted by [GM] View Post
i know sir, so if i use bool i get an error, and if i use void i get another error
iam using ur old hunting method btw which is in here:
[Only registered and activated users can see links. Click Here To Register...]
but i get alot of errors, if u updated it, it would be nice if you realese it
ty
Can you please stop posting WHOLE attack sources, because there will come some noobs that try to compile it and go complain that it wont work (These are noobs with like +1 gear, IE:They know more then the average)

In other news.. Somehow because of internet problems epvp didnt load, and now im banned from epvp, for i dont know how long. Im now using a proxy to login, but this is the reason i was off much.

The bot is currently going good, ninja is as stable as 10k kills, trojan isn't fully tested, but was 3k when my power gone off, warrior is max at 7k, because the shift isnt fully NON-DC yet.
01/09/2011 02:47 argon69#562
Ok, autopot again. For who didn't work on this feature yet, I am adding a bonus here. iteminfo data[64] is item count. Well, ItemInfo doesn't have this information. Then we need to populate :)

Since I located pots in my inventory. I need to use it. Does UseItem() posted at the beginning work? I guess I will find out soon.
01/09/2011 04:59 argon69#563
Quote:
Originally Posted by argon69 View Post
Ok, autopot again. For who didn't work on this feature yet, I am adding a bonus here. iteminfo data[64] is item count. Well, ItemInfo doesn't have this information. Then we need to populate :)

Since I located pots in my inventory. I need to use it. Does UseItem() posted at the beginning work? I guess I will find out soon.
Now it works like a charm. Thanks for the function. I think this could be my last question on hunting bot. How do I know the item is not lootable since the dropped is not yours? I think I am going to set tryCount for the GroundItem. If tryCount > 1 then I will skip.

BTW, I greatly appreciate the help everyone on this thread especially from PxN.
Thanks.
01/09/2011 09:42 [GM]#564
Quote:
Originally Posted by argon69 View Post
If you don't want NewBot to return anything, then while loop should be like

while (this.RunBot)
{
NewBot(this);
...
}
worked like a charm ty, but its dcing after like 3-4 monsters
and it don't stop hunting when i press /hunt again, it only says hunting = true but it don't stop
01/09/2011 10:02 demon17#565
Quote:
Originally Posted by [GM] View Post
worked like a charm ty, but its dcing after like 3-4 monsters
and it don't stop hunting when i press /hunt again, it only says hunting = true but it don't stop
What things you added to your bot?

For stop hunting you need to type /hunt
=true ( hunt is on , will attack monsters)
=false(hunt is off , wont attack monsters)
01/09/2011 10:06 [GM]#566
Quote:
Originally Posted by demon17 View Post
What things you added to your bot?

For stop hunting you need to type /hunt
=true ( hunt is on , will attack monsters)
=false(hunt is off , wont attack monsters)
this is the command of hunting
Code:
                    case "/hunt":
                        {
                            if (!C.RunBot)
                                C.RunBot = true;
                            UpdateStats(C);
                            C.Hunting = !C.Hunting;
                            Chat(C, "Hunting = " + C.Hunting, 2011);
                            break;
                        }
but it doesn't stop hunting + it attacks so fast and dcs even when i make the speed of jumping/attacking 100
01/09/2011 10:20 demon17#567
Quote:
Originally Posted by [GM] View Post
this is the command of hunting
Code:
                    case "/hunt":
                        {
                            if (!C.RunBot)
                                C.RunBot = true;
                            UpdateStats(C);
                            C.Hunting = !C.Hunting;
                            Chat(C, "Hunting = " + C.Hunting, 2011);
                            break;
                        }
but it doesn't stop hunting + it attacks so fast and dcs even when i make the speed of jumping/attacking 100
For me the speed rates are average . I can use 50 at all but to get stable i use :
attack 50 ( In Bird i need to put it to 60 to get it stable )
jump 100
update 100
pothp 350
hitstokill 1

I never hunt with bot w/out FS . Attacks to fast and get DC
I hit mobs buy my hand and after I FS comes i try to get an amount of ks near to 80+ ti unlimited fs .

But i not have a rand jump in my source . so i need to jump sometimes
01/09/2011 10:24 [GM]#568
Quote:
Originally Posted by demon17 View Post
For me the speed rates are average . I can use 50 at all but to get stable i use :
attack 50 ( In Bird i need to put it to 60 to get it stable )
jump 100
update 100
pothp 350
hitstokill 1

I never hunt with bot w/out FS . Attacks to fast and get DC
I hit mobs buy my hand and after I FS comes i try to get an amount of ks near to 80+ ti unlimited fs .

But i not have a rand jump in my source . so i need to jump sometimes
u can use this RandomJump its working great with me
PHP Code:
private static void RandomJump(Client C)
        {
            
Random random = new Random();
            
Coord XY = new Coord();
            
XY.= (ushort)(C.random.Next(-1818));
            
XY.= (ushort)(C.random.Next(-1818));
            if (
Calculations.ValidDmap(C.StaticMapXY.XXY.Y))
            {
                
Packets.CliJump(XY.XXY.Y156C);
                
Packets.Jump(CXY.XXY.Y137);
                
Packets.CliJump(XY.XXY.Y156C);
                
C.XY.X;
                
C.XY.Y;
                
C.UpdatedX XY.X;
                
C.UpdatedY XY.Y;
                
System.Threading.Thread.Sleep(C.JumpSpeed);
                
C.LastJump DateTime.Now;
            }
        } 
01/09/2011 10:39 demon17#569
Quote:
Originally Posted by [GM] View Post
u can use this RandomJump its working great with me
PHP Code:
private static void RandomJump(Client C)
        {
            
Random random = new Random();
            
Coord XY = new Coord();
            
XY.= (ushort)(C.random.Next(-1818));
            
XY.= (ushort)(C.random.Next(-1818));
            if (
Calculations.ValidDmap(C.StaticMapXY.XXY.Y))
            {
                
Packets.CliJump(XY.XXY.Y156C);
                
Packets.Jump(CXY.XXY.Y137);
                
Packets.CliJump(XY.XXY.Y156C);
                
C.XY.X;
                
C.XY.Y;
                
C.UpdatedX XY.X;
                
C.UpdatedY XY.Y;
                
System.Threading.Thread.Sleep(C.JumpSpeed);
                
C.LastJump DateTime.Now;
            }
        } 

Amazing ..
This i need to put in the bot.cs nope?
01/09/2011 10:41 [GM]#570
Quote:
Originally Posted by demon17 View Post
Amazing ..
This i need to put in the bot.cs nope?
ya