Weaver.Examples Namespace

Summary

Examples of how to use Weaver.

Class Types

Class Summary
BillboardManager Controls the rotation of any objects it is given to make them constantly face its Weaver.Examples.BillboardManager.Transform
Building A simple destructible building for Example 05 Missile Command which also serves as an example of how to create a procedural asset.
Conversation A simple sequence that shows a series of pre-defined lines as speech text above specific objects as if they were having a conversation.
DamageOnContact Shows a Weaver.Examples.FloatingText as if damage were being dealt whenever a collision is detected.
DamageSystem A set of simple methods which use Weaver.Examples.IDealDamage and Weaver.Examples.ITakeDamage to pass simple damage messages around.
Explosion A simple spherical explosion which grows then shrinks over time and uses the Weaver.Examples.DamageSystem to notify objects that it hits.
FloatingText A Weaver.PoolableBehaviour`1 which manages a text object in the scene. This base class is a facade to allow implementations such as Weaver.Examples.FloatingTextUnity to use any text system.
FloatingTextBounce Causes the UnityEngine.Transform.localScale of a Weaver.Examples.FloatingText to smoothly bounce in and out over the course of its lifetime using a sine curve.
FloatingTextExtensions Extension methods for Weaver.Examples.FloatingText.
FloatingTextFade Causes a Weaver.Examples.FloatingText.Color to fade its alpha value from 1 to 0 over the course of its lifetime.
FloatingTextTypewriter Causes a Weaver.Examples.FloatingText to gradually show each of its character one at a time with a short delay.
FloatingTextUnity A Weaver.Examples.FloatingText that uses Unity's inbuilt UnityEngine.TextMesh component.
FollowMouse Constantly accelerates a UnityEngine.Rigidbody towards the mouse cursor on the XZ plane.
FrameRate A system that uses a Weaver.Examples.FrameRate.Text component to display the current Frame Rate (Frames Per Second). The displayed value is updated once per second.
GameOverScreen Pauses the game when shown and has a function to reload the current scene.

The Weaver.Examples.GameOverScreen.Prefab field serves as an example of Lazy Asset Injection.
Item An item that can be purchased from a shop.

This class could contain any kind of functionality, but for the purpose of this simple example it just holds the meta-data.
ItemDisplay A group of UI components which display the details of an Weaver.Examples.Item.
ItemShop Initializes an Weaver.Examples.ItemDisplay for each item in an Weaver.ItemList.
Missile A projectile that flies straight and creates an Weaver.Examples.Explosion when it hits something or takes damage.
MissileLauncher Rotates the Weaver.Examples.MissileLauncher._Launcher to face the mouse cursor and fires a Weaver.Examples.Missile whenever the player clicks the mouse.
MissileRain Randomly spawns missiles at a gradually increasing rate over an area.
Score A simple scoring system with a high score and Weaver.Examples.FloatingText to indicate when points are gained.
StunOnContact When collided with, this component shows a Weaver.Examples.FloatingText to indicate that the colliding object is stunned and temporarily freezes all its UnityEngine.Rigidbody.constraints so it can't move.
TextManager Provides a central location for accessing various different kinds of Weaver.Examples.FloatingText.

Interface Types

Interface Summary
IDealDamage An object that can deal damage and be notified when it does so.
ITakeDamage An object that can be damaged.

Struct Types

Struct Summary
ItemMetaData Details about an Weaver.Examples.Item.