public void Respawn()
{
if( m_RespawnTimer != null )
{
m_RespawnTimer.Stop();
m_RespawnTimer = null;
}
if( m_Content == null || Deleted )
return;
GenerateContent();
if( IsLockable )
{
Locked = true;
int difficulty = ( m_Content.Level - 1 ) * 30;
LockLevel = difficulty - 10;
MaxLockLevel = difficulty + 30;
RequiredSkill = difficulty;
}
if( IsTrapable && ( m_Content.Level > 1 || 4 > Utility.Random( 5 ) ) )
{
if( m_Content.Level > Utility.Random( 5 ) )
TrapType = TrapType.PoisonTrap;
else
TrapType = TrapType.ExplosionTrap;
TrapPower = m_Content.Level * Utility.RandomMinMax( 10, 30 );
TrapLevel = m_Content.Level;
}
else
{
TrapType = TrapType.None;
TrapPower = 0;
TrapLevel = 0;
}
CheckRespawn();
}