Stripped ProjectAlchemy Source Code

02/06/2011 08:11 pro4never#886
if(Distance to C.Path[C.PathIndex] < 7);


Should be

if(Distance to C.Path[C.PathIndex] < 7)

You do not put semi colons after if statements.
02/06/2011 08:49 denominator#887
Code:
Error	1	Embedded statement cannot be a declaration or labeled statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	25	AlchemyProxy
Error	2	) expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	25	AlchemyProxy
Error	3	Invalid expression term '.'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	29	AlchemyProxy
Error	4	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	29	AlchemyProxy
Error	5	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	30	AlchemyProxy
Error	6	Invalid expression term ')'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	51	AlchemyProxy
Error	7	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	51	AlchemyProxy
Error	8	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	52	AlchemyProxy
Error	9	Cannot implicitly convert type 'AlchemyProxy.Path' to 'bool'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	16	AlchemyProxy
Error	10	The type or namespace name 'to' could not be found (are you missing a using directive or an assembly reference?)	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	25	AlchemyProxy
Error	11	A local variable named 'C' cannot be declared in this scope because it would give a different meaning to 'C', which is already used in a 'parent or current' scope to denote something else	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	28	AlchemyProxy
Error	12	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	28	AlchemyProxy
Error	13	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	30	AlchemyProxy
Error	14	'AlchemyProxy.Path' is a 'type' but is used like a 'variable'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	30	AlchemyProxy
Error	15	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	264	50	AlchemyProxy
02/06/2011 09:37 pro4never#888
your brackets also don't match up

Code:
public static void Pathfinder (Client C, PathFinder Distance)
            {
            if (C.Recording)
            {
                
              if(Distance to C.Path[C.PathIndex] < 7); 
              {
              if(C.PathIndex + 1< C.Path.Count)
              {
                 C.PathIndex++; 
              }
              else
              {
                 C.Recording = true;
                 C.Path = new List<Coord>();
                 C.PathIndex = 0;
                 C.Path.Add(new Point(C.X, C.Y));
                 C.Path = C.Path.Reverse();
                 C.PathIndex = 1;
              }}
else{
                 Coord To = Calculations.PullWeights(MakeCoord(C.X, C.Y), C.Path[C.PathIndex]);
              } 
            }
        }
Something like that looks more like what you want.

Question though... this is an IN PATH code... why would you start recording a new path inside it? That makes no sense.

Also judging from the errors it sounds like you're trying to place this method inside another method... IE: why it won't let you declare the member C (because it's already in use within the same class/method/indentation level)
02/06/2011 09:47 denominator#889
So the "if (C.Recording)" is not needed? It was something you posted in this thread so I am just trying to get it to work lol. Still got errors >.<

Code:
Error	2	Expected class, delegate, enum, interface, or struct	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	284	23	AlchemyProxy
Error	3	Type or namespace definition, or end-of-file expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	472	5	AlchemyProxy
Error	4	Embedded statement cannot be a declaration or labeled statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	27	AlchemyProxy
Error	5	) expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	27	AlchemyProxy
Error	6	Invalid expression term '.'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	31	AlchemyProxy
Error	7	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	31	AlchemyProxy
Error	8	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	32	AlchemyProxy
Error	9	Invalid expression term ')'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	53	AlchemyProxy
Error	10	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	53	AlchemyProxy
Error	11	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	54	AlchemyProxy
Error	12	Invalid expression term 'else'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	277	15	AlchemyProxy
Error	13	; expected	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	277	19	AlchemyProxy
Error	14	Cannot implicitly convert type 'DeenGames.Utils.AStarPathFinder.PathFinder' to 'bool'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	18	AlchemyProxy
Error	15	The type or namespace name 'to' could not be found (are you missing a using directive or an assembly reference?)	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	27	AlchemyProxy
Error	16	A local variable named 'C' cannot be declared in this scope because it would give a different meaning to 'C', which is already used in a 'parent or current' scope to denote something else	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	30	AlchemyProxy
Error	17	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	30	AlchemyProxy
Error	18	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	32	AlchemyProxy
Error	19	'AlchemyProxy.Path' is a 'type' but is used like a 'variable'	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	32	AlchemyProxy
Error	20	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	261	52	AlchemyProxy
Error	21	Only assignment, call, increment, decrement, and new object expressions can be used as a statement	C:\Users\AlanKnight\Desktop\AlchemyProxy(2)\AlchemyProxy\Handlers\Bot.cs	276	15	AlchemyProxy
Can I send you my Bot.cs so you can have a look?
02/06/2011 12:03 Warlax#890
lmfao at this copy and paste thread. that code ur posting is so obviusly broken in such a simple place and u dont have any idea, which suggests u have no idea what the code is doing in the first place. try making a calculator or summit simple first before u try and dive in with a path finding method
02/06/2011 12:07 denominator#891
That`s the experience I have and I am actually trying to learn, stop criticising people who are actually TRYING to learn. Besides it was just a suggestion that was given.

HTML Code:
http://www.elitepvpers.com/forum/co2-bots-macros/877185-stripped-projectalchemy-source-code-77.html#post8753851
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int answer = 18;
            int j = 0;
            while (j < 1)
            {
                int input = int.Parse(Console.ReadLine());
                if (input > answer)
                {
                    Console.WriteLine("You`re older than 18, welcome");
                }
                else if (input < answer)
                {
                    Console.WriteLine("Too young");
                }
                 
                else
                {
                    Console.WriteLine("Good Job your 18");
                }
                
            }
                Console.WriteLine("Thank you for playing!");
                j++;
        }
    }
}
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int age = int.Parse(Console.ReadLine());
            if (age < 16)
            {
                Console.WriteLine("You can`t enter");
            }
            else if ((age >= 16) && (age <= 18))
            {
                Console.WriteLine("You can come in but can`t drink");
            }
            else if (age >= 19)
            {
                Console.WriteLine("You can drink as well");
            }
        }
    }
}
Code:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Flashy_thing
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            while (Visible)
            {
                for (int c = 0; c < 254 && Visible; c++)
                {
                    this.BackColor = Color.FromArgb(c, 255 - c, c);
                    Application.DoEvents();
                    System.Threading.Thread.Sleep(3);
                }
                for (int c = 254; c >= 0 && Visible; c--)
                {
                    this.BackColor = Color.FromArgb(c, 255 - c, c);
                    Application.DoEvents();
                    System.Threading.Thread.Sleep(3);
                }
            }
        }
    }
}
02/06/2011 17:52 pro4never#892
Re-read my suggestion... it covered the command... receiving a jump packet... and your actual bot jump code. It was NOT intended to be one method.

Think things through for a second..

.Recording indicates you are recording a path (therefor when you jump, points should be added to the path). Setting up the path/the recording bool should happen when you want it to... so it should be a command. The actual finding coords/pulling path points needs to happen to get from path point A to path point B... therefor it needs to be part of your botting code.

Simple enough.
02/06/2011 19:22 hippie#893
Quote:
Originally Posted by pro4never View Post
The 5000-5002 are the ports it listens on unless you change it. 9958 and such is what it then will connect to from the proxy.

@Kim: You can take a peek at the game server encryption, that's blowfish. Basically you have to intercept and create 2 copies of the encryption and then run the packets through each one/forward if you want them to be sent.

It shouldn't be too bad seeing as blowfish and dhkey exchanges are already in the proxy but if you aren't familiar with it it probably won't be very easy. When I first was trying to setup blowfish for my server it took me quite a long time to understand how to do it properly.
:handsdown::handsdown: kk thxns p4n 4 the info :D
02/06/2011 23:11 biancardi#894
Conquest (BR Version of CO) uses the same encryption as normal CO. . . u just have to change ur auth handle/auth response. . cuz Conquest packets r different from CO :bandit:
02/06/2011 23:47 caio bola#895
@biancardi , eh tu leandro? voce só me disse oq mudar no authresponse , nao falou nada no auth handle. cade tu no msn
02/07/2011 01:13 denominator#896
LOL@me I reread it again and see indeed it was not meant to be one method but a variety of things to add in various areas. I have sent a message with what I have for now but that last part which you talk about in the thread has me stumped completely I have no idea where to add it but it`s still not essential, I am thoroughly enjoying the mining though :D SDGs and DBs from mines so far and not being pked is amazing lol.
02/07/2011 01:52 pro4never#897
You guys need to stop pming me. I do not offer support on this and I'm tired of getting like 4 pm's a day from ppl wanting me to fix their problems/send them stuff.
02/07/2011 02:12 denominator#898
Would rather help than just having you "fix" the problem seeing as that doesn`t actually help to learn if a "fix" is given without any knowledge of WHY it is fixed and what exactly was wrong in the first place.

It`s like being a trainee mechanic but taking your car to the garage to be fixed >.< What`s the point in trying to learn to be a mechanic if you`re just going to send the car to a garage, rather have somebody to give ideas of what`s wrong and why it`s wrong :)

Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int age = int.Parse(Console.ReadLine()); // Changes "age" to a number?
            if (age < 16)  //If person is aged 18 and under tell them no
            {
                Console.WriteLine("You can`t enter"); //tells the console to let the person know he is not allowed in
            }
            else if ((age >= 16) && (age <= 18)) //Otherwise if person is aged 16 but below 18 come in but don`t drink
            {
                Console.WriteLine("You can come in but can`t drink"); //Again tells console to let person know
            }
            else if (age >= 19) //Otherwise if 19 and above they can come in and drink
            {
                Console.WriteLine("You can drink as well"); //Console let`s person know
            }
        }
    }
}
My basic understanding of how it works, I may be wrong though but that was an explanation given online whilst learning basic stuff. Theoretically for what is already there then this is how it should be?

Code:
           public static bool NewBot(Client C)
            {
            if (C.RunBot)
            {
                if(Distance to C.ActivePath[C.ActivePath.ID] < 7)
                {
                //path found, move to next one
                if(C.ActivePath.ID + 1< C.Path.Count)
                {
                C.ActivePath.ID++;
                }
                else
                {
                C.ActivePath = C.Path.Reverse();
                C.ActivePath.ID = 1;
                }
                }
                if (!C.Hunting)
                    return true;

                Mob attack = GetClosestMonster(C); // Radius 18
                Coord To = Calculations.PullWeights(MakeCoord(C.X, C.Y), C.ActivePath[C.PathIndex]);
                Items.GroundItem moneyloot = GetClosestMoney(C);
Code:
 if (C.Recording == true)
                {
                    C.ActivePath.Points.Add(new Point(0, MakeCoord(C.X, C.Y)));
                    Packets.CliJump(XY.X, XY.Y, 156, C);
                    Packets.Jump(C, XY.X, XY.Y, 137);
                    Packets.CliJump(XY.X, XY.Y, 156, C);
02/07/2011 05:32 Santa#899
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int answer = 18;
            int j = 0;
            while (j < 1)
            {
                int input = int.Parse(Console.ReadLine());
                if (input > answer)
                {
                    Console.WriteLine("You`re older than 18, welcome");
                }
                else if (input < answer)
                {
                    Console.WriteLine("Too young");
                }
                 
                else
                {
                    Console.WriteLine("Good Job your 18");
                }
                
            }
                [COLOR="Red"]Console.WriteLine("Thank you for playing!");
                j++;[/COLOR]
        }
    }
}
Yay for unreachable code :D
02/07/2011 06:32 denominator#900
Yeah I noticed that as well but didn`t find an answer for it >.< Updated WITH reachable code lmao. The code was originally with the unreachable code so it`s not that great if it is not even explained that there might be a problem which was never actually stated :(

Makes for learning a lot harder than what it is or should be >.<

Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            int answer = 18;
            int j = 0;
            while (j < 1)
            {
                int input = int.Parse(Console.ReadLine());
                if (input > answer)
                {
                    Console.WriteLine("You`re older than 18, welcome");
                }
                else if (input < answer)
                {
                    Console.WriteLine("Too young");
                }

                else
                {
                    Console.WriteLine("Good Job your 18");
                }
                Console.WriteLine("Thank you for playing!");
                j++;
            }
            
        }
    }
}