Add donate links, because I need to eat, too

This commit is contained in:
Roland Rytz 2017-04-11 23:16:35 +02:00
parent 35e484cd0e
commit dfe6e85c0c
8 changed files with 156 additions and 51 deletions

View file

@ -76867,11 +76867,11 @@ var atlas = [
]
}, {
"id": 1279,
"submitted_by": "sunnyotakuu",
"name": "Originally a gun for a Bulletkin.",
"description": "Before being overrun by pixels, there was a Bulletkin from the game 'Enter the Gungeon' residing in this area, and this was his gun.",
"website": "http://dodgeroll.com/gungeon/",
"subreddit": "/r/EnterTheGungeon/",
"submitted_by": "",
"name": "The Lost Gun",
"description": "The lost gun is an inside joke on Haven, a small Discord server.",
"website": "",
"subreddit": "",
"center": [
977.5,
900.5

View file

@ -959,8 +959,66 @@ #contributors a{
line-height: 26px;
}
#bitcoinButton{
cursor: pointer;
}
#bitcoinWindow{
display: none;
position: absolute;
z-index: 2000;
max-width: 400px;
left: calc(50% - 200px);
background-color: #444444;
border: 1px #000000 solid;
width: 100%;
text-align: center;
top: 70px;
bottom: 10px;
max-height: 500px;
overflow: auto;
}
#bitcoinWindow > *{
display: inline-block;
margin: 5px 0px;
}
#bitcoinWindow > h2{
font-weight: 200;
background-color: #555555;
width: 100%;
line-height: 1.5em;
margin: 10px 0px;
text-shadow: 1px 1px 0px #000000;
}
#bitcoinWindow input{
width: 100%;
max-width: 350px;
font-size: 14px;
background-color: #666666;
padding: 15px 3px;
text-align: center;
cursor: text;
}
#bitcoinWindow button{
padding: 10px 20px;
margin-bottom: 20px;
margin-top: 10px;
}
h2#abouth2{
font-size: 40px;
margin-bottom: 20px;
text-shadow: 2px 2px 0px #000000;
}
#bitcoinNotice{
color: #AAAAAA;
margin-top: 7px;
}

BIN
web/_img/bitcoinQR.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 532 B

View file

@ -70604,7 +70604,7 @@ var atlas = [
437.5
]
]
}, {
}, /* {
"id": 1145,
"submitted_by": "3juicypeaches",
"name": "Flag of Faroe Islands",
@ -70633,7 +70633,7 @@ var atlas = [
608.5
]
]
}, /* {
}, */ /* {
"id": 1146,
"submitted_by": "tritratrulala",
"name": "Eric Cartman",
@ -74337,7 +74337,7 @@ var atlas = [
"id": 1225,
"submitted_by": "raseksa",
"name": "Faroe Islands",
"description": "The Faroe Islands is an archipelago between the Norwegian Sea and the North Atlantic, about halfway between Norway and Iceland, 320 kilometres (200 miles) north-northwest of Scotland.",
"description": "The Faroe Island are an archipelago between the Norwegian Sea and the North Atlantic, about halfway between Norway and Iceland, 320 kilometres (200 miles) north-northwest of Scotland.",
"website": "https://en.wikipedia.org/wiki/Faroe_Islands",
"subreddit": "/r/FaroeIslands/",
"center": [

File diff suppressed because one or more lines are too long

View file

@ -29,6 +29,11 @@ var hovered = [];
var previousZoomOrigin = [0, 0];
var previousScaleZoomOrigin = [0, 0];
var backgroundCanvas = document.createElement("canvas");
backgroundCanvas.width = 1000;
backgroundCanvas.height = 1000;
var backgroundContext = backgroundCanvas.getContext("2d");
function updateLines(){
linesCanvas.width = linesCanvas.clientWidth;
@ -79,6 +84,41 @@ function updateLines(){
}
}
function renderBackground(atlas){
backgroundContext.clearRect(0, 0, canvas.width, canvas.height);
//backgroundCanvas.width = 1000 * zoom;
//backgroundCanvas.height = 1000 * zoom;
//backgroundContext.lineWidth = zoom;
backgroundContext.fillStyle = "rgba(0, 0, 0, 0.6)";
backgroundContext.fillRect(0, 0, backgroundCanvas.width, backgroundCanvas.height);
for(var i = 0; i < atlas.length; i++){
var path = atlas[i].path;
backgroundContext.beginPath();
if(path[0]){
//backgroundContext.moveTo(path[0][0]*zoom, path[0][1]*zoom);
backgroundContext.moveTo(path[0][0], path[0][1]);
}
for(var p = 1; p < path.length; p++){
//backgroundContext.lineTo(path[p][0]*zoom, path[p][1]*zoom);
backgroundContext.lineTo(path[p][0], path[p][1]);
}
backgroundContext.closePath();
backgroundContext.strokeStyle = "rgba(255, 255, 255, 0.8)";
backgroundContext.stroke();
}
}
function initView(){
var wrapper = document.getElementById("wrapper");
@ -86,11 +126,6 @@ function initView(){
var objectsContainer = document.getElementById("objectsList");
var closeObjectsListButton = document.getElementById("closeObjectsListButton");
var backgroundCanvas = document.createElement("canvas");
backgroundCanvas.width = 1000;
backgroundCanvas.height = 1000;
var backgroundContext = backgroundCanvas.getContext("2d");
var filterInput = document.getElementById("searchList");
var entriesList = document.getElementById("entriesList");
@ -282,6 +317,7 @@ function initView(){
//console.log(entry.center[1]);
zoom = 4;
renderBackground(atlas);
applyView();
zoomOrigin = [
@ -361,34 +397,6 @@ function initView(){
}
}
function renderBackground(atlas){
backgroundContext.clearRect(0, 0, canvas.width, canvas.height);
backgroundContext.fillStyle = "rgba(0, 0, 0, 0.6)";
backgroundContext.fillRect(0, 0, canvas.width, canvas.height);
for(var i = 0; i < atlas.length; i++){
var path = atlas[i].path;
backgroundContext.beginPath();
if(path[0]){
backgroundContext.moveTo(path[0][0], path[0][1]);
}
for(var p = 1; p < path.length; p++){
backgroundContext.lineTo(path[p][0], path[p][1]);
}
backgroundContext.closePath();
backgroundContext.strokeStyle = "rgba(255, 255, 255, 0.8)";
backgroundContext.stroke();
}
}
function buildObjectsList(filter, sort){
if(entriesList.contains(moreEntriesButton)){
@ -558,6 +566,7 @@ function initView(){
wrapper.className += " listHidden";
zoom = 4;
renderBackground(atlas);
applyView();
zoomOrigin = [
@ -610,6 +619,12 @@ function initView(){
}
function render(){
context.clearRect(0, 0, canvas.width, canvas.height);
//canvas.width = 1000*zoom;
//canvas.height = 1000*zoom;
context.globalCompositeOperation = "source-over";
context.clearRect(0, 0, canvas.width, canvas.height);
@ -628,10 +643,12 @@ function initView(){
context.beginPath();
if(path[0]){
//context.moveTo(path[0][0]*zoom, path[0][1]*zoom);
context.moveTo(path[0][0], path[0][1]);
}
for(var p = 1; p < path.length; p++){
//context.lineTo(path[p][0]*zoom, path[p][1]*zoom);
context.lineTo(path[p][0], path[p][1]);
}
@ -653,10 +670,12 @@ function initView(){
context.beginPath();
if(path[0]){
//context.moveTo(path[0][0]*zoom, path[0][1]*zoom);
context.moveTo(path[0][0], path[0][1]);
}
for(var p = 1; p < path.length; p++){
//context.lineTo(path[p][0]*zoom, path[p][1]*zoom);
context.lineTo(path[p][0], path[p][1]);
}
@ -665,6 +684,7 @@ function initView(){
context.globalCompositeOperation = "source-over";
context.strokeStyle = "rgba(0, 0, 0, 1)";
//context.lineWidth = zoom;
context.stroke();
}

View file

@ -57,19 +57,32 @@ <h1>The /r/place Atlas</h1>
Code by <a href="/" target="_blank" rel="author">Roland Rytz</a>. Source on <a target="_blank" href="https://github.com/RolandR/place-atlas">GitHub</a>.
</div>
<div id="bitcoinWindow">
<h2>My Bitcoin Address</h2>
<img src="./_img/bitcoinQR.png" height="300" width="300">
<input type="text" onclick="this.select();" readonly value="1DnBGYpH6HZYHvpCq3QqqtH1HxwwVe2QxN">
<br>
<button id="closeBitcoinButton">Close</button>
</div>
<div id="aboutContainer">
<a id="aboutBackButton" href="./">&lt; Back to the Atlas</a>
<div id="about">
<h2>The /r/place Atlas</h2>
<h2 id="abouth2">The /r/place Atlas</h2>
<p>This is an Atlas aiming to chart all the artworks created during the <a href="https://www.reddit.com/r/place/">/r/place</a> April's fools event on <a href="https://www.reddit.com/" target="_blank">Reddit</a> in 2017.</p>
<p>The code was developed by <a href="/" target="_blank" rel="author">Roland Rytz</a> and is available under the free <a href="https://www.gnu.org/licenses/agpl-3.0.en.html">AGPL license</a> on <a target="_blank" href="https://github.com/RolandR/place-atlas">GitHub</a>.
<p>The code was developed by <a href="/" target="_blank" rel="author">Roland Rytz</a> (<a href="mailto:roland.rytz@gmail.com">mail</a>, <a href="https://reddit.com/user/draemmli/">reddit</a>) and is available under the free <a href="https://www.gnu.org/licenses/agpl-3.0.en.html">AGPL license</a> on <a target="_blank" href="https://github.com/RolandR/place-atlas">GitHub</a>.</p>
<br>
<p>I have worked on the Atlas full-time (and more!) for almost two weeks.</p>
<p>If you'd like to support me, you can do so by <a target="_blank" href="https://paypal.me/draemmli">PayPal</a> or <a title="Click to see my address." id="bitcoinButton" role="button">Bitcoin</a>.</p>
<p>If you donate more than 10(€/$/CHF/mBTC), I'll send you a nice sticker of the Place canvas!</p>
<p id="bitcoinNotice">If you donate by Bitcoin and want a sticker, please send me a<br>message with your Bitcoin address <i>before</i> you make the transaction!</a>
<h2>How to contribute</h2>
<p>Everybody is encouraged to collaborate in mapping all of /r/place on the Atlas.</p>
<p>Please read <a href="https://reddit.com/r/placeAtlas/comments/63afic/how_to_contribute/" target="_blank">this post on reddit</a> to learn how to submit a new entry.</p>
<p>The <a href="https://reddit.com/r/placeAtlas/" target="_blank">/r/placeAtlas</a> subreddit is also the place to submit all bug reports, feature requests or questions.</p>
<h2>Contributors</h2>
<p>The Atlas would not have been possible without the help of the following 716 reddit users.</p>
<p>Thank you to everyone who contributed.</p>
<p>Thank you to everyone who submitted new entries, amended existing ones, reported bugs and just supported the project in general.</p>
<div id="contributors">
<a href="https://reddit.com/user/-Chowder-" target="_blank">-Chowder-</a>
<a href="https://reddit.com/user/-DuckMuffins-" target="_blank">-DuckMuffins-</a>
@ -792,6 +805,21 @@ <h2>Contributors</h2>
</div>
</div>
</div>
<script type="text/javascript">
document.getElementById("closeBitcoinButton").addEventListener("click", function(e){
document.getElementById("bitcoinWindow").style.display = "none";
});
document.getElementById("bitcoinButton").addEventListener("click", function(e){
document.getElementById("bitcoinWindow").style.display = "block";
});
</script>
</body>
</html>

View file

@ -181,16 +181,16 @@ <h2>Tux</h2>
<!--
<script type="text/javascript" src="./_js/pointInPolygon.js?version=1.0"></script>
<script type="text/javascript" src="./_js/atlas.js?version=1.0.50"></script>
<script type="text/javascript" src="./_js/view.js?version=1.0.4"></script>
<script type="text/javascript" src="./_js/overlap.js?version=1.0.4"></script>
<script type="text/javascript" src="./_js/draw.js?version=1.0.3"></script>
<script type="text/javascript" src="./_js/main.js?version=1.0.3"></script>
-->
<script type="text/javascript" src="./_js/minified.js?version=1.0.89"></script>
<!--
<script type="text/javascript" src="./_js/minified.js?version=1.0.90"></script>
-->
</body>