From 8e50b1252b86f1422a612f8e4cb7f42fd267313d Mon Sep 17 00:00:00 2001 From: OKtoshi Date: Sat, 31 Oct 2015 04:59:49 -0500 Subject: [PATCH] OKCash OK updt --- encompass-mercury.conf.sample | 6 ++++++ src/chains/okcash.py | 18 ++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 src/chains/okcash.py diff --git a/encompass-mercury.conf.sample b/encompass-mercury.conf.sample index 42d8aec..73e75a9 100644 --- a/encompass-mercury.conf.sample +++ b/encompass-mercury.conf.sample @@ -63,3 +63,9 @@ coind_user = dogedrpcuser coind_password = rpcpassword coind_host = localhost coind_port = 107337 + +[ok] +coind_user = okrpcuser +coind_password = rpcpassword +coind_host = localhost +coind_port = 6969 diff --git a/src/chains/okcash.py b/src/chains/okcash.py new file mode 100644 index 0000000..7cd0fa2 --- /dev/null +++ b/src/chains/okcash.py @@ -0,0 +1,18 @@ +import cryptocur +from cryptocur import chainhook + +class Currency(cryptocur.CryptoCur): + p2pkh_version = 55 + p2sh_version = 28 + genesis_hash = '0000046309984501e5e724498cddb4aff41a126927355f64b44f1b8bba4f447e' + + coin_name = 'OKCash' + code = 'OK' + + @chainhook + def transaction_parse_fields(self, vds, is_coinbase, fields): + timestamp = ('timestamp', vds.read_int32, True) + fields.insert(1, timestamp) + + irc_nick_prefix = 'EL_' + irc_channel = '#okcash' \ No newline at end of file