janfilips / blockchain-dice Goto Github PK
View Code? Open in Web Editor NEWA simple ethreum dice smart-contract utilizing random.org and oraclize
Home Page: https://cryptodice2.win
License: BSD 2-Clause "Simplified" License
A simple ethreum dice smart-contract utilizing random.org and oraclize
Home Page: https://cryptodice2.win
License: BSD 2-Clause "Simplified" License
fuck tables you'll make two ajax calls which both returns generated html tables
the result on the ajax call is html not json and we'll display this html on the web as is
/ajax/games/mine requires a parameter player_session_id (I have this generated on the index.html template for you)
Also then there is a question of whether or not we actually want to remember last player bet..
I think it will be better if we simply reset this value back to the default 0.15
is that possible to individually hide them after 5 minutes as they come in?
thank you
e.g. if numbers = [1,2,3,4] tak at kostka pristane na 4 (ted pristane na 1)
/usr/local/lib/python3.6/dist-packages/django/db/models/fields/init.py:1423: RuntimeWarning: DateTimeField Bets.created received a naive datetime (2019-01-04 18:49:34.882063) while time zone support is active
GameFinalized (address _contract)
I will take care of this one
There's a footer include at the end of the index.html -
{% include "footer.html" %}
We need this footer to be an actual footer.
I want to have a predefined list of numbers that the +/- lists through..
bet_amount = [0.01, 0.05, 0.10, 0.15, 0.25, 0.50, 0.75, 1, ....... max 10] * depending on the player balance
This is also because it takes unnecessarily long to get on say 1.0 bet, this simply needs to be allowed quicker using +/-....
someone needs to redo our tables please (!!)
we'll put in a fake "ddos protection" loader on when the website when it is first loaded..
it'll look like we're ddos protected (which is expensive)
i'll get you the logo / spinner for this..
ATTENTION: In an effort to improve user privacy, MetaMask stopped exposing user accounts to dapps if "privacy mode" is enabled on November 2nd, 2018. Dapps should now call provider.enable() in order to view and use accounts. Please see https://bit.ly/2QQHXvF for complete information and up-to-date example code.
(anonymous) @ inpage.js:1
AttributeDict({'blockHash': HexBytes('0x0000000000000000000000000000000000000000000000000000000000000000'), 'blockNumber': None, 'from': '0xdc8F20170C0946ACCF9627b3EB1513CFD1c0499f', 'gas': 200000, 'gasPrice': 20000000000, 'hash': HexBytes('0xcf5a36fbbe79195964c3aa68e35c939997bc10c5c2d7bae0c327e1e9c4d74285'), 'input': '0x27dc297e0a37377349322444b2d1f886a8bc692b4d9cf13e978c0e525f757760b826223c00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000002360a000000000000000000000000000000000000000000000000000000000000', 'nonce': 230784, 'r': HexBytes('0x9c22d11279c39c6c5cb2ae10fbee262ecc928fceec84d8ceff1900e13806cbd7'), 's': HexBytes('0x1d632b71927dda08c6f3a38d073eef09dd7d8a9e180279b6fad03a111be29f33'), 'to': '0x9110C5e8F019783f6B361f704cb436825B708cda', 'transactionIndex': 0, 'v': 27, 'value': 0})
WinningNumber 0xcf5a36fbbe79195964c3aa68e35c939997bc10c5c2d7bae0c327e1e9c4d74285
oracle_query_id 0x0a37377349322444b2d1f886a8bc692b4d9cf13e978c0e525f757760b826223c
player 0xeacd131110FA9241dEe05ccf3e3635D12f629A3b
bet_number [1, 6, 3]
win_number 0
bet_amount 0.5
win_amount 0
wow the win_number we received was 0 wtf?
We're adding one more event "Congratulations you win"..
These are all one-off messages and you'll get them on /ajax/notifications call (you'd need to provide the player_session_id on the input .. it's simple, I will talk you through this..
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.