//-------------------------------------------------------------------
//
//  This code is copyright 2001 by G5 Software.
//  Any unauthorized usage, either in part or in whole of this code
//  is strictly prohibited. Violators WILL be prosecuted to the
//  maximum extent allowed by law.
//
//-------------------------------------------------------------------

class CSmallAsianHouseMesh_1
{
  string MeshFile = "Models/B_Asian_1.mesh";
  string SkinFile = "Models/B_Asian_1.skin";
}

class CSmallAsianHouseMesh_2
{
  string MeshFile = "Models/B_Asian_2.mesh";
  string SkinFile = "Models/B_Asian_2.skin";
}

class CSmallAsianHouseMesh_3
{
  string MeshFile = "Models/B_Asian_7.mesh";
  string SkinFile = "Models/B_Asian_7.skin";
}

class CSmallAsianHouseStateControl extends CUnitLifeControl
{
  void CSmallAsianHouseStateControl()
  {
    CUnitLifeControl(1500.0);
    m_DestroyPause = 20.0;
    m_ExplosionId  = "EXPLID_BuildingExplosion";
  }
}

// Building without ground control (for use in villages)
class CBaseSmallAsianHouse extends CBuilding, CUnitWithStateControl
{
  array m_MeshClassNames = array(
      "CSmallAsianHouseMesh_1",
      "CSmallAsianHouseMesh_2",
      "CSmallAsianHouseMesh_3"
    );

  void CBaseSmallAsianHouse()
  {
    int MeshNumber = rand_int(m_MeshClassNames.size());
    InitializeModelAsStatic(m_MeshClassNames[MeshNumber]);
    CUnitWithStateControl("CSmallAsianHouseStateControl");
  }
}

// Single game object
class CMountedSmallAsianHouse extends CBaseSmallAsianHouse
{
  void CMountedSmallAsianHouse()
  {
    InitializeGroundControl();
  }
}

