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

Question I really need help finding interface id

Discussion in 'Developer Support' started by mastalewt, Jul 13, 2020.

  1. mastalewt

    Joined:
    Jul 10, 2020
    Messages:
    6
    Likes Received:
    7
    Okay guys, let's say i want to find the interface id of the wilderness warning that says "Enter wilderness" and "Don't go" how do i do that? How can i find the id of both buttons too? Any help will be greatly appreciated!

    ddds.png


    EDIT: nevermind, i just used Devkit++ and found it for anyone that have the same problem as me.
     
    #1 mastalewt, Jul 13, 2020
    Last edited: Jul 13, 2020
    Kobo likes this.
  2. Kobo

    Joined:
    Apr 1, 2018
    Messages:
    3
    Likes Received:
    0
    Was wondering the same thing, thanks!

    Edit: Just added DevKit++ but still can't figure out, can you explain how you got it?
     
    #2 Kobo, Jul 13, 2020
    Last edited: Jul 13, 2020
  3. CuppaJava

    CuppaJava cuppa.drink(java);

    Joined:
    Mar 13, 2018
    Messages:
    6,052
    Likes Received:
    1,360
    I haven't actually tested it in this instance but my first reaction would be to do something like

    Code (Text):
    1. Interfaces.newQuery().texts("Enter Wilderness").results();
    to find the button. I'm not sure why so many people like finding interface ids tbh. It speeds up your code a bit rather than querying every time, but that's pretty negligible tbh.
     
  4. Kobo

    Joined:
    Apr 1, 2018
    Messages:
    3
    Likes Received:
    0
    So if I was looking for a GE buy interface component, how would querying help? Wouldn't I get multiple results? How would I know which result matches which component?
     
  5. mastalewt

    Joined:
    Jul 10, 2020
    Messages:
    6
    Likes Received:
    7
    Okay so what i did is the following:

    Open up Devkit++, InterfaceExplorer, Click where it says "Texts" tick the "contains" one then just type in the title of your interface.

    get the number of that interface with the given results then;

    InterfaceComponent enterWild = Interfaces.newQuery().containers(XXX).filter(e -> e != null && e.getActions() != null && e.getActions().contains("Enter Wilderness")).results().first();

    this is what i did, just replace "XXX" with the numbers you get from your results.

    This is not my line of code, credits goes to the user named "Succulent".
     
    Kobo likes this.

Share This Page

Loading...