Star Against the Dark — 13-World

Pen-plotter orbital rosette inspired by STAR AGAINST THE DARK - a free space survivor-like roguelite by Ant Games (antgames.ai/) where 13 orbiting worlds fire conjunction arcs & alignment beams. Free, no pay to win, no sign-up, browser & Android.

STAR AGAINST THE DARK: antgames.ai/play/star-against-the-dark/ | Guide: antgames.ai/guide/star-against-the-dark/
Android GP: play.google.com/stor…s.staragainstthedark
WARSHIP WORKSHOP: antgames.ai/play/warship-workshop/#play | Guide: antgames.ai/guide/warship-workshop/
Android GP: play.google.com/stor…ames.warshipworkshop
APOGEE KEEP: antgames.ai/play/apogee-keep/ | Guide: antgames.ai/guide/apogee-keep/
BRIDGE STRESS TEST: antgames.ai/play/bridge-stress-test/ | Guide: antgames.ai/guide/bridge-stress-test/
SCARECROW SMASHER: antgames.ai/play/scarecrow-smasher/ | Guide: antgames.ai/guide/scarecrow-smasher/

Log in to post a comment.

// Star Against the Dark — 13-World Orbital Rosette
// Play free at https://antgames.ai/play/star-against-the-dark/
Canvas.setpenopacity(0.9);
const turtle = new Turtle();
function circle(cx, cy, r, segs) {
  for (let i = 0; i <= segs; i++) {
    const a = (i / segs) * Math.PI * 2;
    const x = cx + Math.cos(a) * r, y = cy + Math.sin(a) * r;
    if (i === 0) turtle.jump(x, y); else turtle.goto(x, y);
  }
}
function walk(i) {
  if (i === 0) { circle(0, 0, 10, 36); circle(0, 0, 6, 24); return true; }
  if (i <= 13) {
    const r = 14 + i * 5.6;
    circle(0, 0, r, 64);
    const a = (i * 2.39996) % (Math.PI * 2);
    circle(Math.cos(a) * r, Math.sin(a) * r, 2.5 + (i % 3) * 0.7, 18);
    if (i % 3 === 0) {
      turtle.jump(Math.cos(a) * 10, Math.sin(a) * 10);
      turtle.goto(Math.cos(a) * 90, Math.sin(a) * 90);
    }
    return true;
  }
  return false;
}