Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 22 from a total of 22 transactions
Transaction Hash |
Method
|
Block
|
From
|
To
|
|||||
---|---|---|---|---|---|---|---|---|---|
Create Kitties | 5854598 | 2330 days ago | IN | 0 ETH | 0.00756986 | ||||
Create Kitties | 5853634 | 2330 days ago | IN | 0 ETH | 0.00109835 | ||||
Birth Kitty | 5851866 | 2330 days ago | IN | 0 ETH | 0.00013101 | ||||
Create Kitties | 5851582 | 2330 days ago | IN | 0 ETH | 0.00341337 | ||||
Create Kitties | 5851321 | 2330 days ago | IN | 0 ETH | 0.00158874 | ||||
Create Kitties | 5851145 | 2330 days ago | IN | 0 ETH | 0.01444786 | ||||
Create Kitties | 5851017 | 2330 days ago | IN | 0 ETH | 0.00659086 | ||||
Create Kitties | 5850849 | 2330 days ago | IN | 0 ETH | 0.01115243 | ||||
Create Kitties | 5850822 | 2330 days ago | IN | 0 ETH | 0.13787607 | ||||
Create Kitties | 5850807 | 2330 days ago | IN | 0 ETH | 0.00542091 | ||||
Create Kitties | 5850791 | 2330 days ago | IN | 0 ETH | 0.00143189 | ||||
Create Kitties | 5849897 | 2330 days ago | IN | 0 ETH | 0.00451994 | ||||
Birth Kitty | 5849879 | 2330 days ago | IN | 0 ETH | 0.00002183 | ||||
Set Action Contr... | 5849649 | 2331 days ago | IN | 0 ETH | 0.00004393 | ||||
Set Action Contr... | 5849633 | 2331 days ago | IN | 0 ETH | 0.00004393 | ||||
Create Kitties | 5849575 | 2331 days ago | IN | 0 ETH | 0.00170668 | ||||
Create Kitties | 5849566 | 2331 days ago | IN | 0 ETH | 0.00019859 | ||||
Create Kitties | 5834826 | 2333 days ago | IN | 0 ETH | 0.00096472 | ||||
Set Kitty Token ... | 5828786 | 2334 days ago | IN | 0 ETH | 0.00017222 | ||||
Set Kitty Contra... | 5828704 | 2334 days ago | IN | 0 ETH | 0.00008727 | ||||
Set Kitty Token ... | 5828702 | 2334 days ago | IN | 0 ETH | 0.0000874 | ||||
0x60606040 | 5828687 | 2334 days ago | IN | 0 ETH | 0.0017708 |
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
CaptainKitty
Compiler Version
v0.4.21+commit.dfe3193c
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity)
/** *Submitted for verification at Etherscan.io on 2018-06-21 */ pragma solidity ^0.4.18; /* ==================================================================== */ /* Copyright (c) 2018 The Priate Conquest Project. All rights reserved. /* /* https://www.pirateconquest.com One of the world's slg games of blockchain /* /* authors [email protected]/[email protected] /* /* ==================================================================== */ contract KittyInterface { function tokensOfOwner(address _owner) external view returns(uint256[] ownerTokens); function ownerOf(uint256 _tokenId) external view returns (address owner); function balanceOf(address _owner) public view returns (uint256 count); } interface KittyTokenInterface { function transferFrom(address _from, address _to, uint256 _tokenId) external; function setTokenPrice(uint256 _tokenId, uint256 _price) external; function CreateKittyToken(address _owner,uint256 _price, uint32 _kittyId) public; } contract CaptainKitty { address owner; //event event CreateKitty(uint _count,address _owner); KittyInterface kittyContract; KittyTokenInterface kittyToken; /// @dev Trust contract mapping (address => bool) actionContracts; mapping (address => uint256) kittyToCount; mapping (address => bool) kittyGetOrNot; function CaptainKitty() public { owner = msg.sender; } modifier onlyOwner() { require(msg.sender == owner); _; } function setActionContract(address _actionAddr, bool _useful) public onlyOwner { actionContracts[_actionAddr] = _useful; } modifier onlyAccess() { require(actionContracts[msg.sender]); _; } function setKittyContractAddress(address _address) external onlyOwner { kittyContract = KittyInterface(_address); } function setKittyTokenAddress(address _address) external onlyOwner { kittyToken = KittyTokenInterface(_address); } function createKitties() external payable { uint256 kittycount = kittyContract.balanceOf(msg.sender); require(kittyGetOrNot[msg.sender] == false); if (kittycount>=99) { kittycount=99; } if (kittycount>0 && kittyToCount[msg.sender]==0) { kittyToCount[msg.sender] = kittycount; kittyGetOrNot[msg.sender] = true; for (uint i=0;i<kittycount;i++) { kittyToken.CreateKittyToken(msg.sender,0, 1); } //event CreateKitty(kittycount,msg.sender); } } function getKitties() external view returns(uint256 kittycnt,uint256 captaincnt,bool bGetOrNot) { kittycnt = kittyContract.balanceOf(msg.sender); captaincnt = kittyToCount[msg.sender]; bGetOrNot = kittyGetOrNot[msg.sender]; } function getKittyGetOrNot(address _addr) external view returns (bool) { return kittyGetOrNot[_addr]; } function getKittyCount(address _addr) external view returns (uint256) { return kittyToCount[_addr]; } function birthKitty() external onlyAccess payable { } }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"getKittyGetOrNot","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"birthKitty","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[{"name":"_addr","type":"address"}],"name":"getKittyCount","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_address","type":"address"}],"name":"setKittyContractAddress","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_actionAddr","type":"address"},{"name":"_useful","type":"bool"}],"name":"setActionContract","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"createKitties","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[{"name":"_address","type":"address"}],"name":"setKittyTokenAddress","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"getKitties","outputs":[{"name":"kittycnt","type":"uint256"},{"name":"captaincnt","type":"uint256"},{"name":"bGetOrNot","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"_count","type":"uint256"},{"indexed":false,"name":"_owner","type":"address"}],"name":"CreateKitty","type":"event"}]
Contract Creation Code
6060604052341561000f57600080fd5b60008054600160a060020a033316600160a060020a03199091161790556105618061003b6000396000f3006060604052600436106100745763ffffffff60e060020a60003504166302fbe0d5811461007957806303bf8e70146100ac5780633dc60e52146100b65780635f4623f1146100e75780636fb642de146101065780637ef3bb631461012a578063cb67ce0414610132578063fb2dfa4514610151575b600080fd5b341561008457600080fd5b610098600160a060020a036004351661018a565b604051901515815260200160405180910390f35b6100b46101a8565b005b34156100c157600080fd5b6100d5600160a060020a03600435166101d1565b60405190815260200160405180910390f35b34156100f257600080fd5b6100b4600160a060020a03600435166101ec565b341561011157600080fd5b6100b4600160a060020a03600435166024351515610236565b6100b461027c565b341561013d57600080fd5b6100b4600160a060020a0360043516610449565b341561015c57600080fd5b610164610493565b604051928352602083019190915215156040808301919091526060909101905180910390f35b600160a060020a031660009081526005602052604090205460ff1690565b600160a060020a03331660009081526003602052604090205460ff1615156101cf57600080fd5b565b600160a060020a031660009081526004602052604090205490565b60005433600160a060020a0390811691161461020757600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60005433600160a060020a0390811691161461025157600080fd5b600160a060020a03919091166000908152600360205260409020805460ff1916911515919091179055565b6001546000908190600160a060020a03166370a082313360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156102d157600080fd5b5af115156102de57600080fd5b5050506040518051600160a060020a03331660009081526005602052604090205490935060ff1615905061031157600080fd5b6063821061031e57606391505b6000821180156103445750600160a060020a033316600090815260046020526040902054155b156104455750600160a060020a033316600090815260046020908152604080832084905560059091528120805460ff191660011790555b8181101561040157600254600160a060020a031663ae5c1816336000600160405163ffffffff85811660e060020a028252600160a060020a0394909416600482015260248101929092529091166044820152606401600060405180830381600087803b15156103e957600080fd5b5af115156103f657600080fd5b50505060010161037b565b7f864010974a23db6786df104bb52e77e71ab4abfce20c45773d7bf2c14f8012a98233604051918252600160a060020a031660208201526040908101905180910390a15b5050565b60005433600160a060020a0390811691161461046457600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60015460009081908190600160a060020a03166370a082313360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156104ea57600080fd5b5af115156104f757600080fd5b5050506040518051600160a060020a033316600090815260046020908152604080832054600590925290912054919690955060ff90911693509150505600a165627a7a7230582013bbb20ad933eca4b1a109a6155cfb1dcbc56866459177962ca39414454a3de50029
Deployed Bytecode
0x6060604052600436106100745763ffffffff60e060020a60003504166302fbe0d5811461007957806303bf8e70146100ac5780633dc60e52146100b65780635f4623f1146100e75780636fb642de146101065780637ef3bb631461012a578063cb67ce0414610132578063fb2dfa4514610151575b600080fd5b341561008457600080fd5b610098600160a060020a036004351661018a565b604051901515815260200160405180910390f35b6100b46101a8565b005b34156100c157600080fd5b6100d5600160a060020a03600435166101d1565b60405190815260200160405180910390f35b34156100f257600080fd5b6100b4600160a060020a03600435166101ec565b341561011157600080fd5b6100b4600160a060020a03600435166024351515610236565b6100b461027c565b341561013d57600080fd5b6100b4600160a060020a0360043516610449565b341561015c57600080fd5b610164610493565b604051928352602083019190915215156040808301919091526060909101905180910390f35b600160a060020a031660009081526005602052604090205460ff1690565b600160a060020a03331660009081526003602052604090205460ff1615156101cf57600080fd5b565b600160a060020a031660009081526004602052604090205490565b60005433600160a060020a0390811691161461020757600080fd5b6001805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60005433600160a060020a0390811691161461025157600080fd5b600160a060020a03919091166000908152600360205260409020805460ff1916911515919091179055565b6001546000908190600160a060020a03166370a082313360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156102d157600080fd5b5af115156102de57600080fd5b5050506040518051600160a060020a03331660009081526005602052604090205490935060ff1615905061031157600080fd5b6063821061031e57606391505b6000821180156103445750600160a060020a033316600090815260046020526040902054155b156104455750600160a060020a033316600090815260046020908152604080832084905560059091528120805460ff191660011790555b8181101561040157600254600160a060020a031663ae5c1816336000600160405163ffffffff85811660e060020a028252600160a060020a0394909416600482015260248101929092529091166044820152606401600060405180830381600087803b15156103e957600080fd5b5af115156103f657600080fd5b50505060010161037b565b7f864010974a23db6786df104bb52e77e71ab4abfce20c45773d7bf2c14f8012a98233604051918252600160a060020a031660208201526040908101905180910390a15b5050565b60005433600160a060020a0390811691161461046457600080fd5b6002805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b60015460009081908190600160a060020a03166370a082313360405160e060020a63ffffffff8416028152600160a060020a039091166004820152602401602060405180830381600087803b15156104ea57600080fd5b5af115156104f757600080fd5b5050506040518051600160a060020a033316600090815260046020908152604080832054600590925290912054919690955060ff90911693509150505600a165627a7a7230582013bbb20ad933eca4b1a109a6155cfb1dcbc56866459177962ca39414454a3de50029
Swarm Source
bzzr://13bbb20ad933eca4b1a109a6155cfb1dcbc56866459177962ca39414454a3de5
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.