Skip to content

Instantly share code, notes, and snippets.

@danaabs
Created October 5, 2016 19:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danaabs/50d3bd41215091904339a92984ae9d81 to your computer and use it in GitHub Desktop.
Save danaabs/50d3bd41215091904339a92984ae9d81 to your computer and use it in GitHub Desktop.
Martian
var r = new Rune({
container: "#canvas",
width: 800,
height: 1100,
debug: true
});
//background
r.rect(0,0, r.width/2, r.height)
.fill(0)
.stroke(false)
//text
//orbit lines black
for(i = 0; i < 1000; i += 100) {
r.circle(400,200, i, i)
.fill(false)
.stroke(0)
.strokeWidth(1)
}
//orbit lines white
for(i = 0; i < 1000; i += 100) {
r.circle(400,200, i, i)
.fill(false)
.stroke(255)
.strokeWidth(.3)
}
r.text("Martian", r.width/2 + 60, r.height/2 + 90)
.fill(0)
.stroke(false)
.fontSize(35)
.textAlign("left")
.fontFamily("Copperplate")
.fontWeight("bold")
//.rotate(5, r.width/2, r.height/2 + 95)
// r.line(r.width/2 + 90, r.height/2 + 105, 660, 630)
// .stroke(0)
// //.strokeWidth(strokeThick)
// .strokeDash(4,4)
r.text("The", r.width/2 -20, r.height/2)
.fill(255)
.stroke(false)
.fontSize(35)
.textAlign("right")
.fontFamily("Copperplate")
.fontWeight("bold")
//.rotate(5, r.width/2, r.height/2)
var by_line = 180
r.text("by", r.width/2 - 20, (r.height/2) + by_line)
.fill(255)
.stroke(false)
.fontSize(22)
.textAlign("right")
.fontFamily("Copperplate")
//.fontWeight("bold")
//.rotate(5, r.width/2 - 120, (r.height/2) + 185)
r.text("Andrew", r.width/2 - 20, (r.height/2) + (by_line + 20))
.fill(255)
.stroke(false)
.fontSize(22)
.textAlign("right")
.fontFamily("Copperplate")
//.fontWeight("bold")
//.rotate(5, r.width/2 - 120, (r.height/2) + 185)
r.text("Weir", r.width/2 - 20, (r.height/2) + (by_line + 40))
.fill(255)
.stroke(false)
.fontSize(22)
.textAlign("right")
.fontFamily("Copperplate")
//.fontWeight("bold")
//.rotate(5, r.width/2 - 60, (r.height/2) + 303)
//sun
for(i = 0; i < 100; i += .1) {
r.circle(400,200, i, i)
.fill(false)
.stroke(255 - 1.5*i)
.strokeWidth(1)
//.strokeDash(".1, .03, .1")
}
//earth
r.circle(0,200, 50,50)
.fill(255)
//mars
r.circle(660, 630, 25, 25)
.fill(0)
r.draw();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment