Remix

Below we show a quick Solidity smart contract, compiled using Remix(https://remix.ethereum.org/) and deployed through the Script web wallet (https://wallet.script.tv/).
In this example, we’ll make a limited edition SRC-20 token (SRC-20 equivalent, SRC stands for Script Network Token) on top of Script blockchain to denote the early adopters of Script protocol — the Script supporters who have run Lightning Nodes on the Script testnet.
We can start with a basic token smart contract.We can start with a basic token smart contract.
To compile this Solidity code, we can use the Remix Ethereum compiler(https://remix.ethereum.org/). (Another benefit of using an Ethereum-compatible VM for Script — much of the extensive Ethereum dev tools can be used here as well.)
We’ll walk through this process step by step, but for more in-depth instructions on using Remix, see the documentation here (https://remix-ide.readthedocs.io/en/latest/index.html).
Next, create a new file in Remix. Once the code is entered, click the Solidity Compiler button on the far left.
Next, you’ll want to set the Compiler to required version used in solidity code, and in the Contract field “Contract_Name” is selected. Then click the blue button that says “Contract_Name.sol”.
Your smart contract is now compiled! Now for the moment let’s go over to the Script wallet.
Next, open your Script wallet or create a new one. Once you’re logged in, select the Contract tab from the wallet menu.
The Contract screen will ask you for two outputs from your compiled smart contract: the ABI/JSON Interface, and the Byte Code. Go back to Remix, and you can copy both by clicking the buttons “ABI” and “Bytecode” under the “Compilation Details” button. Then, paste each into the Script wallet and click “Deploy Contract”.
Your contract is now live on the Script Testnet. Make sure to record your contract address.
Now you can try out the different functions for this contract, for example:
totalSupply
symbol
transfer
balanceOf
Other users can sign in to the Smart Contracts and interact with your smart contract as well. They will need to know both the contract address and the ABI/JSON interface data. That’s a bit unwieldy, but an example of one of the ease-of-use improvements that will come with future versions of the Script smart contract interface (for example, that ABI data could be made to auto-populate when a given smart contract address is entered).
Last modified 18d ago