Method for smart contract state transition