A fully procedurally animated spider. Climbs walls and ceilings. Legs step onto surrounding geometry. Third-Person playable character and NPC.What does the asset contain?Spider Model (incl. Rig/Texture/Material)Third-Person Playable Spider (Prefab)NPC Spider (Prefab)All Code/Scripts for the Procedural AnimationDemo ScenesHow does the spider walk on walls?The spider uses sphere casting (downwards for terrain adjustment and forwards for wall climbing). A fake gravity in respect to its current normal sticks the spider to the surface. The layers on which it can walk can be adjusted.Do the feet touch actual geometry?Yes, each leg will step onto actual physical colliders in your scene. Each leg is modelled by a chain of hinge joints with implemented rotational limits. A system of raycasts queries the environment for physical geometry to determine where to place the foot. Then IK is used, specifically a simple tailored CCD (Cyclic Coordinate Descent) algorithm, to solve the leg.When and how do the legs step?A leg desires to step if the IK solver can not solve the leg sufficiently anymore. The leg will queue in for a step, and the spider will orchestrate each legs desire to step and make sure asynchronicity to other legs is adhered to. The leg will move in an arc to reach every new target.Does the body also procedurally animate?Yes, the spiders body (root bone) will elevate and rotate with the legs, which makes the procedural animation more realistic.Does the spider use physics?Yes, the spider has a rigid body and a capsule collider. It can therefore be pushed and also push other rigid bodies. It will however not rotate from any forces applied for stability reasons. It does not use default physics gravity, as it has its own implemented gravity that get applied to stick it to the current surface.What is the Third-Person-Playable spider?You can play as the spider. You have a smooth camera behind the spider that will react to mouse input. You can move the spider using horizontal/vertical input axes (e.g. WASD). You can jump with Space. The camera will cull objects between camera and spider so as to never loose sight of it.What is the NPC spider?It’s a basic controller that will either move the spider around randomly using perlin noise, or move towards a specified target (or a blend of the two). It can frequently and erratically stop moving as to mimic how real spiders move.Can I customize behaviour?Yes, all the components expose a bunch of parameters with which you can tweak behaviour.Is documentation provided?Yes, documentation in form of a pdf file is included in the asset. Additionally all user facing variables have tooltips.Can I set it up to use my own spider model?It is possible to use another model/rig than the provided one, but this is not straightforward to set up and it is not guaranteed to work for your model. There are a couple of requirements your model/rig has to fulfill:Must have enough joints per leg (The provided one has five per leg, plus end effector).The first joint of each leg must be designed to rotate around the spiders root bone up axis and the remaining ones must be designed to rotate in such a way that they curl (e.g. local Z-Axis).The leg/body length ratio needs to be similar to the provided one.The provided documentation goes more in depth on how to set this up correctly. Note however that I can and will not guarantee that using your custom spider model will work without issues.Can I combine it with regular animations?This asset does not include any animation clips. All animation is fully procedural. It is not possible to blend animation clips on top of this procedural animation. It is however possible to disable the procedural animation, play an animation clip and reenable it when the animation clip has finished playing. With this approach one could e.g. add a custom jump animation etc.What about performance?Performance has been taken into account heavily. A simple built scene of eighty active and rendered spiders on a MacBook Air M1 (2020) has a stable frame rate of 75FPS. Note that in reality it will perform even better than in this stress test. This is firstly due to procedurally animation being fully culled if a spider is not being rendered. And secondly, having these many spiders is not a realistic scenario as most games will only use one or a few. It is always recommended to keep the amount of spiders low as procedural animation is inherently more expensive than regular animation mostly due to the IK solving and the ray casting.Full source code includedDocumentation includedCustom inspectorsPerformance optimizedRigid body basedNumber of prefabs: 3 (Player, NPC, Player+NPC)Included Spider:Number of textures: 1Texture dimensions: 2048 × 2048Polygon count: 9650Animation count: 0 (Spider is fully procedurally animated!)