Results 1 to 9 of 9

Thread: Can I check the declaration of a class/object?

  1. #1
    Join Date
    Jan 2017
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default Can I check the declaration of a class/object?

    Hi,

    I'm new to the forum.

    Is there a way to check the interface of TPoint. Like what are their attributes?

    I tried searching in Simba and the forums but couldn't find. Thanks!

  2. #2
    Join Date
    Oct 2012
    Posts
    1,258
    Mentioned
    40 Post(s)
    Quoted
    588 Post(s)

    Default

    Here's some info on TPoints, from a [fantastic] rs3 scripting guide.
    Quote Originally Posted by The Mayor View Post
    TPoint

    A TPoint is a single point (i.e. a single pixel) on your screen. In the image on the left below is the backpack tab icon. In the subsequent pictures I zoom in a little bit more until you can see individual pixels. In the right hand picture, I have highlighted one pixel red - this is an example of a single TPoint.



    A TPoint is made up of 2 integers - the x and y coordinates. If you are unfamiliar with coordinates, look at this example of the RuneScape screen. The x axis goes from left to right. The y axis goes from top to bottom. Both axes start in the top left corner:



    Basically, every single individual pixel on the screen is a TPoint, which has its own x and y coordinates. TPoints are used very regularly - such as when you move your mouse to any coordinates on the screen.

    TBox

    A TBox is a box. A Tbox is made up of 2 TPoints (or 4 integers) on the top left (x1, y1) and bottom right (x2, y2) corners. TBoxes come in handy when dealing with things like bank slots, buttons, and backpack slots. You can look for certain colors within a box, or move the mouse to a random place inside the box, for example.


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

    Default

    For types that are native to Simba (such as a TPoint), you can't really view source code directly, but instead have to go to Git, or assign it to a variable such as:
    Simba Code:
    program new;

    var
      P : TPoint;
    begin
      P. //Variable name + "." will display its content
    end.

    For user sided types you can find the type declaration somewhere in the include that you are using
    Feel free to ask me any questions, I will do my best to answer them!

    Previously known as YouPee.

  4. #4
    Join Date
    Dec 2011
    Posts
    193
    Mentioned
    5 Post(s)
    Quoted
    51 Post(s)

    Default

    Quote Originally Posted by Joopi View Post
    For types that are native to Simba (such as a TPoint), you can't really view source code directly, but instead have to go to Git, or assign it to a variable such as:
    Simba Code:
    program new;

    var
      P : TPoint;
    begin
      P. //Variable name + "." will display its content
    end.

    For user sided types you can find the type declaration somewhere in the include that you are using
    Don't need to assign a variable, just type the type itself with the period.

    Simba Code:
    TPoint.

  5. #5
    Join Date
    Jan 2017
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Do you know how I can make it display its content. It doesn't do it for me

  6. #6
    Join Date
    Dec 2011
    Posts
    193
    Mentioned
    5 Post(s)
    Quoted
    51 Post(s)

    Default

    Quote Originally Posted by Khion View Post
    Do you know how I can make it display its content. It doesn't do it for me
    Manually type in "TPoint." once you hit the period it should display. If not make sure you have setup Simba correctly and updated. TPoint as said above is native to Simba so no include declarations is required (but wont mess it up either).

    If you hit 'Ctrl' + 'Space' the menu should also come up, does it?

  7. #7
    Join Date
    Jan 2017
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    Quote Originally Posted by Borland View Post
    Manually type in "TPoint." once you hit the period it should display. If not make sure you have setup Simba correctly and updated. TPoint as said above is native to Simba so no include declarations is required (but wont mess it up either).
    Ok its weird it really doesn't display. Ill reinstall I think

  8. #8
    Join Date
    Jan 2017
    Posts
    9
    Mentioned
    0 Post(s)
    Quoted
    1 Post(s)

    Default

    There was an error in my code which somehow disabled this feature. Correcting it resolved the problem. Thanks all.

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

    Default

    Yeah, improper standards tend to cause that.
    Feel free to ask me any questions, I will do my best to answer them!

    Previously known as YouPee.

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
  •