Stripped ProjectAlchemy Source Code

02/15/2011 23:38 pro4never#976
Personally I used an update speed to control how often client jump was sent.

I used a Updated X/Y value which I only updated every time I sent a client jump packet. I then used a client update speed as well as checking updated x/y vs server x/y. If the two did not match and enough time had passed then I updated the client.

That way I could have the client be updated say every... 500 ms... 1000ms... 100000 ms, etc.

Made controlling updates much simpler and I felt no need to display every single movement (pointless and can crash your client if you send too many updates)
02/16/2011 00:51 caio bola#977
Is it a good example of controling updates?
Quote:
if (C.LastJump.AddMilliseconds(C.JumpSpeed) < DateTime.Now)
{
Packets.CliJump(attack.X, attack.Y, 156, C);
C.X = attack.X;
C.Y = attack.Y;
C.UpdatedX = C.X;
C.UpdatedY = C.Y;
Calculations.UpdateLocal(C);
C.LastJump = DateTime.Now;
02/17/2011 18:48 pro4never#978
Personally I'd check last updated position vs current position...

Also you aren't moving so you shouldn't be calling updatelocal.

Nor are you jumping so setting last jump is pointless

Also this will only run if you are attacking... IE: What happens if no mobs are in range? ^^ The whole point of doing an update client type action is to display where you are. There are lots of times you want the position to update even if no mobs are in range.


if (C.LastJump.AddMilliseconds(C.JumpSpeed) < DateTime.Now && (C.X != C.UpdatedX || C.Y != C.UpdatedY))
{
Packets.CliJump(C.X, C.Y, 156, C);
C.UpdatedX = C.X;
C.UpdatedY = C.Y;
C.LastUpdated = DateTime.Now; }


Place that at the beginning of your bot code.

<edit>

I'm bored... kinda tempted to make a simple pserver proxy to let people use ahahah...
02/18/2011 01:53 caio bola#979
p4n i changed it , now i will only send clijump in 2 occasions:

1 - When fatalstrike is over ( infatalstrike=false ,hunting=false , clijump)
2 - When theres no mobs in range ( aKa RandomJump condition: clijump + jump -18+18 cords)

What do you think?

And I really need help on looting code , mine is just fucked up , im not a leecher but im a newbie coder and looting is causing me 1022 error packet ( wich is not jump packet , so I guess whres the problem? in the PickItem packet? Or the delaye between Picking and Attacking? )

p4n would be really good if you release some of your code pattern , ESPECIALLY for the outsiders players ( like me Brazilian ) who will never had a chance to play in your proxy.

My hunting is going very good , very stable , but im pretty sure you have better stuff than I do , because that whole code is yours and im just a nb coder
02/18/2011 02:12 argon69#980
Quote:
Originally Posted by pro4never View Post
Personally I'd check last updated position vs current position...

Also you aren't moving so you shouldn't be calling updatelocal.

Nor are you jumping so setting last jump is pointless

Also this will only run if you are attacking... IE: What happens if no mobs are in range? ^^ The whole point of doing an update client type action is to display where you are. There are lots of times you want the position to update even if no mobs are in range.


if (C.LastJump.AddMilliseconds(C.JumpSpeed) < DateTime.Now && (C.X != C.UpdatedX || C.Y != C.UpdatedY))
{
Packets.CliJump(C.X, C.Y, 156, C);
C.UpdatedX = C.X;
C.UpdatedY = C.Y;
C.LastUpdated = DateTime.Now; }


Place that at the beginning of your bot code.

<edit>

I'm bored... kinda tempted to make a simple pserver proxy to let people use ahahah...
I am thinking about writing c++ proxy... just for fun :) Also I want to include loader as part of proxy. But I am kind of lost where to start... I am not sure what I can do to make client exe to listen to proxy address without changing co files.
02/18/2011 17:07 caio bola#981
p4n why on some videobots , some proxys updates CLIJUMP while attacking ( co farmer ) and others not ( COOperative) ? Whats the big deal in it?
02/18/2011 17:12 pro4never#982
Well to define anything you just go to the character class and put something like

uint HitsDone = 0;

or w/e type of variable you want lol. What are you using HitsDone for? I assume it's total hits attempted during botting? Simple enough to do.
02/18/2011 18:33 caio bola#983
1 -p4n why on some videobots , some proxys updates CLIJUMP while attacking ( co farmer ) and others not ( COOperative) ? Whats the big deal in it?

2 - p4n my hunting is runing , my best mark was 170 in 1 fatal strike ( 60 seconds ) , with 2 katanas ( no rage skill )

is it good or i can go faster?

im using the lowest speed attack ( 1 )
02/19/2011 01:16 pro4never#984
Quote:
Originally Posted by caio bola View Post
1 -p4n why on some videobots , some proxys updates CLIJUMP while attacking ( co farmer ) and others not ( COOperative) ? Whats the big deal in it?

2 - p4n my hunting is runing , my best mark was 170 in 1 fatal strike ( 60 seconds ) , with 2 katanas ( no rage skill )

is it good or i can go faster?

im using the lowest speed attack ( 1 )
Well there's no way you are attacking every 1 millisecond so obviously there are other limiting factors.

170 ko's in 60 seconds seems really low but it seems more likely that xp just re-activated (it only takes like 100-150 ko to chain fatal). I know in my tests I was able to do around 10 ko per second fairly stable (like 500-600 ko per minute) but it all depends on if you are looting, how easy you kill monsters, how many monsters are in range and how efficient you are at moving between groups of monsters.

Ooh and rage helps :P
02/19/2011 01:50 caio bola#985
else if (attack != null && C.Hunting && moneyloot2 == null)
{
if (C.LastAttack.AddMilliseconds(C.AttackSpeed) < DateTime.Now)
{
Calculations.ShiftTarget(attack);
Packets.AtkServer(C, attack, 2);
C.X = attack.X;
C.Y = attack.Y;
C.UpdatedX = C.X;
C.UpdatedY = C.Y;
Calculations.UpdateLocal(C);
C.LastAttack = DateTime.Now;

thats my attack coding , how to make it faster?!

And what "speed action" and "speed update" do in the hunting scene? normally i dont even touch this values.
02/20/2011 04:08 caio bola#986
i need a botjail code urgent , anyone?
02/20/2011 07:09 Taugamma1968#987
Sucks! many Instrucstion,.,.,.
02/20/2011 12:06 fireTQ#988
Could you p4v to gimme the packet for Divinhear :P please :) .
02/20/2011 15:32 vicslay#989
Quote:
Originally Posted by caio bola View Post
i need a botjail code urgent , anyone?
lol
02/20/2011 16:29 pro4never#990
Quote:
Originally Posted by fireTQ View Post
Could you p4v to gimme the packet for Divinhear :P please :) .
..... useskill...

I could be incredibly mistaken but I'm confident it just involves sending the useskill packet just like I do for fatal strike except with the desired skill id, target id of either 0 or charuid (depends on the skill... fairly sure disguise would be target uid 0) and most likely X/Y of 0 also.