1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Which language should I choose for creating bots? Python or C#?

Discussion in 'General Programming Chat' started by kevinlewontin, Apr 30, 2016.

  1. kevinlewontin

    kevinlewontin Registered Member

    Joined:
    Apr 25, 2016
    Messages:
    64
    Likes Received:
    32
    Hey, guys.

    I want to code bots to automate tasks. I have a rather limited knowledge of programming. I'm strong in basics and OOP concepts. Not an expert, though. I've only created console apps so far. So, I have no idea how to create bots with GUI. I did a bit of research, and I found out a lot of people in BHW suggest C#. However, some people seem to suggest Python too. I can get started with anything.

    I would like to have a few questions answered.

    1. Which language should I use and why?
    2. Which one provides the best performance?
    3. Which one is the best for multithreading?
    4. Where can I learn GUI programming quickly?
    5. What other things should I know before I start coding bots?
     
    Last edited: Apr 30, 2016
  2. june007

    june007 BANNED BANNED

    Joined:
    Sep 9, 2015
    Messages:
    359
    Likes Received:
    41
    C can be use everywhere.........
     
  3. Shirko

    Shirko Regular Member

    Joined:
    Aug 11, 2012
    Messages:
    200
    Likes Received:
    172
    Location:
    adding monkeys to my papal
    1. They are both very robust solutions for coding bots.
    2. Same performance as long as you know what you're doing.
    3. They both support multithreading.
    4. There's no "quick" way to learn anything.
    5. So many other skills which I won't go into detail here, but depending on what you need, these should be useful:

    Automating Websites
    - Network protocols (primarily HTTP)
    - Web Scraping (HTML / DOM parsing)
    - Reverse Engineering (Javascript / Network Traffic)
    - Digital Footprints (Cookies, Browser Fingerprinting, IPs, etc)

    Automating Software / Games
    - Network protocols
    - Packet Sniffing
    - API Hooking
    - Memory management
    - Reverse Engineering

    I think choosing one of these 2 languages will heavily depend on what your intentions are in terms of software design and deployment.

    Looks like you're starting from zero so this is what I -again- * I * would do in your situation which isn't necessarily the right option for everyone:

    Are you coding a private tool only for yourself?
    > No GUI? > Python
    > GUI - Desktop Based? > C# or Python (depending on target platform and desired GUI - although both can be multi-platform)
    > GUI - Web Based? > Python + Django

    Are you coding a tool that you want to distribute in the future?
    > Desktop Based? > C# or Python (note that both languages can be easily disassembled and cracked)
    > Web Based - Scalable? Python + Django + Celery

    Choosing between Desktop (client-side) and Web Based (server-side) will depend on things like:
    - Whether or not you want your code to be reverse engineered and cracked.
    - Whether or not you can host the whole tool & processing on your servers.
    - Whether or not your target audience want to host their own copy of the software.

    Hope that helps.
     
    • Thanks Thanks x 6
  4. norkodeo

    norkodeo Jr. VIP Jr. VIP

    Joined:
    Feb 1, 2014
    Messages:
    809
    Likes Received:
    196
    Location:
    Europe
    Fortran :whistle:
     
  5. kevinlewontin

    kevinlewontin Registered Member

    Joined:
    Apr 25, 2016
    Messages:
    64
    Likes Received:
    32
    Is there any way to not get your bot crack3d? I want to make money off of coding bots. Crackabl3 bots doesn't make much money, right?
     
  6. Shirko

    Shirko Regular Member

    Joined:
    Aug 11, 2012
    Messages:
    200
    Likes Received:
    172
    Location:
    adding monkeys to my papal
    As a rule of thumb, anything that runs on client-side (e.g. your computer) can be reverse engineered and manipulated. There's no point in fighting crackers, no matter what you do, you can't win. If you think you can, well... Adobe might be interested in buying your licensing system because since 1982 they have yet to come up with a viable so- called "anti cracking solution".

    What you can do is design your system wisely in a way that it depends, as much as possible, on server-side programming. This means fully web based tools or maybe desktop tools that rely on dynamic data pulled from your server on a daily basis.

    Crackable bots are still profitable, if not check the marketplace, most of the tools being sold there are easily crackable. People still buy their license because:

    * they want to support the developer
    * they are scared of downloading infected cracks
    * they need daily/weekly updates and support

    The latter seems to be a pretty popular business model nowadays. You need to find a way to provide value to your customers on a daily basis and they will surely purchase your license.
     
    • Thanks Thanks x 2
  7. kevinlewontin

    kevinlewontin Registered Member

    Joined:
    Apr 25, 2016
    Messages:
    64
    Likes Received:
    32
    I guess I must develop bots in C# and a server-side scripting language then. I know a little bit of PHP and NodeJS. Not everything. But enough to get up and running soon. Which one do you suggest?
     
    Last edited: May 1, 2016
  8. BrianKu

    BrianKu Newbie

    Joined:
    May 1, 2016
    Messages:
    6
    Likes Received:
    0
    There are only 10 kinds of people in this world: those who know binary and those who don?t. ;)
     
  9. hajroboss

    hajroboss Registered Member

    Joined:
    Aug 11, 2015
    Messages:
    86
    Likes Received:
    30
    LoL, I had Fortran in my middle school, most useless shit :D
     
  10. DesignCamp

    DesignCamp Junior Member

    Joined:
    Dec 27, 2015
    Messages:
    122
    Likes Received:
    39
    I write my bots in pyhton simply because I put them on my raspberry pi and use crons to trigger them, I don't need a GUI for them. I'm thinking of creating one using Windows IoT and C#, but haven't had the time to create one. I think that C# offers a bit more protection against cracks and the drag and drop IDE in visual studio is really good when you want a GUI for your bots.
     
  11. Netro

    Netro Junior Member

    Joined:
    Jun 12, 2015
    Messages:
    107
    Likes Received:
    27
    Occupation:
    Baka Dev.
    For GUI go for C#.
    For Console go for Python.
    For speed go for one of them.

    Anyway, even thought Python is recommended for such things, I'd go for C# for multiple reasons.
     
  12. globalanomaly

    globalanomaly Newbie

    Joined:
    May 8, 2016
    Messages:
    10
    Likes Received:
    0
    Gender:
    Male
    Location:
    Northern California
    It wouldn't be too very difficult to make a GUI using something like Django, though.
     
  13. WhereIsMyMoney

    WhereIsMyMoney Newbie

    Joined:
    Apr 7, 2016
    Messages:
    28
    Likes Received:
    11
    Talking about bots and GUI I thought about using Go and as for GUI just run a local http server the moment the bot is launched and server all GUI in a browser. For me, web technology is the ultimate solution for GUI :)
     
  14. kahuna74

    kahuna74 Regular Member

    Joined:
    Aug 19, 2014
    Messages:
    270
    Likes Received:
    102
    Gender:
    Male
    Occupation:
    Software Developer
    Location:
    Grand Rapids, MI
    Python is easier, and if you're targeting more than just Microsoft Windows, it's what you're going to want to use given those two choices.

    C# is a more advanced language though, and in my opinion has better multithreaded/async features than python which go a long way when writing bots.

    I write a LOT of Ruby code, but I write almost all of my bots in Java/Clojure because parallel and async are so much better.
     
  15. kctnky

    kctnky Registered Member

    Joined:
    Dec 26, 2014
    Messages:
    65
    Likes Received:
    15
    C rocks. You can compile your code for Linux as though Linux systems cost cheaper if you think about growing your business to very large scales. Java may be alternative for portability if you are a person who likes easy-coding.

    But my favourite one is C#.
     
  16. pasdoy

    pasdoy Power Member

    Joined:
    Jul 17, 2008
    Messages:
    785
    Likes Received:
    245
    This is also how I work. Take a look at atom.io
     
  17. CommonCents

    CommonCents Registered Member

    Joined:
    Apr 20, 2016
    Messages:
    77
    Likes Received:
    11
    I would go with Python - it's just simplier so a lot less headaches
     
  18. 0xxi3

    0xxi3 Jr. VIP Jr. VIP

    Joined:
    Mar 25, 2016
    Messages:
    238
    Likes Received:
    84
    Gender:
    Male
    Occupation:
    Collecting Government Benefits
    Location:
    SJW Kingdom
    Choose whatever language. The hard part won't be learning the language itself (although it depends on your previous programming experience). The hard part will be everything else. As Shirko already pointed out, there are many skills that you will need to obtain before you can make a bot; especially a bot that you can sell to other people.

    Just to answer some of your questions.
    If you are very new to programming, use Python. It's just great. Python is a megahyped language for beginners.
    However, if you have any solid experience in programming, choose whatever you like, seriously, it won't matter, because:

    - You won't have to care about performance, you aren't making a resource-heavy application
    - Both languages offer solid abstractions, you won't have to care about pointers or memory management
    - Both C# and Python have a good knowledge base, anything from Stackoverflow threads to docs and guides
    - Both support multithreading.

    If you want to write a GUI for Win systems quickly, C# is the way to go.

    P.S. my five cents on your concerns about application security. Every system can be cracked, don't be bothered by making your application secure, it will only make things harder both for you and your future customers.
     
  19. 5zz

    5zz Newbie

    Joined:
    May 23, 2016
    Messages:
    45
    Likes Received:
    15
    Wait, what? Why should he not bother about application security? Let's say he had an API, then you would tell him to leave the doors open? "Every system can be cracked" - yes, but it doesn't mean you should not bother at all, you can lose money by laziness and no one wants that. Okay, I know he's a beginner, but you said "future customers", so I assume you're talking about selling an (insecure) application.
     
  20. 0xxi3

    0xxi3 Jr. VIP Jr. VIP

    Joined:
    Mar 25, 2016
    Messages:
    238
    Likes Received:
    84
    Gender:
    Male
    Occupation:
    Collecting Government Benefits
    Location:
    SJW Kingdom
    I am talking about goofing around with a custom DRM when you are a beginner, not about leaving an unprotected databse on :3306.