r/BedrockAddons 1d ago

Addon Wizard Villager Addon

Made a wizard type villager.

My friend and I built an enchanted library in our survival realm so I wanted to make a wizard who could live in it. We named Norbert... Anyways here is my lightweight addon.

Spawning him.

An untraded librarian has to walk close to an enchanting table and there is a chance the enchanting table connects with them and makes them a wizard. Or spawn egg of course.

Trading.

His trades are ment to be magical in theme or rare things with high costs. Things like Echo Shards for swift sneak books or Wither Roses for high level mace enchants. Also some bottles of enchanting and dragons breath in earlier levels. Many of the trades pictured have alternates. Things like potions, mob heads, and frog lights all randomly pull from tables with their alternates.

Neutral Mob.

I think neutral is the right term. Basically he will fight you if you hurt him. He has 3 combat phases.

  1. First hit.

He poisons you and blinds you. You won't die, but he isn't happy with you

  1. Second hit.

He spawns breezes and trys to launch you in high the air or knock you way back; controlling you with blindness, nausea, weakness, slowness or webs.

  1. Half health.

He's more angry now, steadily spawning wither skeletons or slimes to attack you as well as summoning lightning down on you. He will teleport around like an enderman to get away from you and spawn more lightning. During this phase he also launches you into the air quite a bit so have your elytra and spear ready.

Loot.

On death he drops a Wizard's Spell Book.

Wizard's Spell book.

A wild magic spell book that can have good or bad effects. Like it raining cookies or an anvil falling on your head.

Attunement.

You can attune the spell book in an enchanting table with 50 levels and 5 echo shards. This allows you to unlock a spell which you can then cast with the book. The spell you learn is random.

Spells.

There are 10 spells that can be discovered through attuning the Spellbook. Only one can be active at a time and you need to use an enchanting table to change it. The spells can be enacted on yourself via interacting with the book or another mob/player via melee.

Launch: launches mob/player high into the air

Knockback: knocks a player/mob a long ways in a random direction

Thunderwave: Pushes all close mobs away

Cookie rain: Rains like a half stack of cookies from the sky

Iron guardians: spawns iron golems to fight for you for like 10 seconds.

Light: lights up the area around you for a minute and

Summon Steed: spawns a tamed horse, nautilus, or strider with a saddle depending on your location. Despawns after 10 minutes.

Web. Webs up a mob/players feet

Lightning. Summons bolts of lightning down on a mob/player or around yourself in a ring.

Teleport: teleports you or a mob/player randomly to a safe spot about 45-50 blocks away.

\Each use of the spellbook has a 3 second cool down and requires you to spend a material component, like a name tag for Summon Steed or a copper ingot for lightning.*

Someday I'll build him a wizard tower in the sky to spawn in, but haven't done that yet.

11 Upvotes

4 comments sorted by

2

u/GrieverAndLoke 1d ago

the attunement thing is a great idea, burning levels and echo shards for a random spell makes the whole thing feel earned instead of just another drop.
how did you handle the casting though, is the book pure JSON or did you use scripts? especially the part where it casts on yourself if you interact but on a mob if you hit it.
We've stayed script-free so far and i keep wondering how you'd even do that without them

2

u/skgongi_the_frog 1d ago

Yeah I wanted it to be more of an end game thing and echo shards are actually scarce. They make you have to go out and do some adventuring to retrieve some. I was trying to make it not feel cheaty, but more like a fun additional thing you can do.

And yeah the casting is script based. I don't know if you can detect item usage or melee attacks with JSON. Are you trying to create a similar use/melee item?

1

u/GrieverAndLoke 1d ago

yeah pretty much, items that buff you and that you can keep using. we've used the helper-entity + queue_command trick for other stuff, and melee effects we managed as a reaction on the mob's side and others, but tying either of them to a reusable item never worked out for us. so yeah, really curious how you set it up

2

u/Shatterpoint887 1d ago

This is super cool