Spider Enemy — Dungeon Escape

Creating my Spider enemy in Unity

Objective: Go over my implementation of my Spider enemy for my mobile game, Dungeon Escape.


The first thing I did to get my Spider enemy working is create the animations it will be using for the time being. These animations are its idle animation and its walking animation. The results of these are shown below.

Spider Idle Animation
Spider Walk Animation

Once I got the animations done, I went into the Animation Tree to hook up my animations and prepared them to be controlled with code. Below is a quick overview of my Animation Tree for my Spider enemy.

With this complete, I can now go ahead and create the code to control my Spider’s movement logic.


The code I created to get my Spider moving in the scene is very similar to the previous article I wrote on creating my Moss Giant enemy movement. The code I used (not including the abstract class) is shown below.

This gave me the result we see in the gif below.

That is all for today. Thank you for reading the article! In the next article, I will be optimizing code a bit and implementing the movements for my final enemy, the Skeleton.




Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Getting Started with Cloud Development Kit for Terraform (CDKTF)

Frontend Weekly Digest #225 (30 August — 5 September 2021)

Patching a binary using radare2

Digital Content

AWS Solution Architect Professional — Exam tips -2021

Convert MOV to GIF in Java

Explore The Advantages of Flutter for your project

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Gabe Gomez

Gabe Gomez

More from Medium

VFX — Adding Enemy Explosions

Pushing a box

Platformer: Collectible & Status Bar

OnCollisionEnter() vs. OnTriggerEnter()