How Spell Circles Work: The Basics and Cursed

General Hexcasting chattery.
(get it cause it's like the irc client hyuck hyuck)
User avatar
StickHexxing
Posts: 4
Joined: Sat Jun 15, 2024 7:09 pm

How Spell Circles Work: The Basics and Cursed

Post by StickHexxing »

Hello, I am Sophia/Stickia, and I have seen many people struggle to get a hold of Spell Circles and understand what they can do and why they are so powerful. So that is what this post will be fixing! In 3 chapters I will be covering: The Basics, The Magic of Playerless Casting, and Unintended Shapes of Spell Circles.

The Basics
Image
Above this are the 4 Impeti, and the 3 Directrices (as of 1.20.1), in order of left to right: Empty, Toolsmith, Fletcher, and Cleric Impeti; as for the Directrices: Shepherd, Mason, and Empty. Each of Impeti and Directrices above do different things. All the Impeti (except for empty) start casting in some way, the direction of the Media Wave for both Impeti and is Directrices indicated by the face on the front.
  • The Empty Impetus does about nothing. When a Media Wave is put through it, it goes out through the front. This can not start casting.
  • The Toolsmith Impetus is the simplest. When clicked, it starts casting as the player who clicked it.
  • The Fletcher Impetus is also quite simple. When looked at for 3 seconds by any player, it starts casting as the observer.
  • The Cleric Impetus is one of the most powerful Impeti. When powered by redstone, it starts casting as the stored player. The reason these Impeti are powerful is because that you can cast as a player, as long as you have their Truename in a focus; and that it can do Playerless Casting (this will be covered in the next chapter).
While the Impeti start casting, Directrices change the direction of the Media Wave. All the Directrices have 2 output faces (these will be called "happy" and "sad"), and all sides, except for the faces, are valid input. Depending on the state of the Directrix, the Media Wave leaves from one of the faces.
  • The Empty Directrix's output is decided by random chance. There are 50/50 odds of it coming out of happy or sad sides.
  • The Mason Directrix's output is decided by the redstone powering the block. If there is no redstone fed into the block, the wave will leave via sad; if there is redstone it will leave via happy.
  • The Shepherd Directrix's output is based on the stack itself. Depending on a Boolean on the top of the stack, it will either leave Happy for true, or Sad for false. If the top of the stack is not a Boolean, then the impetus itself will break
Hopefully your head isn't spinning quite yet! This is just how the blocks work. But as for how spell circles work, all you need to know is there has to be a loop of slate connecting the Impetus' output to itself.
Image
Above this section, there are 3 example Spell Circles: 1 functional, and 2 nonfunctional.
  • The first circle is functional. This is because it forms a full loop; therefor, the media wave can complete the full loop.
  • The second circle is nonfunctional. This is because it does not form a full loop; therefor, it errors before it starts.
  • The third circle is semi-nonfunctional. While it forms a full loop like circle 1, there is a split path on the second slate, meaning the circle errors on that slate. This is because it can not find where the media wave should go.
As well, an important fact that new players struggle to learn is that Spell Circles also have vertical ambit. The way vertical ambit is gotten is by running Slate up a wall, such as:
Image
This functions because when the Media Wave runs into the Empty Impeti, it can be redirected into a new slate orientation. Thus giving the Circle more vertical ambit. Now you know all you need for a basic Spell Circle! However, there are cursed arts with Spell Circles. And the rest of this post will be dedicated to said cursed arts. First up:

The Magic of Playerless Casting
As covered in The Basics, all but one of the Impeti require a player; this is the Cleric Impetus. For the average Hex Casting player, Playerless Casting might not seem that powerful; however, the utilities of this are endless. What Playerless Casting means is, the ability to cast automated Hexes without the requirement of a specific player online.

For example, let us take a farm I often use on the HexxyTest server: Automated Lava. If this was 1.19.2 Hex Casting, the Spell Circle that runs this farm would require a player to be online 24/7, giving it a player to reference to cast from. However, in 1.20.1, the Impetus does not require a player, therefor it can just take a redstone signal, and make lava. Unfortunately, Playerless Casting does have its downsides, those being: unable to use sentinels, unable to spawn in wisps, and unable to affect objects outside its ambit.
But, despite the downsides, Playerless Casting is still one of the most useful tools Spell Circles gives casters.

Unintended Shapes of Spell Circles
This section is dedicated to the truly cursed capabilities of Spell Circles.
First, let us get started with a more basic ability, the ability to change slate orientation without an Empty Impetus. All the Media Wave requires to "jump" to the next slate is at least one pixel of the slate it's currently on, to touch another slate.
Image
At first glance, this circle seems like it would error on start up; this is because the Impetus has no clear connection to its self. However, a single pixel of the floor slate connects to the wall slate, meaning the Media Wave can jump to the wall slate without any Empty Impeti. However, this is child's play compared to what can be done with Spell Circles: Ambit Modification.

On Spell Circle startup, the Impetus scans for all possible slates it can connect to, then it finds the smallest cuboid shape it can inside its bounds; this is the ambit it can effect. So using this fact, a Spell Circle can be "tricked" into thinking more slate is connected than what it really runs.
Image
Take this Spell Circle for example. What it really runs is the 2 slate in the center and the Directrix; but what it has ambit over is the blue glass square. How this works is when it is first scanning, the Spell Circle knows it can run the slate outside the Directrix, so it counts that as ambit. On top of that, the Spell Circle does not error on start up because it never reaches the invalid slates. This is what I call a "Slate Work," a tiny spell circle with "branches" of slate coming out of it, producing more ambit than what is normally possible. This is, by far, the most powerful tool Spell Circles have. It combines the speed of a small circle, with the massive ambit of a large circle.

However, this is not quite the end yet. There are Looping Circles (or "loopers").
Loopers are exactly what they sound like on the tin, they are spell circles that loop indefinitely. They work similarly to Slate Works, they both use the Directrices' ability to change slate direction.
Image
In the above example, the Spell Circle finds it has a valid path to its self, meaning it starts the Media Wave. Then, when the Media Wave hits the Directrix, it goes to the right, then it hits the Directrix again, and goes right. Repeat this until the Directrix gets a signal of some kind to make it go back down the valid path. As useful as loopers are, they are also quite laggy to use, this is because they cause "data leaks" or "nbt leaks."
On the Java level of Spell Circles, when the Media Wave hits a slate, it adds said Slate into a list, this is so it can calculate how fast the Media Wave should be going, and what slates to energize. However, the large problem with this method is that it can add the same slate it already has; meaning normal Spell Circles are fine, but loopers keep building this data, and evenly crash the world. There is a PR to Hex Casting to fix this annoying bug; but as of the time of writing, it has not been merged. So take this warning:
For now, looping Spell Circles can lag or crash your world if they loop for too long.

However, as for now, this post is now done. If there are any more techniques I may have missed, please add them! Or if anything needs clarifying, let me know and I will update the post. But for now, have fun with Spell Circles!
-Arco_Stickia was here
deaqqwwwqqaed
User avatar
endlessstormwolf
Posts: 1
Joined: Tue Jan 21, 2025 6:22 pm

Re: How Spell Circles Work: The Basics and Cursed

Post by endlessstormwolf »

10/10 very enlightening!
⚡Stormcaller Wolf⚡(she/her)
⚧️Mage of Lightning⚧️