(This solution might be really complex but idk)
Would it be possible to recreate langton’s ant in gimkit?
If you don’t know what langton’s ant is, here:
Basically, the ant is on a completely white 1x1 grid (grid repeats forever) world and follows these rules:
At a white square, turn 90° clockwise, flip the color of the square, move forward one unit
At a black square, turn 90° counter-clockwise, flip the color of the square, move forward one unit
It will eventually get to a repeating pattern forever.
So my question, Is it possible?
(You can ask more questions if you want)
My first guess is no, as it seems it would need colour detection to work but I’m not the best block coder, so maybe someone else knows.
Does this go in devices or help? I’m not sure.
Edit: I’m not looking for a code that is really long that just does it (just going: image of ant forward one, turning the colour and turning 90* clockwise (not this order) and so on. I’m looking for one that can do it automatically. (If you were thinking of this)
Hm, this is interesting, I will try to see if this is possible and write what I tried to do below:
Im not too sure if this would work so tell me if this is wrong but,
Get text and put a white square emoji in it, copy it so you have a 20x20 square of white squares, then do another 20x20 black squares on top of the white ones, make all the black squares invisible at game start. Then, put a smaller orange square everywhere over the other white and black ones, but leave on orange square visible in the middle. After, make the ant move 90 degrees clockwise if white square visible by making it invisible and making the one 90 degrees to it visible, make white square that it was on invisible, and make black square visible. now repeat this process for the black one so it goes 90 degree counter-clockwise.
Most probably. You would have to code in cardinal directions so the AI is aware in which direction it’s pointing. But other than that, the system should be easy, like giving each square an on off state (on might be white and off would be black) and running a check in which state the ant is on and run the required code.
Best way you can try to achieve this is by using a property string like this:
00000,00000,00000,00000,00000
Which it represents a square and 0 is black and 1 is white. Then, you make a pseudo x y tracker for each square.
Err maybe we can use 3 to show the ant, such as
00000,00000,00000,0-31-000,00000
This is a concept that should be possible but I don’t have time for testing so someone else might want to try.
I could see how it would travel “up and down”. And as long as we just set a position in a property like North South East or West, we could get the ant to go in different directions.
I think @Aubec7’s idea is great but I’d like to build off of it a bit. Using text boxes with colored emoji as a display is a good idea but @Aubec7’s idea ends up using 1200 text boxes. A simple solution is to use one text box for each row and use block code to set each text box to a string of white or black emoji based on a property (like @AstralLuke suggested). Then you create properties for X, Y, and direction and create a trigger with block code so that each second it changes direction based on the color of the current tile, flips the current tile, then moves forward one space depending on direction.
Please let me know if you find any flaws in my proposed solution or want me to explain something in more detail.
This actually sorta fascinates me, I feel if we looked hard enough we can figure out smth
I feel we could somehow accomplish this I just have this wierd feeling
for so
I think we should keep going on this. I want to see how this ends up
I’ve already said that randomly generating mazes are almost there to this. Just replace the randomizer with an if statement to do the functions, and you should be all set for the most part
The only issue is the lag from a lot of barriers/props for the different colored squares.
So yeh lemme think a little on this
I have changed a decent-ish amount of making theories and not even helping
I think I am slightly more prone nowadays to help since I have been focusing my professions on code
Update: I do not know what to say… We pretty much have it figured out but we just need to incorporate what @Jon said into real time
What if we were to set our own rules for this ant so We can set it to still follow its whole rule system but we give it new rules that therefore would make these things
From my knowledge of staring at this ant for at least 10 minutes it simply just changes its direction from like clockwise to counter-clockwise based on tile color?
We could make a theoretical artist Ant here
we could really go far and wide with the color assortments and the combinations we could make
Know what Lemme mess around in Gimkit and see if I can concoct some sort of small system that makes a basic Langston ant
I am gonna need to hyperfocus on this I believe I can do this