Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A shitty Tooltip for Shitdice .Wishing players shit luck before rolling! #10

Open
wants to merge 31 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
fbe0817
Make app.js shittier
shitdice Nov 14, 2015
e0a08ba
Extra shit API key
shitdice Nov 14, 2015
068d287
Terrible app ID
shitdice Nov 14, 2015
d35e4e5
We're shit, not untitled!
shitdice Nov 14, 2015
76bdcbe
Ah, satirical art.
shitdice Nov 14, 2015
0c5942d
Isn't it beautiful?
shitdice Nov 14, 2015
c13b959
Even better
shitdice Nov 14, 2015
1ebca11
Perfection
shitdice Nov 14, 2015
59cb31a
NOW it's perfect. Promise.
shitdice Nov 14, 2015
c4a5398
This could be gold
shitdice Nov 14, 2015
d41bfe4
This has gotta be it.
shitdice Nov 14, 2015
9f707c9
Again!
shitdice Nov 14, 2015
e915285
derp
shitdice Nov 14, 2015
755b7eb
Update custom.css
shitdice Nov 14, 2015
0e5eabb
ShitStaff
shitdice Nov 15, 2015
6dd2d3a
Code in 'ShitUser' with label 'success' (green bg)
shitdice Nov 15, 2015
f0fea97
Double semi-colon
shitdice Nov 15, 2015
7de48ed
Changed ShitOwner to red, MP ShitStaff to blue
shitdice Nov 15, 2015
ecdc768
Change favicon, had to download git for this!
Nov 15, 2015
e3fc008
(Git) Made favicon transparent
Nov 15, 2015
0125c5d
Bits -> ShitBits
shitdice Nov 15, 2015
5fcec96
Elephant Bubble
shitdice Nov 15, 2015
6920a1b
No more https warning (secure background image)
shitdice Nov 15, 2015
8e445a2
New bg image, in HTTPS!
shitdice Nov 20, 2015
89777c2
new bg
shitdice Nov 22, 2015
e2aab52
bg music upload
Nov 25, 2015
901f306
Autoplay & loop dank.mp3
shitdice Nov 25, 2015
b107344
insulting faucet/etc.
shitdice Nov 29, 2015
d1a3a76
linebreak js
shitdice Nov 29, 2015
e129e21
whatever
shitdice Nov 29, 2015
1645dae
0.5% house edge
shitdice Dec 5, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 3 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,8 @@
# untitled-dice
# Shit Dice

##### Live demo: https://untitled-dice.github.io
##### We're shit

More info (including changelog and FAQ) in the bitcointalk.org thread: https://bitcointalk.org/index.php?topic=1062680

Untitled Dice is a bare-bones bitcoin dice casino built on top of the [Moneypot.com gambling API](https://www.moneypot.com/api-docs.html) that lets anyone run their own dice site by forking this project.

Since Moneypot handles the user accounts, betting, faucet, and chat, Untitled Dice does not need a server of its own. It's fully client-side (just some javascript files), so it can be hosted anywhere including Github.

Moneypot even handles the bankroll. Profits are split between you, Moneypot, and Moneypot's investors. See: <https://www.moneypot.com/investment>.

![Screenshot](http://i.imgur.com/dTwOR01.png)

## Run your own dice site

If you want to run your own dice casino, all you need to do is clone/fork this project, create an app at Moneypot (https://www.moneypot.com/apps/new), and set the `config.app_id` at the top of the `app.js` file.

## Host it on Github

1. Fork this project
2. Rename the repository from `untitled-dice.github.io` to `{YOUR_USERNAME}.github.io`
3. Edit the config at the top of `app.js`
4. Visit `https://{YOUR_USERNAME}.github.io`

## Run it locally (for development)

cd untitled-dice
npm install
python -m SimpleHTTPServer 5000

Then visit <http://localhost:5000>
Satirical art by DiamondCardz

## License

Expand Down
38 changes: 19 additions & 19 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

var config = {
// - Your app's id on moneypot.com
app_id: 18, // <----------------------------- EDIT ME!
app_id: 750, // <----------------------------- EDIT ME!
// - Displayed in the navbar
app_name: 'Untitled Dice',
app_name: 'Shit Dice',
// - For your faucet to work, you must register your site at Recaptcha
// - https://www.google.com/recaptcha/intro/index.html
recaptcha_sitekey: '6LfI_QUTAAAAACrjjuzmLw0Cjx9uABxb8uguLbph', // <----- EDIT ME!
redirect_uri: 'https://untitled-dice.github.io',
recaptcha_sitekey: '6Lev_RATAAAAANPSUss9BWWz0eClzv9pDf-x6AxT', // <----- EDIT ME!
redirect_uri: 'https://shitdice.github.io',
mp_browser_uri: 'https://www.moneypot.com',
mp_api_uri: 'https://api.moneypot.com',
chat_uri: '//socket.moneypot.com',
Expand All @@ -21,7 +21,7 @@ var config = {
force_https_redirect: !isRunningLocally(),
// - Configure the house edge (default is 1%)
// Must be between 0.0 (0%) and 1.0 (100%)
house_edge: 0.01,
house_edge: 0.005,
chat_buffer_size: 250,
// - The amount of bets to show on screen in each tab
bet_buffer_size: 25
Expand Down Expand Up @@ -111,13 +111,13 @@ helpers.calcNumber = function(cond, winProb) {
helpers.roleToLabelElement = function(role) {
switch(role) {
case 'ADMIN':
return el.span({className: 'label label-danger'}, 'MP Staff');
return el.span({className: 'label label-primary'}, 'MP ShitStaff');
case 'MOD':
return el.span({className: 'label label-info'}, 'Mod');
return el.span({className: 'label label-info'}, 'ShitMod');
case 'OWNER':
return el.span({className: 'label label-primary'}, 'Owner');
return el.span({className: 'label label-danger'}, 'ShitOwner');
default:
return '';
return el.span({className: 'label label-success'}, 'ShitUser');
}
};

Expand Down Expand Up @@ -725,12 +725,12 @@ var UserBox = React.createClass({
className: 'navbar-text',
style: {marginRight: '5px'}
},
(worldStore.state.user.balance / 100) + ' bits',
(worldStore.state.user.balance / 100) + ' ShitBits',
!worldStore.state.user.unconfirmed_balance ?
'' :
el.span(
{style: { color: '#e67e22'}},
' + ' + (worldStore.state.user.unconfirmed_balance / 100) + ' bits pending'
' + ' + (worldStore.state.user.unconfirmed_balance / 100) + ' ShitBits pending'
)
),
// Refresh button
Expand Down Expand Up @@ -1301,7 +1301,7 @@ var BetBoxWager = React.createClass({
style: style1,
onChange: this._onWagerChange,
disabled: !!worldStore.state.isLoading,
placeholder: 'Bits'
placeholder: 'ShitBits'
}
),
el.div(
Expand Down Expand Up @@ -1748,7 +1748,7 @@ var MyBetsTabContent = React.createClass({
el.td(
null,
helpers.round10(bet.wager/100, -2),
' bits'
' ShitBits'
),
// target
el.td(
Expand All @@ -1769,7 +1769,7 @@ var MyBetsTabContent = React.createClass({
bet.profit > 0 ?
'+' + helpers.round10(bet.profit/100, -2) :
helpers.round10(bet.profit/100, -2),
' bits'
' ShitBits'
)
);
}).reverse()
Expand Down Expand Up @@ -1849,7 +1849,7 @@ var FaucetTabContent = React.createClass({
if (!worldStore.state.user) {
return el.p(
{className: 'lead'},
'You must login to claim faucet'
'You must login to claim the faucet you fucking idiot'
);
}

Expand All @@ -1865,9 +1865,9 @@ var FaucetTabContent = React.createClass({
case 'SUCCESSFULLY_CLAIMED':
innerNode = el.div(
null,
'Successfully claimed ' + this.state.claimAmount/100 + ' bits.' +
'Successfully claimed ' + this.state.claimAmount/100 + ' ShitBits. Free money! ' +
// TODO: What's the real interval?
' You can claim again in 5 minutes.'
'You can claim again in 5 minutes, you greedy little shit.'
);
break;
case 'ALREADY_CLAIMED':
Expand Down Expand Up @@ -1932,7 +1932,7 @@ var BetRow = React.createClass({
el.td(
null,
helpers.round10(bet.wager/100, -2),
' bits'
' ShitBits'
),
// Target
el.td(
Expand Down Expand Up @@ -2043,7 +2043,7 @@ var BetRow = React.createClass({
bet.profit > 0 ?
'+' + helpers.round10(bet.profit/100, -2) :
helpers.round10(bet.profit/100, -2),
' bits'
' ShitBits'
)
);
}
Expand Down
2 changes: 1 addition & 1 deletion custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
/* The following example turns the background to yellow if you uncomment it. */

body {
/* background-color: #f1c40f; */
background-image: url("https://i.imgur.com/7ggNBjw.png");
}

Binary file added dank.mp3
Binary file not shown.
Binary file modified favicon.ico
Binary file not shown.
6 changes: 5 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
<!doctype html>
<head>
<title>Untitled Dice</title>
<title>Shit Dice</title>
<link href="node_modules/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="node_modules/bootstrap/dist/css/bootstrap-theme.min.css" rel="stylesheet">
<link href="style.css" rel="stylesheet">
<link href="custom.css" rel="stylesheet"> <!-- Recommendation: Put your CSS customizations in custom.css -->
<audio autoplay loop>
<source src="dank.mp3" type="audio/mpeg">
Your browser does not support our dank tunes.
</audio>
</head>
<body>
<div id="app"></div>
Expand Down