> For the complete documentation index, see [llms.txt](https://docs.blocksec.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.blocksec.com/phalcon/phalcon-explorer/simulator.md).

# Simulator

Phalcon simulator allows a user to simulate a transaction at an arbitrary position of an arbitrary block. The simulated transaction can be **viewed in Phalcon Explorer and shared with others.**

This feature can be used in multiple scenarios.&#x20;

* Users: Understand the transaction before signing it
* Developers: Debug a transaction
* Security researchers: Simulate and debug an attack transaction

## Launch the Simulator

The simulator can be launched inside a detailed transaction or the landing page of Phalcon Explorer.

&#x20;

* ![](/files/dhqWVkYJ0ILgskKBoubw)Network: Select the network. Ethereum, BSC, Arbitrum, Optimism, Avalanche, and Polygon are currently supported.
* Sender: The sender of the transaction (the `from` address)
* Receiver: The target of this transaction (the `to` address)
* Calldata: the detailed call data of this transaction. To facilitate the construction of the calldata, the call data can be specified using the contract ABI.
* Value: the value of this transaction.
* Gas Limit: The gas limit.
* Gas Price: The gas price.
* Use Pending Block: Whether the simulation occurs on the latest block or an old block specified in the `Block Number`. The default value is `False`.
* Block Number: The block number where the transaction simulates.
* Position in Block: The position inside the block.

When launching inside the transaction page, the transaction data is automatically fed into the simulator (and can be changed) for a quick simulation. This is useful when you just want to slightly change the data of an existing transaction, e.g., changing the position inside the block.

<figure><img src="/files/w8fGENvg31fX9fwyd103" alt=""><figcaption></figcaption></figure>

## Examples

In the following, we will use some examples to illustrate this feature.

### Sending Ether

We can simulate a transaction to send 200 Ether to an address, e.g., from to `vitalik.eth` `0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045`to`0xdeadbeef40e59eb8582ff949afb313e09c5815c9.`

<figure><img src="/files/U0lbNd2ujdTSgpuVgv53" alt="" width="375"><figcaption></figcaption></figure>

The simulated transaction can be viewed in Phalcon Explorer. The link to this simulated transaction can be shared with friends (the link is valid 48 hours after sharing).&#x20;

<figure><img src="/files/DfL9bV4bKO2Po4mRLLdv" alt=""><figcaption></figcaption></figure>

### Sending USDC

<figure><img src="/files/DgEF67SvLKVNdsNwEDqB" alt=""><figcaption></figcaption></figure>

When the `Receiver` is a contract, our system will get the ABI of the contract if it's verified and show the list of methods. Users can select a method to invoke in the transaction. For instance, the contract is `USDC` contract, and the method `transfer` is invoked to send USDC from the sender to the `to` value of the invocation.&#x20;

If the contract is not verified, a Local ABI can be uploaded. Of course, a raw calldata can also be used.
