Results 1 to 11 of 11

Thread: [Help with selecting this NPC] Roat Pkz RSPS - New Programmer

  1. #1
    Join Date
    Nov 2015
    Location
    Glasgow, Scotland
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default [Help Please] setupSrl seems to close my client..

    Hi there, I'm currently working towards learning this confusing language that is Pascal/Simba haha and currently i'm stumped at this, if anyone could help it would be amazing.



    Simba Code:
    program EatFood;
         {$I SRL-6/srl.simba}
    var

    food, x, y : integer;


    procedure clickFood;
    begin
    Food := DTMFromString('mggAAAHicY2NgYHBhYmDwBWJPIHYCYiso/RwodwOIXwHxRwYI/y4QX9i5HUgyYmAuBuwAUyUEQwAAYYQJXg==');
    findDTM(food, x, y, 555, 215, 737, 465);
    movemouse(x, y);
    clickmouse(x, y, mouse_left);
    end;

    begin
    activateclient;
    setupsrl;
    clickFood;

    freeDTM(food)
    end.


    If i remove the setupsrl; it works fine, it finds my food and clicks it. However, when i setupsrl it just closes my client.

    PLS EXPLAIN

  2. #2
    Join Date
    Mar 2013
    Posts
    1,010
    Mentioned
    35 Post(s)
    Quoted
    620 Post(s)

    Default

    I think ActivateClient will close the smart client, try removing that.
    Edit: Are you using SMART or another client e.g. OSBuddy?
    Last edited by Harrier; 11-09-2015 at 12:27 PM.
    #slack4admin2016
    <slacky> I will build a wall
    <slacky> I will ban reflection and OGL hooking until we know what the hell is going on

  3. #3
    Join Date
    Nov 2015
    Location
    Glasgow, Scotland
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    I'm not using SMART, using the RSPS's custom client.jar. I have my program fully working so to be honest my question now is, Why would i use SRL? I thought SRL made this easier..?

  4. #4
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Kieran x Dzr View Post
    I'm not using SMART, using the RSPS's custom client.jar. I have my program fully working so to be honest my question now is, Why would i use SRL? I thought SRL made this easier..?
    SRL makes scripting with Runescape easier. It is not designed to work with any RSPS.

  5. #5
    Join Date
    Nov 2015
    Location
    Glasgow, Scotland
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    Quote Originally Posted by BMWxi View Post
    SRL makes scripting with Runescape easier. It is not designed to work with any RSPS.
    Ah ok, thank you, really new to this type of programming, well new-ish to programming in a whole. Do you have any suggestions how I can detect an NPC on a server that moves about? I was thinking a FindColor or DTM but they'd both fuck up if the npc was turned around..

  6. #6
    Join Date
    Jun 2012
    Posts
    4,867
    Mentioned
    74 Post(s)
    Quoted
    1663 Post(s)

    Default

    Quote Originally Posted by Kieran x Dzr View Post
    Ah ok, thank you, really new to this type of programming, well new-ish to programming in a whole. Do you have any suggestions how I can detect an NPC on a server that moves about? I was thinking a FindColor or DTM but they'd both fuck up if the npc was turned around..
    The most common way would be making a TPointArray with FindColorsTolerance and then filtering out things that don't match. If you upload some screenshots it would be easier to see how well this would work.

  7. #7
    Join Date
    Mar 2006
    Location
    Behind you
    Posts
    3,193
    Mentioned
    61 Post(s)
    Quoted
    63 Post(s)

    Default

    I Agree with the above post. I will add that you probably should post in the correct section and not just post anywhere.

    Moved.

    "Sometimes User's don't need the Answer spelled out with Code. Sometimes all they need is guidance and explanation of the logic to get where they are going."

  8. #8
    Join Date
    Nov 2015
    Location
    Glasgow, Scotland
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default [Help with selecting this NPC] Roat Pkz RSPS - New Programmer

    Hi there, I've only been doing this for a couple of days but already know kind of what i'm doing. I've so far made a script that can do a fair bit but i'm now trying to work out how to get it to find an NPC that moves around. I don't want just a straight answer that I can copy and paste so if you're going to try helping, can you try explaining it so that I learn, rather than leech.

    The server is a 317 with these gfx 80480c8205ee3c1540ab4721e61d25cc.png.

    (I'm trying to make the programme kill an npc then loot the items, but I can deal with that when i'm past this first bit(in terms of combat, already got it eating, spawning, drinking ect))

  9. #9
    Join Date
    Sep 2014
    Location
    C:\Simba\
    Posts
    565
    Mentioned
    9 Post(s)
    Quoted
    71 Post(s)

    Default

    It really depends on how the NPC looks, and what include you are using.
    Is the NPC you are trying to fight anywhere in that picture? and what include are you using?
    I would personally recommend AeroLib so you can take a few functions out of there if the RSPS' graphics aren't too much updated.
    Feel free to ask me any questions, I will do my best to answer them!

    Previously known as YouPee.

  10. #10
    Join Date
    May 2012
    Location
    Glorious Nippon
    Posts
    1,011
    Mentioned
    50 Post(s)
    Quoted
    505 Post(s)

    Default

    Take a look at Simba's color finding functions: http://docs.villavu.com/simba/script...inding-methods

    And as Joopi said, take a look at what people are currently using for OSR. You should be able to tweak the functions so that they work for you.
    I use SRL-6 for DarkScape and it works really well. I just had to override a few functions.

  11. #11
    Join Date
    Nov 2015
    Location
    Glasgow, Scotland
    Posts
    13
    Mentioned
    0 Post(s)
    Quoted
    6 Post(s)

    Default

    Quote Originally Posted by Joopi View Post
    It really depends on how the NPC looks, and what include you are using.
    Is the NPC you are trying to fight anywhere in that picture? and what include are you using?
    I would personally recommend AeroLib so you can take a few functions out of there if the RSPS' graphics aren't too much updated.
    Thanks a lot mate, The NPC has 3rd age range with a fire cape on. I'm not using any include and the server is 317.

    Quote Originally Posted by Citrus View Post
    Take a look at Simba's color finding functions: http://docs.villavu.com/simba/script...inding-methods

    And as Joopi said, take a look at what people are currently using for OSR. You should be able to tweak the functions so that they work for you.
    I use SRL-6 for DarkScape and it works really well. I just had to override a few functions.
    Going to check out the link just now and I don't think im experienced enough to be tweaking the functions of an include.. When i was using SRL-6 earlier it was just closing my client straight away...

Thread Information

Users Browsing this Thread

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

Posting Permissions

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