i saw an other example
var msg = begin_cell()
.store_uint(0x18, 6)
.store_uint(2,2)
.store_uint(0,9)
.store_uint(nft,256)
.store_coins(amount)
.store_uint(1, 1 + 4 + 4 + 64 + 32 + 1 + 1)
.store_ref(begin_cell()
.store_uint(op::transfer(), 32)
.store_uint(query_id, 64)
.store_slice(to) ;; new_owner_address
.store_slice(to) ;; response_address
.store_int(0, 1) ;; empty custom_payload
.store_coins(0) ;; forward amount to new_owner_address
.store_int(0, 1) ;; empty forward_payload
.end_cell()
);
send_raw_message(msg.end_cell(), mode);
}
what i dont understand is, here nft is a int, how does that work? i have nft address how do i put it as int?
Feb 10, 2023, 8:56 PM
Here it looks like accountID.
According to TL-B scheme Message address for internal message is:
addr_std$10 anycast:(Maybe Anycast)
workchain_id:int8 address:bits256 = MsgAddressInt;
and in this example:
....
.store_uint(2,2) ;; $10
.store_uint(0,9) ;; Maybe = (0,1) + workchain_id = (0,8)
.store_uint(nft,256) ;; address
...
According to TL-B scheme Message address for internal message is:
addr_std$10 anycast:(Maybe Anycast)
workchain_id:int8 address:bits256 = MsgAddressInt;
and in this example:
....
.store_uint(2,2) ;; $10
.store_uint(0,9) ;; Maybe = (0,1) + workchain_id = (0,8)
.store_uint(nft,256) ;; address
...
Feb 10, 2023, 9:10 PM
@iftryalexg this works
thanks anyway
Feb 10, 2023, 10:15 PM