From 358ea0111f6ac6ceeab82df0b197c906824c6a1d Mon Sep 17 00:00:00 2001 From: JustAGenericUsername Date: Sat, 23 Mar 2024 18:48:26 -0400 Subject: [PATCH 1/2] grid maker :) --- mods/nousersthings.js | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/mods/nousersthings.js b/mods/nousersthings.js index 54db584e..9e5282ff 100644 --- a/mods/nousersthings.js +++ b/mods/nousersthings.js @@ -2368,4 +2368,24 @@ elements.spacedust = { } elements.acid.ignore.push("spacedust") elements.acid.ignore.push("spacedust_cola") -elements.sun.breakInto = "spacedust" \ No newline at end of file +elements.sun.breakInto = "spacedust" +var gridElem = 0 +elements.grid_maker = { + color: elements.lattice.color, + behavior: behaviors.WALL, + category: "special", + movable: false, + onSelect: function() { + var gridans = prompt("Please input the desired element of this void. It will not work if you do multiple void types while paused.",(gridElem||undefined)); + if (!gridans) { return } + gridElem = mostSimilarElement(gridans); + }, + tick: function(pixel){ + if (pixel.x%2 || pixel.y%2){ + deletePixel(pixel.x, pixel.y) + createPixel(gridElem, pixel.x, pixel.y) + } else { + deletePixel(pixel.x, pixel.y) + } + } +} \ No newline at end of file From 04275e025d520bf19b0ab4efd7508b05d435f4c0 Mon Sep 17 00:00:00 2001 From: JustAGenericUsername Date: Sat, 23 Mar 2024 18:48:54 -0400 Subject: [PATCH 2/2] s --- mods/nousersthings.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/nousersthings.js b/mods/nousersthings.js index 9e5282ff..06760b7d 100644 --- a/mods/nousersthings.js +++ b/mods/nousersthings.js @@ -2370,13 +2370,13 @@ elements.acid.ignore.push("spacedust") elements.acid.ignore.push("spacedust_cola") elements.sun.breakInto = "spacedust" var gridElem = 0 -elements.grid_maker = { +elements.grid_brush = { color: elements.lattice.color, behavior: behaviors.WALL, category: "special", movable: false, onSelect: function() { - var gridans = prompt("Please input the desired element of this void. It will not work if you do multiple void types while paused.",(gridElem||undefined)); + var gridans = prompt("Please input the desired element of this grid brush",(gridElem||undefined)); if (!gridans) { return } gridElem = mostSimilarElement(gridans); },