How to get the predicates input index from the global state during a transaction

fn predicate_input_index() -> u64 {
    asm(r1) {
        gm r1 i3;
        r1: u64
    }
}

saw this in an example, but doesn’t work. how do i get the predicates input index during the transaction. inorder to derive it’s address.

Hey @shealtielanz you can have a look at the Fuel VM Instruction ser here

I believe you are looking for the opcode 0x20B, let me know if that helps you.