TowerTests ShowAllTowerTypesAndEffects Method Delta Engine Documentation

Namespace: CreepyTowers.Tests.Towers
Assembly: CreepyTowers.Tests (in CreepyTowers.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public void ShowAllTowerTypesAndEffects()
Examples

[Test]
public void ShowAllTowerTypesAndEffects()
{
    var tower = new Tower(TowerType.Acid, Vector3D.Zero);
    tower.RenderModel();
    var creep = new Creep(CreepType.Cloth, new Vector2D(2, 8));
    new Command(() => { tower.FireAtCreep(creep); }).Add(new KeyTrigger(Key.Space));
    new Command(() => { tower.RotationZ += 2; }).Add(new KeyTrigger(Key.A, State.Pressed));
    new Command(() => { tower.RotationZ -= 2; }).Add(new KeyTrigger(Key.D, State.Pressed));
    new Command(() =>
    { //ncrunch: no coverage start
        tower.Dispose();
        tower = new Tower(CycleTypeUpwards(tower.Type), Vector3D.Zero);
        tower.RenderModel(); //ncrunch: no coverage end
    }).Add(new KeyTrigger(Key.W));
    new Command(() =>
    { //ncrunch: no coverage start
        tower.Dispose();
        tower = new Tower(CycleTypeDownwards(tower.Type), Vector3D.Zero);
        tower.RenderModel(); //ncrunch: no coverage end
    }).Add(new KeyTrigger(Key.S));
}
See Also