Results 1 to 15 of 15

Thread: Writing in Java

  1. #1
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default Writing in Java

    I just recently stumbled across SRL and have become interested in the prospect of writing bots once again. I've been programming in Java for a few years now, and started scripting about a year ago. I took a look at SMART's source code, and figured that I could rewrite my own version of it to accept Java-based scripts instead of Pascal (since the color buffer is handled by SMART, not Simba). However, to save myself time and help the community here, I was wondering if this would be integrable with the existing SRL framework. I could also write Pascal, but I can do so much more with Java that I feel like I would be limited :3.

    Sorry if this has already been asked, but a search yielded no information about this particular subject. Thanks!

  2. #2
    Join Date
    Feb 2011
    Location
    The Future.
    Posts
    5,600
    Mentioned
    396 Post(s)
    Quoted
    1598 Post(s)

    Default

    I've seen scar++ but never seen anyone attempt to re-write Smart to a full on java bot :S How do you plan to load it into a plugin to have simba read it? Or are u planning on writing a java version of simba? oh and smart is C++ And Java.
    I am Ggzz..
    Hackintosher

  3. #3
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Smart is in Java. The C++ parts are for integration with SCAR and Simba from what I can gather, and simply call methods (I have a runnable, very highly modified version of SMART in Eclipse right now). I would not have Simba at all, I would simply implement my own color detection methods and script handling system, but if something like this is already possible I'd love to use a system that others are using so I could contribute :s

  4. #4
    Join Date
    Jan 2009
    Location
    Turlock/LA, California
    Posts
    1,494
    Mentioned
    3 Post(s)
    Quoted
    66 Post(s)

    Default

    if i am reading his post correctly, i believe he would be creating his own bot (not simba) that utilized smart. if so, i have thought about that many times, just was always busy with college . good luck to u!

  5. #5
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    That's sort of a last resort haha. My only real objective is to be able to write scripts in Java. If I have to make my own client, so be it, but I'd rather not.

  6. #6
    Join Date
    Jan 2009
    Location
    Turlock/LA, California
    Posts
    1,494
    Mentioned
    3 Post(s)
    Quoted
    66 Post(s)

    Default

    no no no. i mean, write scripts in eclipse that can utilize smart . thats wat i meant by a bot. no need to actually have a client. thats just the pretty stuff that leachers like. but anyway, once again, i think it is a fun and great idea. best of luck to you

    EDIT: and even though i dont have too much time to spare, i will help, just ask(or pm)

  7. #7
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Alright, thanks. And I wouldn't release the client to the public, but I already have it written haha. I started the project a lil while ago with some IRL programming buddies. I'll be sure to hit you with a PM if I continue to develop

  8. #8
    Join Date
    Feb 2011
    Location
    The Future.
    Posts
    5,600
    Mentioned
    396 Post(s)
    Quoted
    1598 Post(s)

    Default

    Quote Originally Posted by Large Lamp View Post
    Alright, thanks. And I wouldn't release the client to the public, but I already have it written haha. I started the project a lil while ago with some IRL programming buddies. I'll be sure to hit you with a PM if I continue to develop

    But what would be the point of us working on it, if its not open source or public :S doesn't that defeat the purpose of a community?
    I am Ggzz..
    Hackintosher

  9. #9
    Join Date
    Apr 2007
    Posts
    581
    Mentioned
    1 Post(s)
    Quoted
    2 Post(s)

    Default

    It is possible, only thing you won't be able to do with pure java (that I can think of) is getting window handles to search a specific window like SCAR and Simba does with its DC window functions. You'd have to use JNI for that.. but it sounds like you just want to use a variation of SMART with it - so yes it'd be possible. Although IMO you're better off writing a complete rewrite of SMART in java.. its not too complicated.

    Edit: Also, to use SRL you would have to translate it to Java, unless you made a java-based PascalScript interpreter.
    Last edited by ShawnjohnSJ; 01-10-2012 at 04:15 AM.

  10. #10
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by ggzz View Post
    But what would be the point of us working on it, if its not open source or public :S doesn't that defeat the purpose of a community?
    Sorry if I wasn't clear... I would be completely open to releasing the client itself, just not the source to the entire internet public (registered users may be able to get it, as an example of what I mean by restriction). I would include a method library and everything for scripters to use to develop their own bots. At this point, I'm really deviating from SRL, and as mentioned before, I may as well write the bot from the ground up (not something I'm against..).

  11. #11
    Join Date
    Jan 2008
    Location
    10° north of Hell
    Posts
    2,035
    Mentioned
    65 Post(s)
    Quoted
    164 Post(s)

    Default

    You cannot use SMART code at all, if your project is not going to be open sawse.

    Please read SMART's license here.

    Dg's Small Procedures | IRC Quotes
    Thank Wishlah for my nice new avatar!
    Quote Originally Posted by IRC
    [22:12:05] <Dgby714> Im agnostic
    [22:12:36] <Blumblebee> :O ...you can read minds

  12. #12
    Join Date
    Jan 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Which is why I would be re-writing the entire thing. Not modifying, replacing. SMART, while admirable, is not exactly what I need anyways. It is designed to be integrated with other platforms which I do not want or need.

  13. #13
    Join Date
    Nov 2010
    Location
    Australia
    Posts
    1,472
    Mentioned
    0 Post(s)
    Quoted
    8 Post(s)

    Default

    Quote Originally Posted by Large Lamp View Post
    I just recently stumbled across SRL and have become interested in the prospect of writing bots once again. I've been programming in Java for a few years now, and started scripting about a year ago. I took a look at SMART's source code, and figured that I could rewrite my own version of it to accept Java-based scripts instead of Pascal (since the color buffer is handled by SMART, not Simba). However, to save myself time and help the community here, I was wondering if this would be integrable with the existing SRL framework. I could also write Pascal, but I can do so much more with Java that I feel like I would be limited :3.

    Sorry if this has already been asked, but a search yielded no information about this particular subject. Thanks!
    You don't need to modify SMART for it to work with other languages, its a dll, any language that can load/call dll's can use it. All you need to do is create a java version of the srl include(or something similar to simba) and voila scripts can be written in java. Also, take a look at libmml.

  14. #14
    Join Date
    Feb 2011
    Location
    The Future.
    Posts
    5,600
    Mentioned
    396 Post(s)
    Quoted
    1598 Post(s)

    Default

    Quote Originally Posted by Large Lamp View Post
    Which is why I would be re-writing the entire thing. Not modifying, replacing. SMART, while admirable, is not exactly what I need anyways. It is designed to be integrated with other platforms which I do not want or need.
    If not modifying, that would also require you to write your own colour procedures :S And upon request of the owner, would u not have to show source code in order to prove that it's not copied?

    Seems like a lot of work to me tbh. But hey I support u anyway if your doing something good. I like programs so meh.
    I am Ggzz..
    Hackintosher

  15. #15
    Join Date
    Dec 2011
    Posts
    57
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    This would b a really good idea you obviously have skill in coding

    btw, could you publish your modified version plz

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •