Agent Model Property Delta Engine Documentation

Namespace: CreepyTowers
Assembly: CreepyTowers (in CreepyTowers.exe) Version: 1.1.1.0 (1.1.1)
Syntax

public Model Model { get; protected set; }

Property Value

Type: Model
Remarks

Tests: CreepyTowers.Tests.Towers.TowerTests
Examples

2 unit tests call CreepyTowers.Agent.Model
[Test, CloseAfterFirstFrame]
public void NotInitializingTowerDoesntCreateTowerModel()
{
    new Tower(TowerType.Water, Vector3D.Zero);
    Assert.AreEqual(0, EntitiesRunner.Current.GetEntitiesOfType<Model>().Count);
    Assert.AreEqual(1, EntitiesRunner.Current.GetEntitiesOfType<Tower>().Count);
}
[Test, CloseAfterFirstFrame]
public void InitializingTowerCreatesTowerModel()
{
    var tower = new Tower(TowerType.Water, Vector3D.Zero);
    tower.RenderModel();
    Assert.AreEqual(1, EntitiesRunner.Current.GetEntitiesOfType<Model>().Count);
    Assert.AreEqual(1, EntitiesRunner.Current.GetEntitiesOfType<Tower>().Count);
}
See Also